Documentation
¶
Overview ¶
Package client provides a Go client for the Prefect Server API.
Index ¶
- type AdminService
- type ArtifactsService
- func (s *ArtifactsService) Count(ctx context.Context, filter *models.ArtifactFilter) (int, error)
- func (s *ArtifactsService) CountLatest(ctx context.Context, filter *models.ArtifactCollectionFilter) (int, error)
- func (s *ArtifactsService) Create(ctx context.Context, req *models.ArtifactCreate) (*models.Artifact, error)
- func (s *ArtifactsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *ArtifactsService) Get(ctx context.Context, id uuid.UUID) (*models.Artifact, error)
- func (s *ArtifactsService) GetLatest(ctx context.Context, key string) (*models.Artifact, error)
- func (s *ArtifactsService) List(ctx context.Context, filter *models.ArtifactFilter, offset, limit int) (*pagination.PaginatedResponse[models.Artifact], error)
- func (s *ArtifactsService) ListAll(ctx context.Context, filter *models.ArtifactFilter) *pagination.Iterator[models.Artifact]
- func (s *ArtifactsService) ListLatest(ctx context.Context, filter *models.ArtifactCollectionFilter, ...) (*pagination.PaginatedResponse[models.ArtifactCollection], error)
- func (s *ArtifactsService) Update(ctx context.Context, id uuid.UUID, req *models.ArtifactUpdate) error
- type AutomationsService
- func (s *AutomationsService) Count(ctx context.Context, filter *models.AutomationFilter) (int, error)
- func (s *AutomationsService) Create(ctx context.Context, req *models.AutomationCreate) (*models.Automation, error)
- func (s *AutomationsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *AutomationsService) DeleteOwnedBy(ctx context.Context, resourceID string) error
- func (s *AutomationsService) Get(ctx context.Context, id uuid.UUID) (*models.Automation, error)
- func (s *AutomationsService) GetRelatedTo(ctx context.Context, resourceID string) ([]models.Automation, error)
- func (s *AutomationsService) List(ctx context.Context, filter *models.AutomationFilter) ([]models.Automation, error)
- func (s *AutomationsService) Patch(ctx context.Context, id uuid.UUID, req *models.AutomationPartialUpdate) error
- func (s *AutomationsService) Update(ctx context.Context, id uuid.UUID, req *models.AutomationUpdate) (*models.Automation, error)
- func (s *AutomationsService) ValidateTemplate(ctx context.Context, template string) error
- type BlockCapabilitiesService
- type BlockDocumentsService
- func (s *BlockDocumentsService) Count(ctx context.Context, filter *models.BlockDocumentFilter) (int, error)
- func (s *BlockDocumentsService) Create(ctx context.Context, req *models.BlockDocumentCreate) (*models.BlockDocument, error)
- func (s *BlockDocumentsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *BlockDocumentsService) Get(ctx context.Context, id uuid.UUID, includeSecrets bool) (*models.BlockDocument, error)
- func (s *BlockDocumentsService) List(ctx context.Context, filter *models.BlockDocumentFilter, includeSecrets bool, ...) ([]models.BlockDocument, error)
- func (s *BlockDocumentsService) Update(ctx context.Context, id uuid.UUID, req *models.BlockDocumentUpdate) error
- type BlockSchemasService
- func (s *BlockSchemasService) Create(ctx context.Context, req *models.BlockSchemaCreate) (*models.BlockSchema, error)
- func (s *BlockSchemasService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *BlockSchemasService) Get(ctx context.Context, id uuid.UUID) (*models.BlockSchema, error)
- func (s *BlockSchemasService) GetByChecksum(ctx context.Context, checksum string, version string) (*models.BlockSchema, error)
- func (s *BlockSchemasService) List(ctx context.Context, filter *models.BlockSchemaFilter, offset, limit int) ([]models.BlockSchema, error)
- type BlockTypesService
- func (s *BlockTypesService) Create(ctx context.Context, req *models.BlockTypeCreate) (*models.BlockType, error)
- func (s *BlockTypesService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *BlockTypesService) Get(ctx context.Context, id uuid.UUID) (*models.BlockType, error)
- func (s *BlockTypesService) GetBlockDocumentByName(ctx context.Context, slug, name string, includeSecrets bool) (*models.BlockDocument, error)
- func (s *BlockTypesService) GetBySlug(ctx context.Context, slug string) (*models.BlockType, error)
- func (s *BlockTypesService) InstallSystemBlockTypes(ctx context.Context) error
- func (s *BlockTypesService) List(ctx context.Context, filter *models.BlockTypeFilter, offset, limit int) ([]models.BlockType, error)
- func (s *BlockTypesService) ListBlockDocumentsBySlug(ctx context.Context, slug string, includeSecrets bool) ([]models.BlockDocument, error)
- func (s *BlockTypesService) Update(ctx context.Context, id uuid.UUID, req *models.BlockTypeUpdate) error
- type Client
- type ConcurrencyLimitsService
- func (s *ConcurrencyLimitsService) Create(ctx context.Context, req *models.ConcurrencyLimitCreate) (*models.ConcurrencyLimit, error)
- func (s *ConcurrencyLimitsService) Decrement(ctx context.Context, names []string, slots int) error
- func (s *ConcurrencyLimitsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *ConcurrencyLimitsService) DeleteByTag(ctx context.Context, tag string) error
- func (s *ConcurrencyLimitsService) Get(ctx context.Context, id uuid.UUID) (*models.ConcurrencyLimit, error)
- func (s *ConcurrencyLimitsService) GetByTag(ctx context.Context, tag string) (*models.ConcurrencyLimit, error)
- func (s *ConcurrencyLimitsService) Increment(ctx context.Context, names []string, slots int, mode string) ([]models.MinimalConcurrencyLimitResponse, error)
- func (s *ConcurrencyLimitsService) List(ctx context.Context) ([]models.ConcurrencyLimit, error)
- func (s *ConcurrencyLimitsService) ResetByTag(ctx context.Context, tag string) error
- type ConcurrencyLimitsV2Service
- func (s *ConcurrencyLimitsV2Service) Create(ctx context.Context, req *models.ConcurrencyLimitV2Create) (*models.ConcurrencyLimitV2, error)
- func (s *ConcurrencyLimitsV2Service) Decrement(ctx context.Context, names []string, slots int) error
- func (s *ConcurrencyLimitsV2Service) DecrementWithLease(ctx context.Context, names []string, slots int, leaseID uuid.UUID) error
- func (s *ConcurrencyLimitsV2Service) Delete(ctx context.Context, idOrName string) error
- func (s *ConcurrencyLimitsV2Service) Get(ctx context.Context, idOrName string) (*models.ConcurrencyLimitV2, error)
- func (s *ConcurrencyLimitsV2Service) Increment(ctx context.Context, names []string, slots int, mode string) error
- func (s *ConcurrencyLimitsV2Service) IncrementWithLease(ctx context.Context, names []string, slots int, mode string) (*models.ConcurrencyLimitWithLeaseResponse, error)
- func (s *ConcurrencyLimitsV2Service) List(ctx context.Context) ([]models.GlobalConcurrencyLimitResponse, error)
- func (s *ConcurrencyLimitsV2Service) RenewLease(ctx context.Context, leaseID uuid.UUID) error
- func (s *ConcurrencyLimitsV2Service) Update(ctx context.Context, idOrName string, req *models.ConcurrencyLimitV2Update) error
- type DeploymentsService
- func (s *DeploymentsService) Count(ctx context.Context, filter *models.DeploymentFilter) (int, error)
- func (s *DeploymentsService) Create(ctx context.Context, req *models.DeploymentCreate) (*models.Deployment, error)
- func (s *DeploymentsService) CreateFlowRun(ctx context.Context, id uuid.UUID, params map[string]interface{}) (*models.FlowRun, error)
- func (s *DeploymentsService) CreateSchedules(ctx context.Context, id uuid.UUID, schedules []models.DeploymentScheduleCreate) ([]models.DeploymentSchedule, error)
- func (s *DeploymentsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *DeploymentsService) DeleteSchedule(ctx context.Context, deploymentID, scheduleID uuid.UUID) error
- func (s *DeploymentsService) Get(ctx context.Context, id uuid.UUID) (*models.Deployment, error)
- func (s *DeploymentsService) GetByName(ctx context.Context, flowName, deploymentName string) (*models.Deployment, error)
- func (s *DeploymentsService) GetSchedules(ctx context.Context, id uuid.UUID) ([]models.DeploymentSchedule, error)
- func (s *DeploymentsService) List(ctx context.Context, filter *models.DeploymentFilter, offset, limit int) (*pagination.PaginatedResponse[models.Deployment], error)
- func (s *DeploymentsService) ListAll(ctx context.Context, filter *models.DeploymentFilter) *pagination.Iterator[models.Deployment]
- func (s *DeploymentsService) Pause(ctx context.Context, id uuid.UUID) error
- func (s *DeploymentsService) Resume(ctx context.Context, id uuid.UUID) error
- func (s *DeploymentsService) Update(ctx context.Context, id uuid.UUID, req *models.DeploymentUpdate) (*models.Deployment, error)
- func (s *DeploymentsService) UpdateSchedule(ctx context.Context, deploymentID, scheduleID uuid.UUID, ...) error
- type EventsService
- func (s *EventsService) CountBy(ctx context.Context, countable string, filter *models.EventFilter) ([]models.EventCount, error)
- func (s *EventsService) Create(ctx context.Context, events []models.Event) error
- func (s *EventsService) List(ctx context.Context, filter *models.EventFilter) (*models.EventPage, error)
- func (s *EventsService) NextPage(ctx context.Context) (*models.EventPage, error)
- type FlowRunStatesService
- type FlowRunsService
- func (s *FlowRunsService) Count(ctx context.Context, filter *models.FlowRunFilter) (int, error)
- func (s *FlowRunsService) Create(ctx context.Context, req *models.FlowRunCreate) (*models.FlowRun, error)
- func (s *FlowRunsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *FlowRunsService) Get(ctx context.Context, id uuid.UUID) (*models.FlowRun, error)
- func (s *FlowRunsService) List(ctx context.Context, filter *models.FlowRunFilter, offset, limit int) (*pagination.PaginatedResponse[models.FlowRun], error)
- func (s *FlowRunsService) ListAll(ctx context.Context, filter *models.FlowRunFilter) *pagination.Iterator[models.FlowRun]
- func (s *FlowRunsService) SetState(ctx context.Context, id uuid.UUID, state *models.StateCreate) (*models.FlowRun, error)
- func (s *FlowRunsService) Update(ctx context.Context, id uuid.UUID, req *models.FlowRunUpdate) (*models.FlowRun, error)
- func (s *FlowRunsService) Wait(ctx context.Context, id uuid.UUID, pollInterval time.Duration) (*models.FlowRun, error)
- type FlowsService
- func (s *FlowsService) Count(ctx context.Context, filter *models.FlowFilter) (int, error)
- func (s *FlowsService) Create(ctx context.Context, req *models.FlowCreate) (*models.Flow, error)
- func (s *FlowsService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *FlowsService) Get(ctx context.Context, id uuid.UUID) (*models.Flow, error)
- func (s *FlowsService) GetByName(ctx context.Context, name string) (*models.Flow, error)
- func (s *FlowsService) List(ctx context.Context, filter *models.FlowFilter, offset, limit int) (*pagination.PaginatedResponse[models.Flow], error)
- func (s *FlowsService) ListAll(ctx context.Context, filter *models.FlowFilter) *pagination.Iterator[models.Flow]
- func (s *FlowsService) Update(ctx context.Context, id uuid.UUID, req *models.FlowUpdate) (*models.Flow, error)
- type LogsService
- type Option
- type SavedSearchesService
- func (s *SavedSearchesService) Create(ctx context.Context, req *models.SavedSearchCreate) (*models.SavedSearch, error)
- func (s *SavedSearchesService) Delete(ctx context.Context, id uuid.UUID) error
- func (s *SavedSearchesService) Get(ctx context.Context, id uuid.UUID) (*models.SavedSearch, error)
- func (s *SavedSearchesService) List(ctx context.Context) ([]models.SavedSearch, error)
- type TaskRunStatesService
- type TaskRunsService
- func (t *TaskRunsService) Count(ctx context.Context, filter *models.TaskRunFilter) (int, error)
- func (t *TaskRunsService) Create(ctx context.Context, req *models.TaskRunCreate) (*models.TaskRun, error)
- func (t *TaskRunsService) Delete(ctx context.Context, id uuid.UUID) error
- func (t *TaskRunsService) Get(ctx context.Context, id uuid.UUID) (*models.TaskRun, error)
- func (t *TaskRunsService) List(ctx context.Context, filter *models.TaskRunFilter, offset, limit int) (*pagination.PaginatedResponse[models.TaskRun], error)
- func (t *TaskRunsService) ListAll(ctx context.Context, filter *models.TaskRunFilter) *pagination.Iterator[models.TaskRun]
- func (t *TaskRunsService) SetState(ctx context.Context, id uuid.UUID, state *models.StateCreate) (*models.TaskRun, error)
- func (t *TaskRunsService) Update(ctx context.Context, id uuid.UUID, req *models.TaskRunUpdate) (*models.TaskRun, error)
- type TaskWorkersService
- type VariablesService
- func (v *VariablesService) Count(ctx context.Context, filter *models.VariableFilter) (int, error)
- func (v *VariablesService) Create(ctx context.Context, req *models.VariableCreate) (*models.Variable, error)
- func (v *VariablesService) Delete(ctx context.Context, id uuid.UUID) error
- func (v *VariablesService) Get(ctx context.Context, id uuid.UUID) (*models.Variable, error)
- func (v *VariablesService) GetByName(ctx context.Context, name string) (*models.Variable, error)
- func (v *VariablesService) List(ctx context.Context, filter *models.VariableFilter, offset, limit int) (*pagination.PaginatedResponse[models.Variable], error)
- func (v *VariablesService) ListAll(ctx context.Context, filter *models.VariableFilter) *pagination.Iterator[models.Variable]
- func (v *VariablesService) Update(ctx context.Context, id uuid.UUID, req *models.VariableUpdate) (*models.Variable, error)
- type WorkPoolsService
- func (w *WorkPoolsService) Count(ctx context.Context, filter *models.WorkPoolFilter) (int, error)
- func (w *WorkPoolsService) Create(ctx context.Context, req *models.WorkPoolCreate) (*models.WorkPool, error)
- func (w *WorkPoolsService) Delete(ctx context.Context, name string) error
- func (w *WorkPoolsService) Get(ctx context.Context, name string) (*models.WorkPool, error)
- func (w *WorkPoolsService) List(ctx context.Context, filter *models.WorkPoolFilter, offset, limit int) ([]models.WorkPool, error)
- func (w *WorkPoolsService) Update(ctx context.Context, name string, req *models.WorkPoolUpdate) error
- type WorkQueuesService
- func (w *WorkQueuesService) Create(ctx context.Context, req *models.WorkQueueCreate) (*models.WorkQueue, error)
- func (w *WorkQueuesService) Delete(ctx context.Context, id uuid.UUID) error
- func (w *WorkQueuesService) Get(ctx context.Context, id uuid.UUID) (*models.WorkQueue, error)
- func (w *WorkQueuesService) GetByName(ctx context.Context, name string) (*models.WorkQueue, error)
- func (w *WorkQueuesService) List(ctx context.Context, filter *models.WorkQueueFilter, offset, limit int) ([]models.WorkQueue, error)
- func (w *WorkQueuesService) Update(ctx context.Context, id uuid.UUID, req *models.WorkQueueUpdate) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminService ¶
type AdminService struct {
// contains filtered or unexported fields
}
AdminService handles administrative operations.
type ArtifactsService ¶
type ArtifactsService struct {
// contains filtered or unexported fields
}
ArtifactsService handles operations related to artifacts.
func (*ArtifactsService) Count ¶
func (s *ArtifactsService) Count(ctx context.Context, filter *models.ArtifactFilter) (int, error)
Count returns the number of artifacts matching the filter.
func (*ArtifactsService) CountLatest ¶
func (s *ArtifactsService) CountLatest(ctx context.Context, filter *models.ArtifactCollectionFilter) (int, error)
CountLatest returns the number of latest artifact collections matching the filter.
func (*ArtifactsService) Create ¶
func (s *ArtifactsService) Create(ctx context.Context, req *models.ArtifactCreate) (*models.Artifact, error)
Create creates a new artifact.
func (*ArtifactsService) List ¶
func (s *ArtifactsService) List(ctx context.Context, filter *models.ArtifactFilter, offset, limit int) (*pagination.PaginatedResponse[models.Artifact], error)
List retrieves a list of artifacts with optional filtering.
func (*ArtifactsService) ListAll ¶
func (s *ArtifactsService) ListAll(ctx context.Context, filter *models.ArtifactFilter) *pagination.Iterator[models.Artifact]
ListAll returns an iterator for all artifacts matching the filter.
func (*ArtifactsService) ListLatest ¶
func (s *ArtifactsService) ListLatest(ctx context.Context, filter *models.ArtifactCollectionFilter, offset, limit int) (*pagination.PaginatedResponse[models.ArtifactCollection], error)
ListLatest retrieves the latest artifact collections with optional filtering.
func (*ArtifactsService) Update ¶
func (s *ArtifactsService) Update(ctx context.Context, id uuid.UUID, req *models.ArtifactUpdate) error
Update updates an artifact.
type AutomationsService ¶
type AutomationsService struct {
// contains filtered or unexported fields
}
AutomationsService handles operations related to automations.
func (*AutomationsService) Count ¶
func (s *AutomationsService) Count(ctx context.Context, filter *models.AutomationFilter) (int, error)
Count returns the number of automations matching the filter.
func (*AutomationsService) Create ¶
func (s *AutomationsService) Create(ctx context.Context, req *models.AutomationCreate) (*models.Automation, error)
Create creates a new automation.
func (*AutomationsService) DeleteOwnedBy ¶
func (s *AutomationsService) DeleteOwnedBy(ctx context.Context, resourceID string) error
DeleteOwnedBy deletes automations owned by a specific resource.
func (*AutomationsService) Get ¶
func (s *AutomationsService) Get(ctx context.Context, id uuid.UUID) (*models.Automation, error)
Get retrieves an automation by ID.
func (*AutomationsService) GetRelatedTo ¶
func (s *AutomationsService) GetRelatedTo(ctx context.Context, resourceID string) ([]models.Automation, error)
GetRelatedTo retrieves automations related to a specific resource.
func (*AutomationsService) List ¶
func (s *AutomationsService) List(ctx context.Context, filter *models.AutomationFilter) ([]models.Automation, error)
List retrieves automations with optional filtering.
func (*AutomationsService) Patch ¶
func (s *AutomationsService) Patch(ctx context.Context, id uuid.UUID, req *models.AutomationPartialUpdate) error
Patch partially updates an automation.
func (*AutomationsService) Update ¶
func (s *AutomationsService) Update(ctx context.Context, id uuid.UUID, req *models.AutomationUpdate) (*models.Automation, error)
Update fully replaces an automation.
func (*AutomationsService) ValidateTemplate ¶
func (s *AutomationsService) ValidateTemplate(ctx context.Context, template string) error
ValidateTemplate validates an automation template.
type BlockCapabilitiesService ¶
type BlockCapabilitiesService struct {
// contains filtered or unexported fields
}
BlockCapabilitiesService handles operations related to block capabilities.
type BlockDocumentsService ¶
type BlockDocumentsService struct {
// contains filtered or unexported fields
}
BlockDocumentsService handles operations related to block documents.
func (*BlockDocumentsService) Count ¶
func (s *BlockDocumentsService) Count(ctx context.Context, filter *models.BlockDocumentFilter) (int, error)
Count returns the number of block documents matching the filter.
func (*BlockDocumentsService) Create ¶
func (s *BlockDocumentsService) Create(ctx context.Context, req *models.BlockDocumentCreate) (*models.BlockDocument, error)
Create creates a new block document.
func (*BlockDocumentsService) Get ¶
func (s *BlockDocumentsService) Get(ctx context.Context, id uuid.UUID, includeSecrets bool) (*models.BlockDocument, error)
Get retrieves a block document by ID.
func (*BlockDocumentsService) List ¶
func (s *BlockDocumentsService) List(ctx context.Context, filter *models.BlockDocumentFilter, includeSecrets bool, sort models.BlockDocumentSort, offset, limit int) ([]models.BlockDocument, error)
List retrieves block documents with optional filtering.
func (*BlockDocumentsService) Update ¶
func (s *BlockDocumentsService) Update(ctx context.Context, id uuid.UUID, req *models.BlockDocumentUpdate) error
Update updates a block document's data.
type BlockSchemasService ¶
type BlockSchemasService struct {
// contains filtered or unexported fields
}
BlockSchemasService handles operations related to block schemas.
func (*BlockSchemasService) Create ¶
func (s *BlockSchemasService) Create(ctx context.Context, req *models.BlockSchemaCreate) (*models.BlockSchema, error)
Create creates a new block schema.
func (*BlockSchemasService) Get ¶
func (s *BlockSchemasService) Get(ctx context.Context, id uuid.UUID) (*models.BlockSchema, error)
Get retrieves a block schema by ID.
func (*BlockSchemasService) GetByChecksum ¶
func (s *BlockSchemasService) GetByChecksum(ctx context.Context, checksum string, version string) (*models.BlockSchema, error)
GetByChecksum retrieves a block schema by checksum and optional version.
func (*BlockSchemasService) List ¶
func (s *BlockSchemasService) List(ctx context.Context, filter *models.BlockSchemaFilter, offset, limit int) ([]models.BlockSchema, error)
List retrieves block schemas with optional filtering.
type BlockTypesService ¶
type BlockTypesService struct {
// contains filtered or unexported fields
}
BlockTypesService handles operations related to block types.
func (*BlockTypesService) Create ¶
func (s *BlockTypesService) Create(ctx context.Context, req *models.BlockTypeCreate) (*models.BlockType, error)
Create creates a new block type.
func (*BlockTypesService) GetBlockDocumentByName ¶
func (s *BlockTypesService) GetBlockDocumentByName(ctx context.Context, slug, name string, includeSecrets bool) (*models.BlockDocument, error)
GetBlockDocumentByName retrieves a block document by name for a given block type slug.
func (*BlockTypesService) InstallSystemBlockTypes ¶
func (s *BlockTypesService) InstallSystemBlockTypes(ctx context.Context) error
InstallSystemBlockTypes installs the system block types.
func (*BlockTypesService) List ¶
func (s *BlockTypesService) List(ctx context.Context, filter *models.BlockTypeFilter, offset, limit int) ([]models.BlockType, error)
List retrieves block types with optional filtering.
func (*BlockTypesService) ListBlockDocumentsBySlug ¶
func (s *BlockTypesService) ListBlockDocumentsBySlug(ctx context.Context, slug string, includeSecrets bool) ([]models.BlockDocument, error)
ListBlockDocumentsBySlug retrieves all block documents for a block type identified by slug.
func (*BlockTypesService) Update ¶
func (s *BlockTypesService) Update(ctx context.Context, id uuid.UUID, req *models.BlockTypeUpdate) error
Update updates a block type.
type Client ¶
type Client struct {
// Services
Flows *FlowsService
FlowRuns *FlowRunsService
Deployments *DeploymentsService
TaskRuns *TaskRunsService
WorkPools *WorkPoolsService
WorkQueues *WorkQueuesService
Variables *VariablesService
Logs *LogsService
Admin *AdminService
BlockTypes *BlockTypesService
BlockSchemas *BlockSchemasService
BlockDocuments *BlockDocumentsService
BlockCapabilities *BlockCapabilitiesService
Artifacts *ArtifactsService
Automations *AutomationsService
Events *EventsService
SavedSearches *SavedSearchesService
ConcurrencyLimits *ConcurrencyLimitsService
ConcurrencyLimitsV2 *ConcurrencyLimitsV2Service
TaskWorkers *TaskWorkersService
FlowRunStates *FlowRunStatesService
TaskRunStates *TaskRunStatesService
// contains filtered or unexported fields
}
Client is the main client for interacting with the Prefect API.
type ConcurrencyLimitsService ¶
type ConcurrencyLimitsService struct {
// contains filtered or unexported fields
}
ConcurrencyLimitsService handles operations related to v1 concurrency limits.
func (*ConcurrencyLimitsService) Create ¶
func (s *ConcurrencyLimitsService) Create(ctx context.Context, req *models.ConcurrencyLimitCreate) (*models.ConcurrencyLimit, error)
Create creates a new concurrency limit.
func (*ConcurrencyLimitsService) DeleteByTag ¶
func (s *ConcurrencyLimitsService) DeleteByTag(ctx context.Context, tag string) error
DeleteByTag deletes a concurrency limit by tag.
func (*ConcurrencyLimitsService) Get ¶
func (s *ConcurrencyLimitsService) Get(ctx context.Context, id uuid.UUID) (*models.ConcurrencyLimit, error)
Get retrieves a concurrency limit by ID.
func (*ConcurrencyLimitsService) GetByTag ¶
func (s *ConcurrencyLimitsService) GetByTag(ctx context.Context, tag string) (*models.ConcurrencyLimit, error)
GetByTag retrieves a concurrency limit by tag.
func (*ConcurrencyLimitsService) Increment ¶
func (s *ConcurrencyLimitsService) Increment(ctx context.Context, names []string, slots int, mode string) ([]models.MinimalConcurrencyLimitResponse, error)
Increment increments concurrency limit slots.
func (*ConcurrencyLimitsService) List ¶
func (s *ConcurrencyLimitsService) List(ctx context.Context) ([]models.ConcurrencyLimit, error)
List retrieves concurrency limits with optional filtering.
func (*ConcurrencyLimitsService) ResetByTag ¶
func (s *ConcurrencyLimitsService) ResetByTag(ctx context.Context, tag string) error
ResetByTag resets a concurrency limit by tag.
type ConcurrencyLimitsV2Service ¶
type ConcurrencyLimitsV2Service struct {
// contains filtered or unexported fields
}
ConcurrencyLimitsV2Service handles operations related to v2 concurrency limits.
func (*ConcurrencyLimitsV2Service) Create ¶
func (s *ConcurrencyLimitsV2Service) Create(ctx context.Context, req *models.ConcurrencyLimitV2Create) (*models.ConcurrencyLimitV2, error)
Create creates a new v2 concurrency limit.
func (*ConcurrencyLimitsV2Service) Decrement ¶
func (s *ConcurrencyLimitsV2Service) Decrement(ctx context.Context, names []string, slots int) error
Decrement decrements active slots for v2 concurrency limits.
func (*ConcurrencyLimitsV2Service) DecrementWithLease ¶
func (s *ConcurrencyLimitsV2Service) DecrementWithLease(ctx context.Context, names []string, slots int, leaseID uuid.UUID) error
DecrementWithLease decrements active slots using a lease ID.
func (*ConcurrencyLimitsV2Service) Delete ¶
func (s *ConcurrencyLimitsV2Service) Delete(ctx context.Context, idOrName string) error
Delete deletes a v2 concurrency limit by ID or name.
func (*ConcurrencyLimitsV2Service) Get ¶
func (s *ConcurrencyLimitsV2Service) Get(ctx context.Context, idOrName string) (*models.ConcurrencyLimitV2, error)
Get retrieves a v2 concurrency limit by ID or name.
func (*ConcurrencyLimitsV2Service) Increment ¶
func (s *ConcurrencyLimitsV2Service) Increment(ctx context.Context, names []string, slots int, mode string) error
Increment increments active slots for v2 concurrency limits.
func (*ConcurrencyLimitsV2Service) IncrementWithLease ¶
func (s *ConcurrencyLimitsV2Service) IncrementWithLease(ctx context.Context, names []string, slots int, mode string) (*models.ConcurrencyLimitWithLeaseResponse, error)
IncrementWithLease increments active slots and returns a lease.
func (*ConcurrencyLimitsV2Service) List ¶
func (s *ConcurrencyLimitsV2Service) List(ctx context.Context) ([]models.GlobalConcurrencyLimitResponse, error)
List retrieves all v2 concurrency limits.
func (*ConcurrencyLimitsV2Service) RenewLease ¶
RenewLease renews a concurrency lease.
func (*ConcurrencyLimitsV2Service) Update ¶
func (s *ConcurrencyLimitsV2Service) Update(ctx context.Context, idOrName string, req *models.ConcurrencyLimitV2Update) error
Update updates a v2 concurrency limit.
type DeploymentsService ¶
type DeploymentsService struct {
// contains filtered or unexported fields
}
DeploymentsService handles operations related to deployments.
func (*DeploymentsService) Count ¶
func (s *DeploymentsService) Count(ctx context.Context, filter *models.DeploymentFilter) (int, error)
Count returns the number of deployments matching the filter.
func (*DeploymentsService) Create ¶
func (s *DeploymentsService) Create(ctx context.Context, req *models.DeploymentCreate) (*models.Deployment, error)
Create creates a new deployment.
func (*DeploymentsService) CreateFlowRun ¶
func (s *DeploymentsService) CreateFlowRun(ctx context.Context, id uuid.UUID, params map[string]interface{}) (*models.FlowRun, error)
CreateFlowRun creates a flow run from a deployment.
func (*DeploymentsService) CreateSchedules ¶
func (s *DeploymentsService) CreateSchedules(ctx context.Context, id uuid.UUID, schedules []models.DeploymentScheduleCreate) ([]models.DeploymentSchedule, error)
CreateSchedules creates schedules for a deployment.
func (*DeploymentsService) DeleteSchedule ¶
func (s *DeploymentsService) DeleteSchedule(ctx context.Context, deploymentID, scheduleID uuid.UUID) error
DeleteSchedule deletes a specific schedule from a deployment.
func (*DeploymentsService) Get ¶
func (s *DeploymentsService) Get(ctx context.Context, id uuid.UUID) (*models.Deployment, error)
Get retrieves a deployment by ID.
func (*DeploymentsService) GetByName ¶
func (s *DeploymentsService) GetByName(ctx context.Context, flowName, deploymentName string) (*models.Deployment, error)
GetByName retrieves a deployment by flow name and deployment name.
func (*DeploymentsService) GetSchedules ¶
func (s *DeploymentsService) GetSchedules(ctx context.Context, id uuid.UUID) ([]models.DeploymentSchedule, error)
GetSchedules retrieves all schedules for a deployment.
func (*DeploymentsService) List ¶
func (s *DeploymentsService) List(ctx context.Context, filter *models.DeploymentFilter, offset, limit int) (*pagination.PaginatedResponse[models.Deployment], error)
List retrieves a list of deployments with optional filtering.
func (*DeploymentsService) ListAll ¶
func (s *DeploymentsService) ListAll(ctx context.Context, filter *models.DeploymentFilter) *pagination.Iterator[models.Deployment]
ListAll returns an iterator for all deployments matching the filter.
func (*DeploymentsService) Update ¶
func (s *DeploymentsService) Update(ctx context.Context, id uuid.UUID, req *models.DeploymentUpdate) (*models.Deployment, error)
Update updates a deployment.
func (*DeploymentsService) UpdateSchedule ¶
func (s *DeploymentsService) UpdateSchedule(ctx context.Context, deploymentID, scheduleID uuid.UUID, req *models.DeploymentScheduleUpdate) error
UpdateSchedule updates a specific schedule for a deployment.
type EventsService ¶
type EventsService struct {
// contains filtered or unexported fields
}
EventsService handles operations related to events.
func (*EventsService) CountBy ¶
func (s *EventsService) CountBy(ctx context.Context, countable string, filter *models.EventFilter) ([]models.EventCount, error)
CountBy counts events grouped by a countable field.
func (*EventsService) List ¶
func (s *EventsService) List(ctx context.Context, filter *models.EventFilter) (*models.EventPage, error)
List retrieves events with filtering.
type FlowRunStatesService ¶
type FlowRunStatesService struct {
// contains filtered or unexported fields
}
FlowRunStatesService handles operations related to flow run states.
type FlowRunsService ¶
type FlowRunsService struct {
// contains filtered or unexported fields
}
FlowRunsService handles operations related to flow runs.
func (*FlowRunsService) Count ¶
func (s *FlowRunsService) Count(ctx context.Context, filter *models.FlowRunFilter) (int, error)
Count returns the number of flow runs matching the filter.
func (*FlowRunsService) Create ¶
func (s *FlowRunsService) Create(ctx context.Context, req *models.FlowRunCreate) (*models.FlowRun, error)
Create creates a new flow run.
func (*FlowRunsService) List ¶
func (s *FlowRunsService) List(ctx context.Context, filter *models.FlowRunFilter, offset, limit int) (*pagination.PaginatedResponse[models.FlowRun], error)
List retrieves a list of flow runs with optional filtering.
func (*FlowRunsService) ListAll ¶
func (s *FlowRunsService) ListAll(ctx context.Context, filter *models.FlowRunFilter) *pagination.Iterator[models.FlowRun]
ListAll returns an iterator for all flow runs matching the filter.
func (*FlowRunsService) SetState ¶
func (s *FlowRunsService) SetState(ctx context.Context, id uuid.UUID, state *models.StateCreate) (*models.FlowRun, error)
SetState sets the state of a flow run.
type FlowsService ¶
type FlowsService struct {
// contains filtered or unexported fields
}
FlowsService handles operations related to flows.
func (*FlowsService) Count ¶
func (s *FlowsService) Count(ctx context.Context, filter *models.FlowFilter) (int, error)
Count returns the number of flows matching the filter.
func (*FlowsService) Create ¶
func (s *FlowsService) Create(ctx context.Context, req *models.FlowCreate) (*models.Flow, error)
Create creates a new flow.
func (*FlowsService) List ¶
func (s *FlowsService) List(ctx context.Context, filter *models.FlowFilter, offset, limit int) (*pagination.PaginatedResponse[models.Flow], error)
List retrieves a list of flows with optional filtering.
func (*FlowsService) ListAll ¶
func (s *FlowsService) ListAll(ctx context.Context, filter *models.FlowFilter) *pagination.Iterator[models.Flow]
ListAll returns an iterator for all flows matching the filter.
type LogsService ¶
type LogsService struct {
// contains filtered or unexported fields
}
LogsService handles operations related to logs.
func (*LogsService) List ¶
func (l *LogsService) List(ctx context.Context, filter interface{}, offset, limit int) (*pagination.PaginatedResponse[models.Log], error)
List retrieves logs with filtering.
type Option ¶
Option is a functional option for configuring the client.
func WithAPIKey ¶
WithAPIKey sets the API key for authentication with Prefect Cloud.
func WithBaseURL ¶
WithBaseURL sets the base URL for the Prefect API.
func WithHTTPClient ¶
WithHTTPClient sets a custom HTTP client.
func WithTimeout ¶
WithTimeout sets the HTTP client timeout.
func WithUserAgent ¶
WithUserAgent sets a custom user agent string.
type SavedSearchesService ¶
type SavedSearchesService struct {
// contains filtered or unexported fields
}
SavedSearchesService handles operations related to saved searches.
func (*SavedSearchesService) Create ¶
func (s *SavedSearchesService) Create(ctx context.Context, req *models.SavedSearchCreate) (*models.SavedSearch, error)
Create creates a new saved search.
func (*SavedSearchesService) Get ¶
func (s *SavedSearchesService) Get(ctx context.Context, id uuid.UUID) (*models.SavedSearch, error)
Get retrieves a saved search by ID.
func (*SavedSearchesService) List ¶
func (s *SavedSearchesService) List(ctx context.Context) ([]models.SavedSearch, error)
List retrieves all saved searches.
type TaskRunStatesService ¶
type TaskRunStatesService struct {
// contains filtered or unexported fields
}
TaskRunStatesService handles operations related to task run states.
type TaskRunsService ¶
type TaskRunsService struct {
// contains filtered or unexported fields
}
TaskRunsService handles operations related to task runs.
func (*TaskRunsService) Count ¶
func (t *TaskRunsService) Count(ctx context.Context, filter *models.TaskRunFilter) (int, error)
Count returns the number of task runs matching the filter.
func (*TaskRunsService) Create ¶
func (t *TaskRunsService) Create(ctx context.Context, req *models.TaskRunCreate) (*models.TaskRun, error)
Create creates a new task run.
func (*TaskRunsService) List ¶
func (t *TaskRunsService) List(ctx context.Context, filter *models.TaskRunFilter, offset, limit int) (*pagination.PaginatedResponse[models.TaskRun], error)
List retrieves a list of task runs with optional filtering.
func (*TaskRunsService) ListAll ¶
func (t *TaskRunsService) ListAll(ctx context.Context, filter *models.TaskRunFilter) *pagination.Iterator[models.TaskRun]
ListAll returns an iterator for all task runs matching the filter.
type TaskWorkersService ¶
type TaskWorkersService struct {
// contains filtered or unexported fields
}
TaskWorkersService handles operations related to task workers.
func (*TaskWorkersService) List ¶
func (s *TaskWorkersService) List(ctx context.Context, filter *models.TaskWorkerFilter) ([]models.TaskWorkerResponse, error)
List retrieves task workers matching the filter.
type VariablesService ¶
type VariablesService struct {
// contains filtered or unexported fields
}
VariablesService handles operations related to variables.
func (*VariablesService) Count ¶
func (v *VariablesService) Count(ctx context.Context, filter *models.VariableFilter) (int, error)
Count returns the number of variables matching the filter.
func (*VariablesService) Create ¶
func (v *VariablesService) Create(ctx context.Context, req *models.VariableCreate) (*models.Variable, error)
Create creates a new variable.
func (*VariablesService) List ¶
func (v *VariablesService) List(ctx context.Context, filter *models.VariableFilter, offset, limit int) (*pagination.PaginatedResponse[models.Variable], error)
List retrieves a list of variables with optional filtering.
func (*VariablesService) ListAll ¶
func (v *VariablesService) ListAll(ctx context.Context, filter *models.VariableFilter) *pagination.Iterator[models.Variable]
ListAll returns an iterator for all variables matching the filter.
type WorkPoolsService ¶
type WorkPoolsService struct {
// contains filtered or unexported fields
}
WorkPoolsService handles operations related to work pools.
func (*WorkPoolsService) Count ¶
func (w *WorkPoolsService) Count(ctx context.Context, filter *models.WorkPoolFilter) (int, error)
Count returns the number of work pools matching the filter.
func (*WorkPoolsService) Create ¶
func (w *WorkPoolsService) Create(ctx context.Context, req *models.WorkPoolCreate) (*models.WorkPool, error)
Create creates a new work pool.
func (*WorkPoolsService) Delete ¶
func (w *WorkPoolsService) Delete(ctx context.Context, name string) error
Delete deletes a work pool by name.
func (*WorkPoolsService) List ¶
func (w *WorkPoolsService) List(ctx context.Context, filter *models.WorkPoolFilter, offset, limit int) ([]models.WorkPool, error)
List retrieves work pools with optional filtering.
func (*WorkPoolsService) Update ¶
func (w *WorkPoolsService) Update(ctx context.Context, name string, req *models.WorkPoolUpdate) error
Update updates a work pool.
type WorkQueuesService ¶
type WorkQueuesService struct {
// contains filtered or unexported fields
}
WorkQueuesService handles operations related to work queues.
func (*WorkQueuesService) Create ¶
func (w *WorkQueuesService) Create(ctx context.Context, req *models.WorkQueueCreate) (*models.WorkQueue, error)
Create creates a new work queue.
func (*WorkQueuesService) List ¶
func (w *WorkQueuesService) List(ctx context.Context, filter *models.WorkQueueFilter, offset, limit int) ([]models.WorkQueue, error)
List retrieves work queues with optional filtering.
func (*WorkQueuesService) Update ¶
func (w *WorkQueuesService) Update(ctx context.Context, id uuid.UUID, req *models.WorkQueueUpdate) error
Update updates a work queue.