Media
Authentication
To manage media files from NVR, HTTP Basic / Digest and RTSP Digest authentication is required. The user must have permission to control system devices.
List
To get media list with HTTP GET method, use following HTTP path:
/api/media
Download
To download media file with HTTP GET method, use following HTTP path:
/api/media/FILENAME
the FILENAME
is the file name to be saved in the file system.
Upload
To upload media file with HTTP POST or PUT method, use following HTTP path:
/api/media/FILENAME
the FILENAME
is the file name to be saved in the file system.
If there is a duplicate file name, POST cannot upload the media file, and PUT overwrites it. and if the media file is in use, all method can not be uploaded.
Delete
To delete media file with HTTP DELETE method, use following HTTP path:
/api/media/FILENAME
the FILENAME
is the file name stored in the file system.
Rename
To rename media file with HTTP PATCH method, use following HTTP path:
/api/media/FILENAME?to=NEW
the FILENAME
is the media file name stored in the file system. the NEW
is the new media file name.
HTTP Response Code
Replies error status with following HTTP response code:
Code | Description |
---|---|
400 Bad Request | Bad request |
401 Unauthorized | Authentication failure |
403 Forbidden | There is no permission. |
404 Not Found | There is no media file. |
409 Conflict | There is duplicated media file. |
423 Locked | Media file is in use. |
503 Service Unavailable | The disk is not ready or there is a problem with the system. |
507 Insufficient Storage | There is out of disk space. |