Update Video
To edit the data in the specified collection with the specified parameters. When a JSON object is saved, the object properties are automatically added to the collection you specified.
Method : PUT
URL : /api/video
Body : JSON
{
"id": 1,
"title": "New Video",
"video_url": "https://youtu.be/_IzOqfrLc0o",
"hd_quality": true,
"island_id": 1,
"province_id": 1
}
id*Required
number
ID of video.
title*Required
string
Title of video.
video_url*Required
string
Video URL
hd_quality
boolean
Video quality
island_id
number
Video Island ID
province_id
number
Video Province ID
Response : 200 - OK
{
"message": "Success update video"
}
Response : 422 - Unprocessable Content
{
"error": [
{
"code": "too_small",
"minimum": 1,
"type": "string",
"inclusive": true,
"exact": false,
"message": "Title is required",
"path": ["title"]
},
{
"code": "too_small",
"minimum": 1,
"type": "string",
"inclusive": true,
"exact": false,
"message": "Video URL is required",
"path": ["video_url"]
}
]
}
Response : 404 - Not Found
Not Found
Response : 500 - Server Error
Internal Server Error