v1

latestOpenAPI 3.0.3MIT2026-07-1411163326.7 KB
Trigger

Get trigger

Get details for a trigger. Currently only supported for triggers where event_source.provider is github_oauth, github_app, github_server, bitbucket_dc, webhook, or schedule. Share feedback about our Project Administration APIs.

get/projects/{project_id}/triggers/{trigger_id}

Path parameters

project_idstring required

An opaque identifier of a project.

trigger_idstring required

An opaque identifier of a trigger.

Response

Successful response.

idstring uuid

The unique ID of the trigger.

event_namestring

The name of the event that will trigger the pipeline.

event_preset'all-pushes' | 'only-tags' | 'default-branch-pushes' | 'only-build-prs' | 'only-open-prs' | 'only-labeled-prs' | 'only-merged-prs' | 'only-ready-for-review-prs' | 'only-build-pushes-to-non-draft-prs' | 'only-merged-or-closed-prs' | 'pr-comment-equals-run-ci' | 'non-draft-pr-opened' | 'pushes-to-merge-queues'

The name of the event preset to use when filtering events for this trigger.

When event_source.provider is github_app or github_server, all preset values are supported.

When event_source.provider is github_oauth, this field is required and only the following values are accepted: all-pushes, only-build-prs.

Not applicable when event_source.provider is webhook or schedule.

checkout_refstring

The ref to use when checking out code for pipeline runs created from this trigger. If empty, the ref provided in the trigger event is used.

config_refstring

The ref to use when fetching config for pipeline runs created from this trigger. If empty, the ref provided in the trigger event is used.

disabledboolean

Whether the trigger is disabled. Not supported for triggers where event_source.provider is github_oauth.

parametersobject

Pipeline parameters passed when running pipelines from this trigger. Currently only supported for triggers where event_source.provider is schedule.

Example response

{
  "event_name": "some event name",
  "event_source": {
    "provider": "github_app",
    "repo": {
      "full_name": "some-org/some-repo-name",
      "external_id": "some-repo-id"
    },
    "webhook": {
      "url": "https://some-webhook.invalid/some-endpoint?secret=some-secret",
      "sender": "datadog"
    },
    "schedule": {
      "cron_expression": "*/5 * * * *"
    }
  },
  "event_preset": "all-pushes",
  "checkout_ref": "some-checkout-ref",
  "config_ref": "some-config-ref",
  "parameters": {
    "deploy_env": "staging"
  }
}