Go to documentation repository
Documentation for Intellect 4.11.0-4.11.3. Documentation for other versions of Intellect is available too.
General request format:
curl -v "http://IP-address:port/web2/secure/video/action.do?fps={fps}&imageHeight={imageHeight}&login={login}&normalize={normalize}&password={password}&sessionid={sessionid}&version={version}&video_in={video_in}" --output ~/{output file}.bin
Request parameters:
Parameter | Is required | Description |
---|---|---|
version | Yes | See Product version. If version 4.10.0.0 is specified in request, then the stream obtained is in MJPEG format without XML inserts – it can be displayed on a web page using the IMG tag in Chrome and FireFox browsers. This feature is implemented for both live and archive video. Note. Not more than 6 video streams can be received simultaneously. |
video_in | Yes | Camera ID in the format "TYPE:ID", for example "CAM:1" |
sessionid | No | Session ID |
imageWidth | No | Frame width. Value can be in [64, 1600] range. Server automatically rounds width to larger value divisible by 4. If not, then the size of the returned image is taken from the video stream. |
imageHeight | No | Frame height. Value can be in [30, 1200] range. If not, then the size of the returned image is taken from the video stream. |
normalize | No | true - stretches the image if the frame comes in incorrect proportions |
fps | No | Video frame rate |
login | No | Intellect username, if set |
password | No | Intellect user password, if set |
output file name | Yes | The name of the file to which the requested video will be output |
Request example:
curl -v "http://127.0.0.1:8085/web2/secure/video/action.do?fps=1&imageHeight=360&login=1&normalize=true&password=1&sessionid=A4D98DDE-A535-49E4-9FB5-FAD441CBBA43&version=4.10.0.0&video_in=CAM:1" --output ~/output.bin
Response example:
% Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Connected to 172.19.2.6 (172.19.2.6) port 8085 (#0) * Server auth using Basic with user '1' > GET /web2/secure/video/action.do?fps=1&imageHeight=360&login=1&normalize=true&password=1&sessionid=A4D98DDE-A535-49E4-9FB5-FAD441CBBA43&version=4.10.0.0&video_in=CAM:1 HTTP/1.1 > Host: 172.19.2.6:8085 > Authorization: Basic MTox > User-Agent: curl/7.74.0 > Accept: */* > * Mark bundle as not supporting multiuse < HTTP/1.1 200 OK < Set-Cookie: JSESSIONID=ae532304-e6dc-4a19-8c4f-1e10656140f2; Path=/web2; HttpOnly < Set-Cookie: rememberMe=deleteMe; Path=/web2; Max-Age=0; Expires=Sun, 24-Jan-2021 08:09:52 GMT < Server: ITV-Intellect-Webserver/4.11.2.3000 < Date: Mon, 25 Jan 2021 08:09:52 GMT < Cache-Control: no-store, no-cache, must-revalidate, max-age=0 < Connection: close < Content-Type: multipart/x-mixed-replace;boundary=videoframe < Pragma: no-cache < X-CameraID: 1 < X-SessionID: A4D98DDE-A535-49E4-9FB5-FAD441CBBA43 < Closing connection 0 < { [32768 bytes data]
Response parameters:
The Content-Type header contains the following parameters:
Parameter | Description |
---|---|
multipart/x-mixed-replace | Indicates that each subsequent piece of content should replace the previous one |
boundary | Indicates a text separator between pieces of content |
Response example:
The output file will contain the following parameters for each piece of requested content:
--videoframe Content-Type: image/jpeg Content-Length: 93081 X-Width: 480 X-Height: 360 X-Timestamp: 0.000 X-Time: 2021-01-25T10:06:42.816+03:00
Response parameters:
Parameter | Description |
---|---|
Content-Type | Type of content |
Content-Length | Piece of content size |
X-Width | Image width |
X-Height | Image height |
X-Time | Absolute frame time |
X-Timestamp | Relative frame time in seconds (relative to the beginning of the stream) |
Response example:
If the stream ends due to the server failure, a final packet may be received:
--videoframe Content-Type: image/jpeg Content-Length: 106 <video_in> <sessionid>A4D98DDE-A535-49E4-9FB5-FAD441CBBA43</sessionid> <video_in>CAM:1</video_in> <newstate>closed</newstate> <errcode>103</errcode> </video_in>
Response parameters:
Parameter | Description |
---|---|
sessionid | session id (same as at start) |
video_in | Camera ID in the "TYPE:ID" format, for example, "CAM:1" |
errcode | Error code:
|