Skip to main content

Kargo Event Reference

This document contains a complete reference of all Kargo events, including their types and descriptions.

info

These events are always emitted by Kargo to the Kubernetes event log with the keys encoded in the annotations of the event. However, they are primarily consumed by the Pro version of Kargo (such as the Notification feature)

Event Fields​

Many Kargo events share common fields. The following sections describe these common fields, which are referenced in individual event definitions. Each field is given as it appears in the event payload (serialized as JSON) and, if optional, notes whether the type is a pointer when used in expr-lang expressions.

In each event definition in Event Types, the included fields are listed under "Payload Includes" with references to the relevant sections. All of the fields described in those events are found at the top level of the event payload unless otherwise noted.

Common Event Fields​

These fields are included in all Kargo events:

Field NameTypeDescriptionOptional
projectStringThe project name the event originated from.No
actorStringThe user or system that triggered the event.Yes (is pointer)
messageStringA human-readable message describing the event.No (may be empty)
idStringA unique identifier for the event.No

Freight Fields​

Freight payloads describe the collection of artifacts under evaluation or promotion.

Field NameTypeDescriptionOptional
nameStringName of the freight object.No
stageNameStringStage associated with the freight when the event fired.No
createTimeString (RFC3339)Creation timestamp of the freight object.No
aliasStringHuman-friendly alias assigned to the freight.Yes (is pointer)
commitsArray<GitCommit>Git commits that compose the freight (see GitCommit fields).Yes
imagesArray<Image>Container images included in the freight (see Image fields).Yes
chartsArray<Chart>Helm charts included in the freight (see Chart fields).Yes
artifactsArray<ArtifactReference>Additional arbitrary artifacts included in the freight (see ArtifactReference fields).Yes

GitCommit Fields​

Field NameTypeDescriptionOptional
repoURLStringURL of the Git repository.Yes
idStringCommit SHA in the referenced repository.Yes
branchStringBranch where the commit was discovered.Yes
tagStringTag that resolved to the commit.Yes
messageStringCommit message subject line.Yes
authorStringAuthor of the commit.Yes
committerStringCommitter recorded for the commit.Yes

Image Fields​

Field NameTypeDescriptionOptional
repoURLStringRepository that hosts the container image.Yes
tagStringMutable tag identifying a version of the image.Yes
digestStringImmutable digest identifying the image content.Yes
annotationsMap<String,String>Arbitrary metadata associated with the image.Yes

Chart Fields​

Field NameTypeDescriptionOptional
repoURLStringHelm chart repository URL.Yes
nameStringChart name within the repository (empty for OCI-style references).Yes
versionStringSpecific chart version selected for inclusion in the freight payload.Yes

ArtifactReference Fields​

Field NameTypeDescriptionOptional
artifactTypeStringUnique type of the artifact.No
subscriptionNameStringName of the subscription that discovered the artifact.No
versionStringVersion identifies a specific revision of this artifact.No
metadataMap<String,Object>Additional metadata associated with the artifact. It is a mostly opaque collection of attributes. "Mostly" because Kargo may understand how to interpret some documented, well-known, top-level keys. Those aside, this metadata is only understood by a corresponding Subscriber implementation that created it.Yes

Freight Verification Fields​

Freight verification metadata accompanies events emitted while verifying freight.

Field NameTypeDescriptionOptional
verificationStartTimeString (RFC3339)Timestamp when the verification run began.Yes (is pointer)
verificationFinishTimeString (RFC3339)Timestamp when the verification run finished.Yes (is pointer)
analysisRunNameStringName of the Argo Rollouts AnalysisRun created for the verification, if present.Yes (is pointer)
analysisTriggeredByPromotionStringName of the promotion that triggered the verification analysis run, if present.Yes (is pointer)

API Token Fields​

API token payloads describe the token Secret an event is about and the Kargo Role it belongs to.

Field NameTypeDescriptionOptional
nameStringName of the token (and its Secret).No
roleNameStringName of the Role the token is bound to.No
systemLevelBooleantrue when the Role is system-level, in which case project is not a Project.No

Promotion Fields​

Promotion payloads describe a promotion resource and the freight it targets.

Field NameTypeDescriptionOptional
freightObject (Freight fields)Snapshot of the freight referenced by the promotion.Yes (is pointer)
nameStringName of the promotion resource.No
stageNameStringStage targeted by the promotion.No
createTimeString (RFC3339)Creation timestamp of the promotion resource.No
applicationsArray<NamespacedName>Argo CD applications resolved for the promotion step.Yes
rollbackBooleanIndicates whether the promotion is a rollback.Yes

Applications Entry Fields​

Each promotion applications entry is a Kubernetes NamespacedName tuple.

Field NameTypeDescriptionOptional
namespaceStringNamespace that contains the Argo CD app.No
nameStringName of the Argo CD application.No

Event Types​

The complete list of built-in Kargo event types is provided below:

  • PromotionCreated
  • PromotionSucceeded
  • PromotionFailed
  • PromotionErrored
  • PromotionAborted
  • PromotionDiscarded
  • FreightCreated
  • FreightApproved
  • FreightVerificationSucceeded
  • FreightVerificationFailed
  • FreightVerificationErrored
  • FreightVerificationAborted
  • FreightVerificationInconclusive
  • FreightVerificationUnknown
  • APITokenCreated
  • APITokenDeleted

Below are the detailed definitions for each event type.

PromotionCreated​

This event is emitted when a promotion resource is created.

Payload Includes

PromotionSucceeded​

This event is emitted when a promotion completes successfully. The payload matches PromotionCreated with one additional field.

Payload Includes

Unique to this event:

Field NameTypeDescriptionOptional
verificationPendingBooleanIndicates whether post-promotion freight verification is still outstanding.Yes (is pointer)

PromotionFailed​

This event is emitted when a promotion fails, typically because a step or verification did not succeed.

Payload Includes

PromotionErrored​

This event is emitted when a promotion encounters an unexpected error.

Payload Includes

PromotionAborted​

This event is emitted when a promotion run is aborted before completion.

Payload Includes

PromotionDiscarded​

This event is emitted when the control plane removes a promotion that never started running, so that the reason it will not run is not lost along with it. Routine deletions by the garbage collector do not emit this event; those promotions already reached a terminal phase and reported an outcome of their own.

Payload Includes

FreightCreated​

This event is emitted when a new piece of freight is created by a warehouse or the API server.

Payload Includes

FreightApproved​

This event is emitted when freight is manually approved for a stage.

Payload Includes

FreightVerificationSucceeded​

This event is emitted when freight verification completes successfully.

Payload Includes

FreightVerificationFailed​

This event is emitted when freight verification completes with a failure.

Payload Includes

FreightVerificationErrored​

This event is emitted when freight verification encounters an unexpected error.

Payload Includes

FreightVerificationAborted​

This event is emitted when freight verification is aborted before completion.

Payload Includes

FreightVerificationInconclusive​

This event is emitted when freight verification finishes with an inconclusive result.

Payload Includes

FreightVerificationUnknown​

This event is emitted when freight verification ends in an unknown state.

Payload Includes

APITokenCreated​

This event is emitted by the API server when an API token is created. The project field is the namespace holding the token: the Project for a project-level token, or Kargo's own namespace for a system-level one, which systemLevel flags. The actor field identifies who created the token.

Payload Includes

APITokenDeleted​

This event is emitted by the API server when an API token is deleted through the Kargo API. It carries the same payload as APITokenCreated, describing the token as it was before deletion. Tokens removed by other means, such as kubectl or the deletion of their Role, do not emit it.

Payload Includes