Skip to content

Return pipeline ID when triggering build via API

Summary

When triggering a CI build via the API the ID of a TriggerRequest object is returned. This is unusable, when checking the pipeline using /api/v3/projects/:id/pipelines

Steps to reproduce

# curl -X POST -F token=token -F ref=master https://gitlab.com/api/v3/projects/1474823/trigger/builds
{"id":82787,"variables":null}

Expected behavior

Return pipeline ID

Actual behavior

Returns TriggerRequest object ID

ZD: https://gitlab.zendesk.com/agent/tickets/43838