Integration Events

Overview

An Integration Event is the demand side of the Integration model. It subscribes a trigger on a scope to a target integration, with an optional message template and filter. A notification is delivered only when both an Integration Event exists and the target integration is supplied to the scope.

Per-scope resources

Each scope has its own resource type:

ResourceScopeScope field
snapcd_organization_integration_eventOrganization(none)
snapcd_stack_integration_eventStackstack_id
snapcd_namespace_integration_eventNamespacenamespace_id
snapcd_module_integration_eventModulemodule_id

All share these common fields:

FieldDescription
integration_idTarget integration
triggerWhat to fire on (see trigger catalog)
templateOptional message template; omit for the built-in default
filterOptional filter expression
is_disabledWhen true, the subscription is inert

Trigger catalog

GroupTriggers
Job lifecycleJobSucceeded, JobFailed, JobAwaitingApproval, JobCancelled
MissionMissionMilestoneReported

JobApproved and JobDeclined are defined in the enum but not yet wired to a consumer.

A mission’s milestones for a single mission are threaded under one Slack message.

Templates

Templates use {{ token }} substitution (no code execution). Unknown tokens render empty; omit template to use the built-in default for the trigger.

TokenAvailable for
{{trigger}}, {{moduleName}}, {{moduleId}}, {{organizationId}}all
{{stackName}}, {{namespaceName}}all
{{jobId}}, {{jobUrl}}job and milestone triggers
{{jobType}}job triggers (Apply / Destroy)
{{missionType}}, {{kind}}, {{message}}mission triggers

Example: ❌ {{jobType}} failed on *{{moduleName}}* ({{stackName}}/{{namespaceName}})\n{{jobUrl}}

Last updated on