Skip to main contentIBM Video Streaming Developers

Manage video chapters

List all chapters of a video

Returns the details of all chapters for a specific video.

GET https://api.video.ibm.com/videos/{video_id}/chapters.json

Parameters

This request has no parameters.

Success response

Upon success a response with HTTP status “200 OK” is returned with an array under a chapters key. The elements of the array contain the following key-value pairs for each video chapter:

KEYTYPEDESCRIPTION
idstringChapter ID
titlestringChapter title
positionnumberThe beginning of the chapter, provided in seconds.

Example of a success response:

{
"chapters": [
{
"id": "17878",
"title": "First chapter",
"position": 10
},
{
"id": "17879",

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
401 UnauthorizedunauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request

Add new chapter to the video

Set title and position of a new chapter for a video.

POST https://api.video.ibm.com/videos/{video_id}/chapters.json

Parameters

The parameters for the POST request:

PARAMETERTYPEIMPORTANCEDESCRIPTION
titlestringREQUIREDChapter title
positionintegerREQUIREDThe beginning of the chapter, provided in seconds.

Success response

Upon success, a response with HTTP status “201 Created” is returned with the following key-value pairs under a chapters key.

KEYTYPEDESCRIPTION
idstringChapter ID
titlestringChapter title
positionnumberThe beginning of the chapter, provided in seconds.

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
400 Bad Requestinvalid_valueValidation failed
401 UnauthorizedunauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request

Get chapter info

Returns the information on a specific chapter of a video.

GET https://api.video.ibm.com/videos/{video_id}/chapters/{chapter_id}.json

Parameters

This request has no parameters.

Success response

Upon success a response with HTTP status “200 OK” is returned with the following key-value pairs under a chapter key.

KEYTYPEDESCRIPTION
idstringChapter ID
titlestringChapter title
positionnumberThe beginning of the chapter, provided in seconds.

Example of a success response:

{
"chapter": {
"id": "17878",
"title": "First chapter",
"position": 10
}
}

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
401 UnauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo or chapter was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request

Modify video chapter

Change title or position of an existing video chapter.

PUT https://api.video.ibm.com/videos/{video_id}/chapters/{chapter_id}.json

Parameters

The parameters for the PUT request:

PARAMETERTYPEIMPORTANCEDESCRIPTION
titlestringREQUIREDChapter title
positionintegerREQUIREDThe beginning of the chapter, provided in seconds.

Success response

Upon success a response with HTTP status “200 OK” is returned.

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
400 Bad Requestinvalid_valueValidation failed
401 UnauthorizedunauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo or chapter was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request

Delete video chapter

Delete an existing video chapter.

DELETE https://api.video.ibm.com/videos/{video_id}/chapters/{chapter_id}.json

Parameters

This request has no parameters.

Success response

Upon success a response with HTTP status “200 OK” is returned.

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
400 Bad Requestinvalid_valueValidation failed
401 UnauthorizedunauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo or chapter was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request

Delete all chapters of a video

Delete all existing chapters of a video.

DELETE https://api.video.ibm.com/videos/{video_id}/chapters.json

Parameters

This request has no parameters.

Success response

Upon success a response with HTTP status “200 OK” is returned.

Error responses

Possible error responses:

HTTP RESPONSE CODEERROR VALUEERROR CONDITIONS
400 Bad Requestinvalid_valueValidation failed
401 UnauthorizedunauthorizedThe provided access token is missing, revoked, expired or malformed
403 Forbiddenlack_of_ownershipThe API user is not allowed to manage the given video
404 Not Foundnot_foundVideo or chapter was not found
429 Too Many Requeststoo_many_requestsRate limit exceeded (Read more)
503 Service UnavailableThere is a temporary error on the server which makes it impossible to serve the request