PUT Videos
Overview
The following table contains information about the PUT method for managing the process for updating a specific video.
| PUT Video | |
|---|---|
| Method | PUT |
| URL or Endpoint | /api/projects/projectId/videos |
| Headers | Authorization |
| Parameters | projectId |
| Body | Check the request body below |
The description of the URL parameter is as follows:
| projectId Parameter | |
|---|---|
| URL Parameter Name | projectId |
| Mandatory | Yes |
| Type | string |
| Description | Unique Id of the project |
Request Body
{
"publicId": "string",
"name": "string",
"title": "string",
"description": "string",
"publishDate": "2024-05-21T08:03:40.817Z",
"publishEndDate": "2024-05-21T08:03:40.817Z",
"shareUrl": "string",
"publicAdScheduleId": "string",
"categoryId": 0,
"geoBlockingRuleId": 0,
"entityRestrictionId": 0,
"skipIntroState": true,
"skipIntroFrom": 0,
"skipIntroTo": 0,
"source": "string",
"author": "string",
"customOverlayState": true,
"videoLockState": true,
"lockAfter": 0,
"password": "string",
"passwordProtectedTitle": "string",
"passwordProtectedDescription": "string",
"chapterState": true,
"visibilityOptionId": 0,
"tagNames": [
"string"
],
"flagIds": [
0
],
"customParameters": [
{
"key": "string",
"value": "string"
}
],
"customOverlays": [
{
"caption": "string",
"secondsFrom": 0,
"secondsTo": 0,
"position": 1
}
],
"chapters": [
{
"title": "string",
"time": 0
}
]
}
Information about the fields that appear when you receive the response are displayed in the table below.
| Parameter Name | Mandatory | Type | Description |
|---|---|---|---|
| publicId | Yes | string | Public Id of the video |
| name | Yes | string | Name of the video |
| title | Yes | string | Title of the video |
| description | No | string | Description of the video |
| publishDate | Yes | Date | Publish date of the video |
| publishEndDate | No | Date | Publish end date of the video |
| shareUrl | No | string | A share URL redirects viewers to a custom destination when they share a video; if not provided, the player shares the video's embed location |
| publicAdScheduleId | No | string | The Id of the ad schedule |
| categoryId | No | integer($int32) | Id of the category |
| geoblockingRuleId | No | integer($int32) | Id of the geoblocking rule |
| entityRestrictionId | Yes | integer($int32) | Entity restriction Id |
| skipIntroState | No | bool | The state of the skip intro option |
| skipIntroFrom | No | integer($int32) | The amount of time the intro skips from |
| skipIntroTo | No | integer($int32) | The amount of time the intro skips to |
| source | No | string | The source of the video |
| author | No | string | The author of the video |
| customOverlayState | No | bool | State of custom overlays |
| videoLockState | No | bool | State of video lock |
| lockAfter | Yes | integer($int32) | Specifies duration before video is locked |
| password | Yes | string | Specifies the password for locked video |
| passwordProtectedTitle | No | string | Custom player title for password protected videos |
| passwordProtectedDescription | No | string | Custom player description for password protected videos |
| chapterState | No | bool | State of the chapters |
| visibilityOptionId | Yes | integer($int32) | Id of the visibility option |
| tagNames | No | array[string] | An array of video tags |
| flagIds | No | array[integer($int32)] | An array of flag Ids |
| customParameters | No | array[Object] | An array of custom parameters |
| key | Yes | string | The key of the custom parameter |
| value | Yes | string | The value of the custom parameter |
| customOverlays | No | array[Object] | An array of custom overlays |
| caption | Yes | string | Caption of custom overlay |
| secondsFrom | Yes | integer($int32) | Specifies start time in seconds |
| secondsTo | Yes | integer($int32) | Specifies end time in seconds |
| positon | Yes | integer($int32) | Specifies the position |
| chapters | No | array[Object] | An array of chapters |
| title | No | string | Title of chapter |
| time | Yes | integer($int32) | Specifies end time in seconds for the specific chapter |
Response
{
"success": true,
"errors": [],
"messages": [],
"result": {
"publicId": "{videoId}",
"id": "{videoId}",
"name": "{name}",
"title": "{title}",
"description": "",
"thumbnailUrl": "https://cdn.vpplayer.tech/{projectId}/encode/{videoId}/thumbnails/retina.jpg",
"filmstripUrl": "https://cdn.vpplayer.tech/{projectId}/encode/{videoId}/thumbnails/filmstrip0.jpg",
"filmstripVttUrl": "https://cdn.vpplayer.tech/{projectId}/encode/{videoId}/thumbnails/filmstrip.vtt",
"publishDate": "2024-05-21T10:01:11.833481",
"publishEndDate": null,
"shareUrl": "string",
"liveCutStartDate": null,
"liveCutEndDate": null,
"insertDate": "2024-05-21T08:01:05.4141661",
"publishStatusId": 2,
"publishStatusName": "Ready",
"duration": 150,
"userName": null,
"categoryId": null,
"publicAdScheduleId": null,
"restrictionId": null,
"skipIntroState": false,
"skipIntroFrom": null,
"skipIntroTo": null,
"geoBlockingRuleId": null,
"customOverlayState": false,
"chapterState": true,
"canEmbed": true,
"canPreview": true,
"source": "",
"author": "",
"isLive": "False",
"visibilityOptionId": 1,
"visibilityOption": "Public",
"videoLockState": false,
"lockAfter": 0,
"password": "1234",
"passwordProtectedTitle": "",
"passwordProtectedDescription": "",
"tagNames": [],
"customParameters": [],
"flagIds": null,
"geoBlockingRule": null,
"customOverlays": [
{
"caption": "hello",
"secondsFrom": 1,
"secondsTo": 63,
"position": 2
}
],
"chapters": [
{
"title": "Introduction",
"time": 50
},
{
"title": "Chapter 2",
"time": 90
},
{
"title": "End",
"time": 150
}
]
},
"resultInfo": null,
"statusCode": 200
}
Information about the fields that appear when you receive the response are displayed in the table below.
| Field Name | Type | Description |
|---|---|---|
| success | bool | If the response is successful it will return true. Otherwise will return false |
| errors | array[string] | Indicates if there was an error |
| messages | array[string] | Returns the response message from back-end |
| result | array[Object] | Returns the response object |
| publicId | string | Unique identifier for the video |
| Id | string | Unique identifier for the video |
| name | string | Name of the video |
| title | string | The title of the video |
| description | string | Description of the video |
| thumbnailUrl | string | URL of the video's thumbnail image |
| filmstripUrl | string | URL of the filmstrip image sequence |
| filmstripVttUrl | string | URL of the WebVTT file for the filmstrip |
| publishDate | Date | Date and time when the video was published |
| publishEndDate | Date | Date and time when video will not be available |
| shareUrl | String | A share URL redirects viewers to a custom destination when they share a video; if not provided, the player shares the video's embed location |
| liveCutStartDate | Date | Start date and time for a live cut |
| liveCutStartDate | Date | End date and time for a live cut |
| insertDate | Date | Date and time when the video was inserted |
| publishStatusId | integer($int32) | Id of the video's publish status |
| publishStatusName | string | The name of the publish status |
| duration | string | Duration of the video in seconds |
| userName | string | The name of the user who uploaded the video |
| categoryId | integer($int32) | Id of the category |
| publicAdScheduleId | string | The public Id of the ad schedule |
| restrictionId | integer($int32) | Id of the restriction |
| skipIntroState | boolean | The state of the skip intro option |
| skipIntroFrom | integer($int32) | The start time in seconds for skipping the intro |
| skipIntroTo | integer($int32) | The end time in seconds for skipping the intro |
| geoBlockingRuleId | integer($int32) | The Id of the geo blocking rule |
| customOverlayState | bool | Indicates whether custom overlays are enabled |
| chapterState | bool | Indicates whether chapters are enabled |
| canEmbed | bool | Indicates whether the video can be embedded |
| canPreview | bool | Indicates whether the video can be viewed |
| source | string | The source of the video |
| author | string | The author of the video |
| isLive | string | Indicates whether the video is live |
| visibilityOptionId | integer($int32) | The id of visibility option |
| visibilityOption | string | The name of the visibility option |
| videoLockState | bool | Indicates whether the video is locked |
| lockAfter | integer($int32) | The number of seconds after which the video locks |
| password | string | The password for accessing the video |
| passwordProtectedTitle | string | Custom player title for password protected videos |
| passwordProtectedDescription | string | Custom player description for password protected videos |
| tagNames | array[string] | An array of video tags |
| customParameters | array[Object] | An array of custom parameters |
| flagIds | array[integer($int32)] | An array of flag Ids |
| geoblockingRule | string | The geoblocking rule applied to the video |
| customOverlays | array[Object] | Return an array of custom overlays |
| caption | string | The text of the custom overlay |
| secondsFrom | integer($int32) | The start time in seconds |
| secondsTo | integer($int32) | The end time in seconds |
| positon | integer($int32) | The the position of custom overlay |
| chapters | array[Object] | Returns an array of chapters |
| title | string | The title of the chapter |
| time | integer($int32) | The end time for the specific chapter |
| resultInfo | string | Returns extra information about the result |
| statusCode | integer($int32) | Returns the HTTP Status Code |
If the action is successful, the service sends back an HTTP 200 or 201 response.
Errors
For information about the errors that are common to all actions, see Common Errors:
HTTP Status Code 400: Bad Request
HTTP Status Code 401: Unauthorized
HTTP Status Code 403: Forbidden
HTTP Status Code 404: Result Not Found
HTTP Status Code 500: Internal Server Error
HTTP Status Code 503: Backend Fetch Failed