Drafts
A release draft is a staging area for the artifacts and changes that will become a pipeline release. It lets a CI workflow prepare a release incrementally without starting deployment before everything is ready.
Each pipeline has a current draft. You can attach artifacts, record changes, and then start a release once preparation is complete. Starting the release consumes the draft, allowing the next release to be prepared.
/spaces/{spaceId}/pipelines/{pipelineName}/draftGETList the artifacts attached to the current draft.
Sample request
GET /spaces/space_123/pipelines/web/draft HTTP/1.1 Host: api.munchii.com Authorization: Bearer <access-token>Example response
HTTP/1.1 200 OK Content-Type: application/json { "data": [ { "name": "bundle", "size": 2048, "sha256": "0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef" } ] }Common errors
401The credentials are missing, expired, or invalid.403The caller lacks permission for this operation.404The space or pipeline was not found.
/spaces/{spaceId}/pipelines/{pipelineName}/draft/changesPUTReplace the change list on the current draft.
Sample request
PUT /spaces/space_123/pipelines/web/draft/changes HTTP/1.1 Host: api.munchii.com Authorization: Bearer <access-token> Content-Type: application/json { "changes": [ { "id": "a1b2c3d", "subject": "Update the web app", "parents": [ "f6e5d4c" ] } ] }Example response
HTTP/1.1 204 No ContentEmpty response body.
Common errors
400Use application/json and send valid JSON that matches the expected schema.401The credentials are missing, expired, or invalid.403The caller lacks permission for this operation.404The space or pipeline was not found.
/spaces/{spaceId}/pipelines/{pipelineName}/draft/resetPOSTClear the current draft.
Sample request
POST /spaces/space_123/pipelines/web/draft/reset HTTP/1.1 Host: api.munchii.com Authorization: Bearer <access-token>Example response
HTTP/1.1 204 No ContentEmpty response body.
Common errors
401The credentials are missing, expired, or invalid.403The caller lacks permission for this operation.404The space or pipeline was not found.
/spaces/{spaceId}/pipelines/{pipelineName}/draft/startPOSTStart a release using the draft’s artifacts and changes, then consume the draft.
Sample request
POST /spaces/space_123/pipelines/web/draft/start HTTP/1.1 Host: api.munchii.com Authorization: Bearer <access-token> Content-Type: application/json { "externalId": "build-42" }Example response
HTTP/1.1 204 No ContentEmpty response body.
Common errors
400The request is invalid or a draft artifact failed validation.401The credentials are missing, expired, or invalid.403The caller lacks permission for this operation.404The space or pipeline was not found.