OpenFolia

Start a change set

POST
/change-sets

Creates the change set’s own branch (change-sets/<id>, named by the server) at the base branch’s current commit, then records the change set and a change-set.create audit event. With maintenanceLine (a maintenance line’s ID) the base is the line’s branch: fixes to an older product revision, merged into it and released from it. Needs the content.edit permission.

Authorization

bearer
headerAuthorizationBearer <JWT>

A service account's token (ccms_sat_…, issued by POST /service-accounts/{id}/tokens), or, for local use and demo mode, the server's shared CCMS_API_TOKEN.

Header Parameters

X-Ccms-User?string

Demo mode only (CCMS_AUTH_MODE=demo): the user ID to act as. The bearer token is still required; without demo mode the header is refused (400).

Request Body

application/vnd.api+json
  1. body
data*

Response Body

application/vnd.api+json
  1. response
data*
Example Request
curl -X POST 'http://localhost:3000/change-sets' \  -H 'Content-Type: application/vnd.api+json' \  -d '{  "data": {    "type": "ChangeSet",    "attributes": {      "title": "string"    }  }}'
Example Response
{  "data": {    "type": "ChangeSet",    "id": "string",    "attributes": {      "title": "string",      "description": "string",      "state": "draft",      "author": {        "kind": "user",        "id": "string"      },      "baseRef": "string",      "baseCommit": "string",      "branch": "string",      "reviewHead": "string",      "mergeCommit": "string",      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    },    "meta": {      "branchMissing": true,      "behind": 0,      "base": {        "state": "current"      },      "supersededBy": "string",      "supersedes": "string"    }  }}