Unicat API Reference

Up - API Reference - Home


/api/p/<project gid>/records/channels/copy_up

Requires JWT.

Copy a record's enabled channels to its ancestors.

Note: only the enabled channels!

This is meant to 'activate' the path to this record.

If a list of channels isn't provided, all enabled channels are copied upwards.

Note: the [all records] channel (__all__) will always stay on.

Request

POST /api/p/<project gid>/records/channels/copy_up
Authorization: Bearer <JWT>

{
    "record": "f2e64fe0-9ffa-4d9a-8750-d561d6542453",
    "channels": [
        "650ebd0f-eab5-41d7-87c1-1dc5334af872",
        "4782d5f5-b62b-4ecb-bf71-5be637a15dc5",
        "23d17876-e3cb-4acf-8eeb-a0154ca83a75"
    ]
}

record gid for the source record.

optional

channels a list of keys for the channels that must be copied; if not provided, all channels are copied upwards.

Success response

Authorization: <JWT>

{
    "success": true,
    "result": {},
    "data": {}
}

Error responses

400 Bad request - missing parameters or wrong type or value
401 Unauthorized - missing or expired JWT
403 Forbidden - not a member of this project
422 Unprocessable entity - parent record doesn't exist