VideoClip
Download previously recorded video clips and snapshot images.
Permissions required include Video playback and Camera live view.
|
|
Timestamps are in UTC in seconds since January 1, 1970, UTC (also called the Unix epoch). Convert the local time zone on FortiRecorder to UTC, and then convert to the Unix epoch relative timestamp. For example, January 1, 2025 at 1 PM EST may convert to 6 PM GMT, which is equivalent to an epoch timestamp of 1735754400. |
|
|
Most request JSON attributes are optional, not required. If a request does not include them, then the video is downloaded as-is. Time required to receive a response increases if you ask FortiRecorder to convert the video. Do not include optional attributes unless you want FortiRecorder to convert the video to a different size or quality, omit audio, etc. Conversion is best effort. It may not be possible in all cases to achieve a video clip with those exact characteristics. |
| HTTP Methods |
|
||||
| URL | https://HOST_OR_IP/api/v1/VideoClip |
||||
| Request JSON | {
"reqAction":21,
"camera":"CAMERA_NAME",
"audio":1,
"begin":1584734700,
"end":1584734900,
"height":1440,
"width":2560,
"fps":30,
"codec":"h265",
"gop":60,
"qvalue":50,
"bitrate":1000,
"osdFormat":"24h",
"osdPosition":"Top-Left"
}
where attributes are:
|
Example: Download an MP4 video
curl -X POST -H "Content-Type:application/json" -d "{\"reqAction\":21,\"camera\":\"CAMERA_NAME\",\"begin\":1762206615,\"end\":1762206675}" -b cookie.txt https://HOST_OR_IP/api/v1/VideoClip/ -o VIDEO_NAME.mp4
Example: Download a JPG snapshot image
curl -X POST -H "Content-Type:application/json" -d "{\"reqAction\" :21,\"camera\":\"CAMERA_NAME\",\"begin\":1735754400,\"end\":1735754400}" -b cookie.txt https://HOST_OR_IP/api/v1/VideoClip/ -o IMAGE_NAME.jpg