Documentation
¶
Index ¶
- Constants
- func IsValidLocation(location string) bool
- type CircleCI
- func (c *CircleCI) Actions() []core.Action
- func (c *CircleCI) Cleanup(ctx core.IntegrationCleanupContext) error
- func (c *CircleCI) Components() []core.Component
- func (c *CircleCI) Configuration() []configuration.Field
- func (c *CircleCI) Description() string
- func (c *CircleCI) HandleAction(ctx core.IntegrationActionContext) error
- func (c *CircleCI) HandleRequest(ctx core.HTTPRequestContext)
- func (c *CircleCI) Icon() string
- func (c *CircleCI) Instructions() string
- func (c *CircleCI) Label() string
- func (c *CircleCI) ListResources(resourceType string, ctx core.ListResourcesContext) ([]core.IntegrationResource, error)
- func (c *CircleCI) Name() string
- func (c *CircleCI) Sync(ctx core.SyncContext) error
- func (c *CircleCI) Triggers() []core.Trigger
- type CircleCIWebhookHandler
- func (h *CircleCIWebhookHandler) Cleanup(ctx core.WebhookHandlerContext) error
- func (h *CircleCIWebhookHandler) CompareConfig(a, b any) (bool, error)
- func (h *CircleCIWebhookHandler) Merge(current, requested any) (any, bool, error)
- func (h *CircleCIWebhookHandler) Setup(ctx core.WebhookHandlerContext) (any, error)
- type Client
- func (c *Client) CheckPipelineStatus(pipelineID string) (*PipelineStatusResult, error)
- func (c *Client) CreateWebhook(name, webhookURL, secret, projectSlug string, events []string) (*WebhookResponse, error)
- func (c *Client) DeleteWebhook(webhookID string) error
- func (c *Client) GetCurrentUser() (*UserResponse, error)
- func (c *Client) GetPipeline(pipelineID string) (*PipelineResponse, error)
- func (c *Client) GetPipelineDefinitions(projectID string) ([]PipelineDefinitionResponse, error)
- func (c *Client) GetPipelineWorkflows(pipelineID string) ([]WorkflowResponse, error)
- func (c *Client) GetProject(projectSlug string) (*ProjectResponse, error)
- func (c *Client) GetWebhook(webhookID string) (*WebhookResponse, error)
- func (c *Client) GetWorkflow(workflowID string) (*WorkflowResponse, error)
- func (c *Client) ListWebhooks(projectSlug string) ([]WebhookResponse, error)
- func (c *Client) RunPipeline(projectSlug string, params RunPipelineParams) (*RunPipelineResponse, error)
- type Configuration
- type CreateWebhookParams
- type Metadata
- type OnWorkflowCompleted
- func (p *OnWorkflowCompleted) Actions() []core.Action
- func (p *OnWorkflowCompleted) Cleanup(ctx core.TriggerContext) error
- func (p *OnWorkflowCompleted) Color() string
- func (p *OnWorkflowCompleted) Configuration() []configuration.Field
- func (p *OnWorkflowCompleted) Description() string
- func (p *OnWorkflowCompleted) Documentation() string
- func (t *OnWorkflowCompleted) ExampleData() map[string]any
- func (p *OnWorkflowCompleted) HandleAction(ctx core.TriggerActionContext) (map[string]any, error)
- func (p *OnWorkflowCompleted) HandleWebhook(ctx core.WebhookRequestContext) (int, error)
- func (p *OnWorkflowCompleted) Icon() string
- func (p *OnWorkflowCompleted) Label() string
- func (p *OnWorkflowCompleted) Name() string
- func (p *OnWorkflowCompleted) Setup(ctx core.TriggerContext) error
- type OnWorkflowCompletedConfiguration
- type OnWorkflowCompletedMetadata
- type Parameter
- type PipelineDefinitionResponse
- type PipelineInfo
- type PipelineResponse
- type PipelineStatusResult
- type Project
- type ProjectResponse
- type RunPipeline
- func (t *RunPipeline) Actions() []core.Action
- func (t *RunPipeline) Cancel(ctx core.ExecutionContext) error
- func (t *RunPipeline) Cleanup(ctx core.SetupContext) error
- func (t *RunPipeline) Color() string
- func (t *RunPipeline) Configuration() []configuration.Field
- func (t *RunPipeline) Description() string
- func (t *RunPipeline) Documentation() string
- func (c *RunPipeline) ExampleOutput() map[string]any
- func (t *RunPipeline) Execute(ctx core.ExecutionContext) error
- func (t *RunPipeline) HandleAction(ctx core.ActionContext) error
- func (t *RunPipeline) HandleWebhook(ctx core.WebhookRequestContext) (int, error)
- func (t *RunPipeline) Icon() string
- func (t *RunPipeline) Label() string
- func (t *RunPipeline) Name() string
- func (t *RunPipeline) OutputChannels(configuration any) []core.OutputChannel
- func (t *RunPipeline) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
- func (t *RunPipeline) Setup(ctx core.SetupContext) error
- type RunPipelineExecutionMetadata
- type RunPipelineNodeMetadata
- type RunPipelineParams
- type RunPipelineResponse
- type RunPipelineSpec
- type UserResponse
- type WebhookConfiguration
- type WebhookMetadata
- type WebhookResponse
- type WorkflowInfo
- type WorkflowResponse
Constants ¶
View Source
const FailedOutputChannel = "failed"
View Source
const PayloadType = "circleci.workflow.completed"
View Source
const PollInterval = 5 * time.Minute
View Source
const ResourceTypePipelineDefinition = "pipeline-definition"
View Source
const SuccessOutputChannel = "success"
View Source
const WorkflowStatusCanceled = "canceled"
View Source
const WorkflowStatusFailed = "failed"
View Source
const WorkflowStatusSuccess = "success"
Variables ¶
This section is empty.
Functions ¶
func IsValidLocation ¶
Types ¶
type CircleCI ¶
type CircleCI struct{}
func (*CircleCI) Components ¶
func (*CircleCI) Configuration ¶
func (c *CircleCI) Configuration() []configuration.Field
func (*CircleCI) Description ¶
func (*CircleCI) HandleAction ¶
func (c *CircleCI) HandleAction(ctx core.IntegrationActionContext) error
func (*CircleCI) HandleRequest ¶
func (c *CircleCI) HandleRequest(ctx core.HTTPRequestContext)
func (*CircleCI) Instructions ¶
func (*CircleCI) ListResources ¶
func (c *CircleCI) ListResources(resourceType string, ctx core.ListResourcesContext) ([]core.IntegrationResource, error)
type CircleCIWebhookHandler ¶
type CircleCIWebhookHandler struct{}
func (*CircleCIWebhookHandler) Cleanup ¶
func (h *CircleCIWebhookHandler) Cleanup(ctx core.WebhookHandlerContext) error
func (*CircleCIWebhookHandler) CompareConfig ¶
func (h *CircleCIWebhookHandler) CompareConfig(a, b any) (bool, error)
func (*CircleCIWebhookHandler) Merge ¶
func (h *CircleCIWebhookHandler) Merge(current, requested any) (any, bool, error)
func (*CircleCIWebhookHandler) Setup ¶
func (h *CircleCIWebhookHandler) Setup(ctx core.WebhookHandlerContext) (any, error)
type Client ¶
type Client struct {
APIToken string
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient(http core.HTTPContext, ctx core.IntegrationContext) (*Client, error)
func (*Client) CheckPipelineStatus ¶
func (c *Client) CheckPipelineStatus(pipelineID string) (*PipelineStatusResult, error)
func (*Client) CreateWebhook ¶
func (c *Client) CreateWebhook(name, webhookURL, secret, projectSlug string, events []string) (*WebhookResponse, error)
func (*Client) DeleteWebhook ¶
func (*Client) GetCurrentUser ¶
func (c *Client) GetCurrentUser() (*UserResponse, error)
func (*Client) GetPipeline ¶
func (c *Client) GetPipeline(pipelineID string) (*PipelineResponse, error)
func (*Client) GetPipelineDefinitions ¶
func (c *Client) GetPipelineDefinitions(projectID string) ([]PipelineDefinitionResponse, error)
func (*Client) GetPipelineWorkflows ¶
func (c *Client) GetPipelineWorkflows(pipelineID string) ([]WorkflowResponse, error)
func (*Client) GetProject ¶
func (c *Client) GetProject(projectSlug string) (*ProjectResponse, error)
func (*Client) GetWebhook ¶
func (c *Client) GetWebhook(webhookID string) (*WebhookResponse, error)
func (*Client) GetWorkflow ¶
func (c *Client) GetWorkflow(workflowID string) (*WorkflowResponse, error)
func (*Client) ListWebhooks ¶
func (c *Client) ListWebhooks(projectSlug string) ([]WebhookResponse, error)
func (*Client) RunPipeline ¶
func (c *Client) RunPipeline(projectSlug string, params RunPipelineParams) (*RunPipelineResponse, error)
type Configuration ¶
type Configuration struct {
APIToken string `json:"apiToken"`
}
type CreateWebhookParams ¶
type OnWorkflowCompleted ¶
type OnWorkflowCompleted struct{}
func (*OnWorkflowCompleted) Actions ¶
func (p *OnWorkflowCompleted) Actions() []core.Action
func (*OnWorkflowCompleted) Cleanup ¶
func (p *OnWorkflowCompleted) Cleanup(ctx core.TriggerContext) error
func (*OnWorkflowCompleted) Color ¶
func (p *OnWorkflowCompleted) Color() string
func (*OnWorkflowCompleted) Configuration ¶
func (p *OnWorkflowCompleted) Configuration() []configuration.Field
func (*OnWorkflowCompleted) Description ¶
func (p *OnWorkflowCompleted) Description() string
func (*OnWorkflowCompleted) Documentation ¶
func (p *OnWorkflowCompleted) Documentation() string
func (*OnWorkflowCompleted) ExampleData ¶
func (t *OnWorkflowCompleted) ExampleData() map[string]any
func (*OnWorkflowCompleted) HandleAction ¶
func (p *OnWorkflowCompleted) HandleAction(ctx core.TriggerActionContext) (map[string]any, error)
func (*OnWorkflowCompleted) HandleWebhook ¶
func (p *OnWorkflowCompleted) HandleWebhook(ctx core.WebhookRequestContext) (int, error)
func (*OnWorkflowCompleted) Icon ¶
func (p *OnWorkflowCompleted) Icon() string
func (*OnWorkflowCompleted) Label ¶
func (p *OnWorkflowCompleted) Label() string
func (*OnWorkflowCompleted) Name ¶
func (p *OnWorkflowCompleted) Name() string
func (*OnWorkflowCompleted) Setup ¶
func (p *OnWorkflowCompleted) Setup(ctx core.TriggerContext) error
type OnWorkflowCompletedConfiguration ¶
type OnWorkflowCompletedConfiguration struct {
ProjectSlug string `json:"projectSlug"`
}
type OnWorkflowCompletedMetadata ¶
type OnWorkflowCompletedMetadata struct {
Project *Project `json:"project"`
}
type PipelineInfo ¶
type PipelineResponse ¶
type PipelineStatusResult ¶
type PipelineStatusResult struct {
AllDone bool
AnyFailed bool
Workflows []WorkflowResponse
IsErrorState bool
}
type ProjectResponse ¶
type RunPipeline ¶
type RunPipeline struct{}
func (*RunPipeline) Actions ¶
func (t *RunPipeline) Actions() []core.Action
func (*RunPipeline) Cancel ¶
func (t *RunPipeline) Cancel(ctx core.ExecutionContext) error
func (*RunPipeline) Cleanup ¶
func (t *RunPipeline) Cleanup(ctx core.SetupContext) error
func (*RunPipeline) Color ¶
func (t *RunPipeline) Color() string
func (*RunPipeline) Configuration ¶
func (t *RunPipeline) Configuration() []configuration.Field
func (*RunPipeline) Description ¶
func (t *RunPipeline) Description() string
func (*RunPipeline) Documentation ¶
func (t *RunPipeline) Documentation() string
func (*RunPipeline) ExampleOutput ¶
func (c *RunPipeline) ExampleOutput() map[string]any
func (*RunPipeline) Execute ¶
func (t *RunPipeline) Execute(ctx core.ExecutionContext) error
func (*RunPipeline) HandleAction ¶
func (t *RunPipeline) HandleAction(ctx core.ActionContext) error
func (*RunPipeline) HandleWebhook ¶
func (t *RunPipeline) HandleWebhook(ctx core.WebhookRequestContext) (int, error)
func (*RunPipeline) Icon ¶
func (t *RunPipeline) Icon() string
func (*RunPipeline) Label ¶
func (t *RunPipeline) Label() string
func (*RunPipeline) Name ¶
func (t *RunPipeline) Name() string
func (*RunPipeline) OutputChannels ¶
func (t *RunPipeline) OutputChannels(configuration any) []core.OutputChannel
func (*RunPipeline) ProcessQueueItem ¶
func (t *RunPipeline) ProcessQueueItem(ctx core.ProcessQueueContext) (*uuid.UUID, error)
func (*RunPipeline) Setup ¶
func (t *RunPipeline) Setup(ctx core.SetupContext) error
type RunPipelineExecutionMetadata ¶
type RunPipelineExecutionMetadata struct {
Pipeline PipelineInfo `json:"pipeline" mapstructure:"pipeline"`
}
type RunPipelineNodeMetadata ¶
type RunPipelineNodeMetadata struct {
ProjectID string `json:"projectId" mapstructure:"projectId"`
ProjectSlug string `json:"projectSlug" mapstructure:"projectSlug"`
ProjectName string `json:"projectName" mapstructure:"projectName"`
PipelineDefinitionID string `json:"pipelineDefinitionId" mapstructure:"pipelineDefinitionId"`
PipelineDefinitionName string `json:"pipelineDefinitionName" mapstructure:"pipelineDefinitionName"`
}
type RunPipelineParams ¶
type RunPipelineResponse ¶
type RunPipelineSpec ¶
type UserResponse ¶
type WebhookConfiguration ¶
type WebhookMetadata ¶
type WebhookResponse ¶
type WorkflowInfo ¶
Click to show internal directories.
Click to hide internal directories.