OpenFolia

Read a lock

GET
/locks/{lockId}

A lock the reader may not know of (as for the list: outside their scope, or, without content.read.draft, another holder's) is 404, exactly like a lock that does not exist.

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.

Path Parameters

lockId*string

The lock’s ID (a UUID). One that names no lock, malformed or not, is 404.

Formatuuid

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).

Response Body

application/vnd.api+json
  1. response
data*
Example Request
curl -X GET 'http://localhost:3000/locks/497f6eca-6276-4993-bfeb-53cbbbba6f08'
Example Response
{  "data": {    "type": "Lock",    "id": "string",    "attributes": {      "subject": {        "type": "module",        "lang": "string",        "moduleId": "string"      },      "holder": {        "kind": "user",        "id": "string"      },      "since": "2019-08-24T14:15:22Z"    },    "relationships": {      "changeSet": {        "data": {          "type": "ChangeSet",          "id": "string"        }      }    }  }}