Request
To create a cue point profile, send a POST request to:
https://<host>:<port>/config/csCueProfiles
Headers
-
Authorization– Keycloak access token for a user with theoperatorRolerole (see Accessing operator APIs using Keycloak) -
Content-Type: application/json
Mandatory arguments
The following argument is in the request body:
-
csCueProfileId– the ID of the profile. This can contain only letters, digits, hyphens, and underscores, and can be up to 100 characters long. You cannot change it later.
Other arguments
All the following arguments are in the request body:
-
csCueProfileName– the name of the profile -
csCueProfileDesc– a description of the profile -
csCueProfileEnabled– whether the profile is enabled (trueorfalse) -
csCueList– the profile's cue points. Each cue point has the following fields:-
name– a unique identifier or label for the cue point, for example,recapEndorendCreditsStart -
type– the category of the cue point, for example,recaporcredits -
description– a human-readable description of the cue point -
duration– the length of the section that the cue point marks, in milliseconds -
The position of the cue point. Specify exactly one of:
-
timeOffset– a time from the start of the content, in milliseconds -
timePercentage– a percentage of the content's duration, from the start (0–100) -
timeFromEnd– a time before the end of the content, in milliseconds -
timePercentageFromEnd– a percentage of the content's duration, from the end (0–100)
-
-
metadata– optional key/value pairs, in the following form:JSON[{ "key": "<key_name>", "value": "<value>" }]
-
In a cue point profile, duration and the timing fields must be whole numbers.
Example
A request with this payload creates a cue point profile for drama series that have a 60-second recap and two minutes of end credits:
{
"csCueProfileId": "drama-60s-recap",
"csCueProfileName": "Drama – 60-second recap",
"csCueProfileDesc": "For drama series with a 60-second recap and two minutes of end credits",
"csCueProfileEnabled": true,
"csCueList": [
{
"name": "recapEnd",
"type": "recap",
"description": "End of the recap of the previous episode",
"timeOffset": 60000
},
{
"name": "endCreditsStart",
"type": "credits",
"description": "Start of the end credits",
"timeFromEnd": 120000,
"metadata": [
{
"key": "buttonLabel",
"value": "Next episode"
}
]
}
]
}
Response
A successful request returns an HTTP 201 status. The response body contains the ID of the new profile, for example:
{
"id": "drama-60s-recap"
}
An unauthorised request returns an HTTP 401 status – for example, if the access token is invalid or has expired.
A forbidden request returns an HTTP 403 status – for example, if the request has no access token, or the user does not have the operatorRole role.
If csCueProfileId is missing, or a profile with the same ID already exists, the request returns an HTTP 500 status.
See also
For full details of this API, see the config-manager API documentation.