Documentation
¶
Index ¶
- func NewPanicableApplication(a core.Application) core.Application
- func NewPanicableComponent(c core.Component) core.Component
- func NewPanicableTrigger(t core.Trigger) core.Trigger
- func RegisterApplication(name string, i core.Application)
- func RegisterComponent(name string, c core.Component)
- func RegisterTrigger(name string, t core.Trigger)
- func RegisterWidget(name string, w core.Widget)
- type Integration
- type PanicableApplication
- func (s *PanicableApplication) CleanupWebhook(ctx core.CleanupWebhookContext) (err error)
- func (s *PanicableApplication) CompareWebhookConfig(a, b any) (result bool, err error)
- func (s *PanicableApplication) Components() []core.Component
- func (s *PanicableApplication) Configuration() []configuration.Field
- func (s *PanicableApplication) Description() string
- func (s *PanicableApplication) HandleRequest(ctx core.HTTPRequestContext)
- func (s *PanicableApplication) Icon() string
- func (s *PanicableApplication) Label() string
- func (s *PanicableApplication) ListResources(resourceType string, ctx core.ListResourcesContext) (resources []core.ApplicationResource, err error)
- func (s *PanicableApplication) Name() string
- func (s *PanicableApplication) SetupWebhook(ctx core.SetupWebhookContext) (metadata any, err error)
- func (s *PanicableApplication) Sync(ctx core.SyncContext) (err error)
- func (s *PanicableApplication) Triggers() []core.Trigger
- type PanicableComponent
- func (s *PanicableComponent) Actions() []core.Action
- func (s *PanicableComponent) Cancel(ctx core.ExecutionContext) (err error)
- func (s *PanicableComponent) Color() string
- func (s *PanicableComponent) Configuration() []configuration.Field
- func (s *PanicableComponent) Description() string
- func (s *PanicableComponent) Execute(ctx core.ExecutionContext) (err error)
- func (s *PanicableComponent) HandleAction(ctx core.ActionContext) (err error)
- func (s *PanicableComponent) HandleWebhook(ctx core.WebhookRequestContext) (status int, err error)
- func (s *PanicableComponent) Icon() string
- func (s *PanicableComponent) Label() string
- func (s *PanicableComponent) Name() string
- func (s *PanicableComponent) OutputChannels(config any) []core.OutputChannel
- func (s *PanicableComponent) ProcessQueueItem(ctx core.ProcessQueueContext) (id *uuid.UUID, err error)
- func (s *PanicableComponent) Setup(ctx core.SetupContext) (err error)
- type PanicableTrigger
- func (s *PanicableTrigger) Actions() []core.Action
- func (s *PanicableTrigger) Color() string
- func (s *PanicableTrigger) Configuration() []configuration.Field
- func (s *PanicableTrigger) Description() string
- func (s *PanicableTrigger) HandleAction(ctx core.TriggerActionContext) (result map[string]any, err error)
- func (s *PanicableTrigger) HandleWebhook(ctx core.WebhookRequestContext) (status int, err error)
- func (s *PanicableTrigger) Icon() string
- func (s *PanicableTrigger) Label() string
- func (s *PanicableTrigger) Name() string
- func (s *PanicableTrigger) Setup(ctx core.TriggerContext) (err error)
- type Registry
- func (r *Registry) GetApplication(name string) (core.Application, error)
- func (r *Registry) GetApplicationComponent(appName, componentName string) (core.Component, error)
- func (r *Registry) GetApplicationTrigger(appName, triggerName string) (core.Trigger, error)
- func (r *Registry) GetComponent(name string) (core.Component, error)
- func (r *Registry) GetEventHandler(integrationType string) (integrations.EventHandler, error)
- func (r *Registry) GetHTTPClient() *http.Client
- func (r *Registry) GetOIDCVerifier(integrationType string) (integrations.OIDCVerifier, error)
- func (r *Registry) GetTrigger(name string) (core.Trigger, error)
- func (r *Registry) GetWidget(name string) (core.Widget, error)
- func (r *Registry) HasIntegrationWithType(integrationType string) bool
- func (r *Registry) HasOIDCVerifier(integrationType string) bool
- func (r *Registry) Init()
- func (r *Registry) ListApplications() []core.Application
- func (r *Registry) ListComponents() []core.Component
- func (r *Registry) ListTriggers() []core.Trigger
- func (r *Registry) ListWidgets() []core.Widget
- func (r *Registry) NewResourceManager(ctx context.Context, integration *models.Integration) (integrations.ResourceManager, error)
- func (r *Registry) NewResourceManagerInTransaction(ctx context.Context, tx *gorm.DB, integration *models.Integration) (integrations.ResourceManager, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewPanicableApplication ¶
func NewPanicableApplication(a core.Application) core.Application
func RegisterApplication ¶
func RegisterApplication(name string, i core.Application)
func RegisterComponent ¶
func RegisterTrigger ¶
func RegisterWidget ¶ added in v0.0.18
Types ¶
type Integration ¶
type Integration struct {
EventHandler integrations.EventHandler
OIDCVerifier integrations.OIDCVerifier
NewResourceManager func(ctx context.Context, URL string, authenticate integrations.AuthenticateFn) (integrations.ResourceManager, error)
}
type PanicableApplication ¶
type PanicableApplication struct {
// contains filtered or unexported fields
}
* PanicableApplication wraps an Application implementation * around logic for handling panics.
func (*PanicableApplication) CleanupWebhook ¶
func (s *PanicableApplication) CleanupWebhook(ctx core.CleanupWebhookContext) (err error)
func (*PanicableApplication) CompareWebhookConfig ¶
func (s *PanicableApplication) CompareWebhookConfig(a, b any) (result bool, err error)
func (*PanicableApplication) Components ¶
func (s *PanicableApplication) Components() []core.Component
func (*PanicableApplication) Configuration ¶
func (s *PanicableApplication) Configuration() []configuration.Field
func (*PanicableApplication) Description ¶
func (s *PanicableApplication) Description() string
func (*PanicableApplication) HandleRequest ¶
func (s *PanicableApplication) HandleRequest(ctx core.HTTPRequestContext)
func (*PanicableApplication) Icon ¶
func (s *PanicableApplication) Icon() string
func (*PanicableApplication) Label ¶
func (s *PanicableApplication) Label() string
func (*PanicableApplication) ListResources ¶ added in v0.0.43
func (s *PanicableApplication) ListResources(resourceType string, ctx core.ListResourcesContext) (resources []core.ApplicationResource, err error)
func (*PanicableApplication) Name ¶
func (s *PanicableApplication) Name() string
* Non-panicking methods. * These are mostly definition methods, so they won't panic.
func (*PanicableApplication) SetupWebhook ¶
func (s *PanicableApplication) SetupWebhook(ctx core.SetupWebhookContext) (metadata any, err error)
func (*PanicableApplication) Sync ¶
func (s *PanicableApplication) Sync(ctx core.SyncContext) (err error)
* Panicking methods. * These are where the application logic is implemented, * so they could panic, and if they do, the system shouldn't crash.
func (*PanicableApplication) Triggers ¶
func (s *PanicableApplication) Triggers() []core.Trigger
type PanicableComponent ¶
type PanicableComponent struct {
// contains filtered or unexported fields
}
* PanicableComponent wraps a Component implementation * around logic for handling panics.
func (*PanicableComponent) Actions ¶
func (s *PanicableComponent) Actions() []core.Action
func (*PanicableComponent) Cancel ¶
func (s *PanicableComponent) Cancel(ctx core.ExecutionContext) (err error)
func (*PanicableComponent) Color ¶
func (s *PanicableComponent) Color() string
func (*PanicableComponent) Configuration ¶
func (s *PanicableComponent) Configuration() []configuration.Field
func (*PanicableComponent) Description ¶
func (s *PanicableComponent) Description() string
func (*PanicableComponent) Execute ¶
func (s *PanicableComponent) Execute(ctx core.ExecutionContext) (err error)
func (*PanicableComponent) HandleAction ¶
func (s *PanicableComponent) HandleAction(ctx core.ActionContext) (err error)
func (*PanicableComponent) HandleWebhook ¶
func (s *PanicableComponent) HandleWebhook(ctx core.WebhookRequestContext) (status int, err error)
func (*PanicableComponent) Icon ¶
func (s *PanicableComponent) Icon() string
func (*PanicableComponent) Label ¶
func (s *PanicableComponent) Label() string
func (*PanicableComponent) Name ¶
func (s *PanicableComponent) Name() string
* Non-panicking methods. * These are mostly definition methods, so they won't panic.
func (*PanicableComponent) OutputChannels ¶
func (s *PanicableComponent) OutputChannels(config any) []core.OutputChannel
func (*PanicableComponent) ProcessQueueItem ¶
func (s *PanicableComponent) ProcessQueueItem(ctx core.ProcessQueueContext) (id *uuid.UUID, err error)
func (*PanicableComponent) Setup ¶
func (s *PanicableComponent) Setup(ctx core.SetupContext) (err error)
* Panicking methods. * These are where the component logic is implemented, * so they could panic, and if they do, the system shouldn't crash.
type PanicableTrigger ¶
type PanicableTrigger struct {
// contains filtered or unexported fields
}
* PanicableTrigger wraps a Trigger implementation * around logic for handling panics.
func (*PanicableTrigger) Actions ¶
func (s *PanicableTrigger) Actions() []core.Action
func (*PanicableTrigger) Color ¶
func (s *PanicableTrigger) Color() string
func (*PanicableTrigger) Configuration ¶
func (s *PanicableTrigger) Configuration() []configuration.Field
func (*PanicableTrigger) Description ¶
func (s *PanicableTrigger) Description() string
func (*PanicableTrigger) HandleAction ¶
func (s *PanicableTrigger) HandleAction(ctx core.TriggerActionContext) (result map[string]any, err error)
func (*PanicableTrigger) HandleWebhook ¶
func (s *PanicableTrigger) HandleWebhook(ctx core.WebhookRequestContext) (status int, err error)
func (*PanicableTrigger) Icon ¶
func (s *PanicableTrigger) Icon() string
func (*PanicableTrigger) Label ¶
func (s *PanicableTrigger) Label() string
func (*PanicableTrigger) Name ¶
func (s *PanicableTrigger) Name() string
* Non-panicking methods. * These are mostly definition methods, so they won't panic.
func (*PanicableTrigger) Setup ¶
func (s *PanicableTrigger) Setup(ctx core.TriggerContext) (err error)
* Panicking methods. * These are where the component logic is implemented, * so they could panic, and if they do, the system shouldn't crash.
type Registry ¶
type Registry struct {
Encryptor crypto.Encryptor
Integrations map[string]Integration
Applications map[string]core.Application
Components map[string]core.Component
Triggers map[string]core.Trigger
Widgets map[string]core.Widget
// contains filtered or unexported fields
}
func NewRegistry ¶
func (*Registry) GetApplication ¶
func (r *Registry) GetApplication(name string) (core.Application, error)
func (*Registry) GetApplicationComponent ¶
func (*Registry) GetApplicationTrigger ¶
func (*Registry) GetComponent ¶
func (*Registry) GetEventHandler ¶
func (r *Registry) GetEventHandler(integrationType string) (integrations.EventHandler, error)
func (*Registry) GetHTTPClient ¶ added in v0.0.43
func (*Registry) GetOIDCVerifier ¶
func (r *Registry) GetOIDCVerifier(integrationType string) (integrations.OIDCVerifier, error)
func (*Registry) HasIntegrationWithType ¶
func (*Registry) HasOIDCVerifier ¶
func (*Registry) ListApplications ¶
func (r *Registry) ListApplications() []core.Application
func (*Registry) ListComponents ¶
func (*Registry) ListTriggers ¶
func (*Registry) ListWidgets ¶ added in v0.0.18
func (*Registry) NewResourceManager ¶
func (r *Registry) NewResourceManager(ctx context.Context, integration *models.Integration) (integrations.ResourceManager, error)
func (*Registry) NewResourceManagerInTransaction ¶
func (r *Registry) NewResourceManagerInTransaction(ctx context.Context, tx *gorm.DB, integration *models.Integration) (integrations.ResourceManager, error)