Skip to main content

Start Event

The codenow.ci.start.event indicates the beginning of a pipeline execution. It informs CodeNOW which pipeline was executed on which resource.

After CodeNOW receives the start event, a new build entry appears in the Build History with a running status.

info

For first-class CI providers (CodeNOW CI, GitHub Actions), the start event is triggered automatically. You only need to send this event manually when using Custom CI.

Payload Fields

FieldRequiredDescription
typeYesMust be codenow.ci.start.event
versionYesAPI version: application/vnd.codenow.v1+json
pipelineIdYesUnique identifier of the pipeline run — all events in the same run must share this ID
componentIdYesTechnical Name (ID) of the resource
buildVersionYesVersion string for the build (e.g., 0.0.1)
createdAtYesTimestamp in ISO 8601 format
actorNoObject with username and fullname of the user who triggered the build
pipelineNameNoName of the pipeline
dashboardUrlNoURL to the external CI dashboard for this build

Example

curl -L -X POST 'https://api.cloud.codenow.com/ci/webhook' \
--header 'Accept: application/vnd.codenow.v1+json' \
--header 'Content-Type: application/vnd.codenow.v1+json' \
--header 'X-Codenow-Api-Key: {YOUR_CI_KEY}' \
--data-raw '{
"type": "codenow.ci.start.event",
"version": "application/vnd.codenow.v1+json",
"pipelineId": "my-pipeline-id",
"componentId": "my-component-id",
"buildVersion": "0.0.1",
"createdAt": "2024-01-01T00:00:00.000Z",
"actor": {
"username": "johnsmith",
"fullname": "John Smith"
},
"pipelineName": "My Pipeline",
"dashboardUrl": "https://my-dashboard.com"
}'
tip

The pipelineId must be unique for each pipeline run. All subsequent result and end events must use the same pipelineId to be associated with this build.