Amcrest HTTP API SDK Specification

Page 1
Amcrest HTTP API SDK Protocol Specification
Amcrest Technologies LLC | www.amcrest.com
Revision 2.10 2016-05-25
Page 2

Document History

2016
A
2016
Add API
2016
Add Chapter Bosch APIs
2016
2016
1 Modify API
2 Add
2016
Add chapter
2016
Modify API Find logs
201
Add API
2016
Add API
2016
Add
2016
Amcrest Technologies LLC | www.amcrest.com
No Release Notes Date Version
1
2
3
4
5 Add API getLimitState
6
7
8
9
d on Old Version
dd API Get max remote input channels
PTZ Move directly
Control the playback stream
auxiliary gap extend header
Record files protection
Create a motion file finder
-6-20 2.0
-6-30 2.01
-8-10 2.02
-8-16 2.03
-8-16 2.04
-8-20 2.05
-8-20 2.06
6-08-31 2.07
-09-01 2.08
10
11
Get daylight
H.265 Support
-09-01 2.09
-09-06 2.10
Page 3

Contents

Amcrest Technologies LLC | www.amcrest.com
1
1 O
verview ........................................................................................................................................................... 10
2 References ......................................................................................................................................................... 10
3 Definitions ......................................................................................................................................................... 10
3.1 Abbreviations ...................................................................................................................................... 10
3.2 Syntax convention ............................................................................................................................... 10
3.3 API format ........................................................................................................................................... 11
3.4 Server responses.................................................................................................................................. 12
3.5 Authentication .................................................................................................................................... 13
4 General APIs ...................................................................................................................................................... 14
4.1 APIs of RTSP ........................................................................................................................................ 14
4.1.1 Get real-time stream ................................................................................................................................ 14
4.1.2 Get playback stream ................................................................................................................................ 15
4.1.3 Get file stream ......................................................................................................................................... 16
4.2 Special APIs ......................................................................................................................................... 16
4.2.1 Get mjpg stream ...................................................................................................................................... 16
4.2.2 Get real-time stream ................................................................................................................................ 17
4.2.3 Get playback stream ................................................................................................................................ 18
4.2.4 Control the playback stream .................................................................................................................... 19
4.3 Audio .................................................................................................................................................. 20
4.3.1 Get audio input channel numbers ........................................................................................................... 20
4.3.2 Get audio output channel numbers ........................................................................................................ 20
4.3.3 Post audio stream .................................................................................................................................... 20
4.3.4 Get audio stream ..................................................................................................................................... 22
4.4 Snapshot ............................................................................................................................................. 24
4.4.1 Sna
p ......................................................................................................................................................... 24
Page 4
4.4.2 Get a snapshot ......................................................................................................................................... 26
Amcrest Technologies LLC | www.amcrest.com
2
4.4.3 Subscribe to snapshot .............................................................................................................................. 26
4.5 Video attributes .................................................................................................................................. 28
4.5.1 Get max extra stream numbers ............................................................................................................... 28
4.5.2 Video color config .................................................................................................................................... 28
4.5.3 Get encode capability .............................................................................................................................. 30
4.5.4 Get encode config capability ................................................................................................................... 31
4.5.5 Encode of media ...................................................................................................................................... 35
4.5.6 Encode of region interested ..................................................................................................................... 41
4.5.7 Channel title............................................................................................................................................. 42
4.5.8 Get video input channels device supported ............................................................................................ 43
4.5.9 Get video output channels device supported .......................................................................................... 43
4.5.10 Get max remote input channels .............................................................................................................. 44
4.5.11 Video standard ........................................................................................................................................ 44
4.5.12 Video widget ............................................................................................................................................ 45
4.5.13 Get video input capability ........................................................................................................................ 48
4.5.14 Adjust focus ............................................................................................................................................. 53
4.5.15 Adjust focus continuously ........................................................................................................................ 54
4.5.16 Auto focus ................................................................................................................................................ 55
4.5.17 Get focus status ....................................................................................................................................... 55
4.5.18 Get coordinates of current window ......................................................................................................... 55
4.5.19 Set coordinates of current window ......................................................................................................... 56
4.5.20 Video in options....................................................................................................................................... 56
4.5.21 Video out ................................................................................................................................................. 69
4.6 System ................................................................................................................................................ 71
4.6.1 General .................................................................................................................................................... 71
4.6.2 Get current time ...................................................................................................................................... 72
.6.3 Set current time ....................................................................................................................................... 73
4
4.6.4 Locales ..................................................................................................................................................... 73
Page 5
4.6.5 Get language capability ........................................................................................................................... 76
Amcrest Technologies LLC | www.amcrest.com
3
4.6.6 Language .................................................................................................................................................. 76
4.6.7 Client access filter .................................................................................................................................... 77
4.6.8 Auto maintain .......................................................................................................................................... 78
4.6.9 Holiday management ............................................................................................................................... 80
4.6.10 Get device type ........................................................................................................................................ 81
4.6.11 Get hardware version .............................................................................................................................. 82
4.6.12 Get serial number of device..................................................................................................................... 82
4.6.13 Get machine name .................................................................................................................................. 82
4.6.14 Get system information ........................................................................................................................... 82
4.6.15 Get vendor information ........................................................................................................................... 83
4.6.16 Get software information ........................................................................................................................ 83
4.6.17 Get version of Onvif ................................................................................................................................. 83
4.6.18 Get version of HTTP API ........................................................................................................................... 84
4.6.19 Get device class ....................................................................................................................................... 84
4.6.20 Onvif service authorization ...................................................................................................................... 84
4.6.21 Backup of config ...................................................................................................................................... 85
4.6.22 Restore the config .................................................................................................................................... 86
4.6.23 Restore except the config ........................................................................................................................ 86
4.6.24 Reboot ..................................................................................................................................................... 87
4.6.25 Shutdown ................................................................................................................................................. 87
4.7 Network .............................................................................................................................................. 87
4.7.1 Get network interfaces ............................................................................................................................ 87
4.7.2 Network basic config ............................................................................................................................... 88
4.7.3 PPPoE ....................................................................................................................................................... 90
4.7.4 DDNS ........................................................................................................................................................ 91
5 Email ........................................................................................................................................................ 93
4.7.
4.7.6 WLan ........................................................................................................................................................ 95
4.7.7 Scan Wlan devices ................................................................................................................................... 97
Page 6
4.7.8 UPnP ........................................................................................................................................................ 98
Amcrest Technologies LLC | www.amcrest.com
4
4.7.9 Get UPnP status ..................................................................................................................................... 100
4.7.10 NTP......................................................................................................................................................... 100
4.7.11 RTSP ....................................................................................................................................................... 101
4.7.12 Telnet ..................................................................................................................................................... 102
4.7.13 Alarm server .......................................................................................................................................... 103
4.8 Motion Detection .............................................................................................................................. 104
4.8.1 Motion Detection Settings ..................................................................................................................... 104
4.9 Event ................................................................................................................................................. 111
4.9.1 Event handler ......................................................................................................................................... 111
4.9.2 Alarm event ........................................................................................................................................... 115
4.9.3 Alarm out ............................................................................................................................................... 117
4.9.4 Get alarm input channels ...................................................................................................................... 118
4.9.5 Get alarm output channels .................................................................................................................... 118
4.9.6 Get states of alarm input channels ........................................................................................................ 118
4.9.7 Get states of alarm input channels ........................................................................................................ 119
4.9.8 Video blind event................................................................................................................................... 119
4.9.9 Video loss event .................................................................................................................................... 120
4.9.10 Login failure event ................................................................................................................................. 121
4.9.11 Storage not exist event .......................................................................................................................... 122
4.9.12 Storage access failure event .................................................................................................................. 123
4.9.13 Storage low space event ........................................................................................................................ 124
4.9.14 Net abort event...................................................................................................................................... 125
4.9.15 IP conflict event ..................................................................................................................................... 126
4.9.16 Get channels event happened ............................................................................................................... 127
4.9.17 Subscribe to event message .................................................................................................................. 128
18 Get capability of event management .................................................................................................... 130
4.9.
4.10 PTZ .................................................................................................................................................... 131
4.10.1 PTZ config............................................................................................................................................... 131
Page 7
4.10.2 PTZ auto movement............................................................................................................................... 133
Amcrest Technologies LLC | www.amcrest.com
5
4.10.3 Get PTZ protocol list............................................................................................................................... 135
4.10.4 Get PTZ capability of current protocol ................................................................................................... 135
4.10.5 Get PTZ presets list ................................................................................................................................ 137
4.10.6 Get PTZ tour routines list ....................................................................................................................... 138
4.10.7 PTZ control command ............................................................................................................................ 138
4.10.8 Get PTZ status ........................................................................................................................................ 142
4.10.9 PTZ Move directly .................................................................................................................................. 143
4.11 Record ............................................................................................................................................... 143
4.11.1 Get capability of recording .................................................................................................................... 143
4.11.2 Record config ......................................................................................................................................... 144
4.11.3 Record mode .......................................................................................................................................... 146
4.11.4 Media global .......................................................................................................................................... 147
4.11.5 Find media files ...................................................................................................................................... 147
4.11.6 Download media file with the file name ............................................................................................... 150
4.11.7 Download media file between times ..................................................................................................... 151
4.12 User management ............................................................................................................................. 152
4.12.1 Get information of a particular user ...................................................................................................... 152
4.12.2 Get information of all users ................................................................................................................... 152
4.12.3 Get information of all active users ......................................................................................................... 153
4.12.4 Get information of a particular group ................................................................................................... 153
4.12.5 Get information of all groups ................................................................................................................. 154
4.12.6 Add a new user ...................................................................................................................................... 154
4.12.7 Delete a user .......................................................................................................................................... 155
4.12.8 Modify user information ........................................................................................................................ 155
4.12.9 Modify user’s password ......................................................................................................................... 156
4.13 Log .................................................................................................................................................... 156
4.13.1 F
ind logs ................................................................................................................................................. 156
4.13.2 Clear all the logs..................................................................................................................................... 158
Page 8
4.13.3 Backup logs ............................................................................................................................................ 158
Amcrest Technologies LLC | www.amcrest.com
6
5 SD camera APIs ................................................................................................................................................ 159
5.1 Video attributes ................................................................................................................................ 159
5.1.1 Video in focus ........................................................................................................................................ 159
5.1.2 Video in zoom ........................................................................................................................................ 161
5.1.3 Video in sharpness................................................................................................................................. 163
5.1.4 Video in mode ....................................................................................................................................... 164
5.2
Wiper ......................................................................................................................................... 167
5.2.1 Mo
ve continuously ................................................................................................................................ 167
5.2.2 Stop move .............................................................................................................................................. 167
5.2.3 Move once ............................................................................................................................................. 168
6 Storage APIs ..................................................................................................................................................... 168
6.1 Storage devices .................................................................................................................................. 168
6.1.1 Get hard disk information ...................................................................................................................... 168
6.1.2 Get all the storage devices’ names ........................................................................................................ 169
6.1.3 Get storage device information ............................................................................................................. 169
6.1.4 Get storage capability ............................................................................................................................ 170
6.2 NAS ................................................................................................................................................... 170
6.2.1 NAS information .................................................................................................................................... 170
6.3 Storage point ..................................................................................................................................... 172
6.3.1 Record storage point .............................................................................................................................. 172
6.3.2 Storage group ........................................................................................................................................ 173
7 Display APIs ..................................................................................................................................................... 175
7.1 GUI ................................................................................................................................................... 175
7.1.1 GUISet .................................................................................................................................................... 175
7.2 Split screen ........................................................................................................................................ 177
7.2.1 Spl
it screen mode .................................................................................................................................. 177
7.3 Moniter tour...................................................................................................................................... 178
7.3.1 Moniter tour .......................................................................................................................................... 178
Page 9
7.3.2 Enable tour ............................................................................................................................................ 180
Amcrest Technologies LLC | www.amcrest.com
7
7.3.3 Monitor collection ................................................................................................................................. 180
8 Video analyse APIs ........................................................................................................................................... 182
8.1 Video analyse .................................................................................................................................... 182
8.1.1 Get video analyse capability .................................................................................................................. 182
8.1.2 Video analyse global .............................................................................................................................. 183
8.1.3 Video analyse rule ................................................................................................................................. 184
8.2 Number of people .............................................................................................................................. 187
8.2.1 Video widget number status ................................................................................................................. 187
8.2.2 Get heat map information ..................................................................................................................... 188
8.3 Video status ...................................................................................................................................... 189
8.3.1 Get summary of video status ................................................................................................................. 189
8.3.2 Query video status ................................................................................................................................. 190
9 Intelligent traffic APIs ....................................................................................................................................... 191
9.1 Traffic snap ........................................................................................................................................ 191
9.1.1 Get the specific parking space status .................................................................................................... 191
9.2 Traffic parking .................................................................................................................................... 192
9.2.1 Get all parking spaces’ status ................................................................................................................. 192
10 Thermography and radiometry APIs ........................................................................................................... 193
10.1 Thermography manager ..................................................................................................................... 193
10.1.1 Get capability of thermography ............................................................................................................. 193
10.1.2 Thermography options .......................................................................................................................... 194
10.1.3 Get extern system information .............................................................................................................. 197
10.1.4 Get information of preset mode ............................................................................................................ 197
10.1.5 Get optimized region information ......................................................................................................... 198
10.1.6 Enable shutter ........................................................................................................................................ 198
7 Fix focus ................................................................................................................................................. 199
10.1.
10.1.8 Do flat field correction ........................................................................................................................... 199
10.2 Radiometry ....................................................................................................................................... 200
Page 10
10.2.1 Get capability of radiometry .................................................................................................................. 200
Amcrest Technologies LLC | www.amcrest.com
8
10.2.2 Heat image thermometry ...................................................................................................................... 201
10.2.3 Thermometry rule ................................................................................................................................. 203
10.2.4 Heat image temper event ...................................................................................................................... 206
10.2.5 Get temperature of particular point ...................................................................................................... 207
10.2.6 Get temperature of particular condition ............................................................................................... 207
10.2.7 Query temperature information ............................................................................................................ 208
10.2.8 Subscribe to temperature information .................................................................................................. 210
10.2.9 Subscribe to radiometry data ................................................................................................................ 211
10.2.10 To fetch radiometry data ....................................................................................................................... 212
11 Access control APIs ................................................................................................................................... 212
11.1 Door .................................................................................................................................................. 212
11.1.1 Open door .............................................................................................................................................. 212
11.1.2 Get door status ...................................................................................................................................... 213
12 Intelligent building APIs............................................................................................................................. 214
12.1 Video talk .......................................................................................................................................... 214
12.1.1 Subscribe video talk status .................................................................................................................... 214
12.1.2 Unsubscribe video talk status ................................................................................................................ 215
12.1.3 Invite server on video talk ..................................................................................................................... 215
12.1.4 Cancel the video talk ............................................................................................................................. 215
12.1.5 Answer the invitation............................................................................................................................. 216
12.1.6 Refuse to answer the video talk invitation ............................................................................................ 216
12.1.7 Hang up .................................................................................................................................................. 216
12.2 Video talk log .................................................................................................................................... 217
12.2.1 Query video talk log ............................................................................................................................... 217
12.3 Access control card record .................................................................................................................. 218
12.3.1 Query record .......................................................................................................................................... 218
2 Update record ........................................................................................................................................ 219
12.3.
12.3.3 Insert record .......................................................................................................................................... 220
Page 11
12.3.4 Remove record ....................................................................................................................................... 220
Amcrest Technologies LLC | www.amcrest.com
9
12.3.5 Get the total number of records ............................................................................................................ 221
12.4 Swiping Access control card record ..................................................................................................... 221
12.4.1 Query swiping card records ................................................................................................................... 221
12.5 Announcement record ....................................................................................................................... 223
12.5.1 Insert record .......................................................................................................................................... 223
12.6 Alarm record ..................................................................................................................................... 223
12.6.1 Query alarm record ................................................................................................................................ 223
13 Bosch APIs ................................................................................................................................................ 225
13.1 FileFindHelper ................................................................................................................................... 225
13.1.1 Create a file finder ................................................................................................................................. 225
13.1.2 Get the file information found by the finder ......................................................................................... 228
13.1.3 Stop the finder ....................................................................................................................................... 229
13.1.4 Get bound files ...................................................................................................................................... 229
14 Other APIs ................................................................................................................................................ 233
14.1 Discover devices ................................................................................................................................ 233
14.1.1 Discover devices on internet ................................................................................................................. 233
14.2 Flashlight ........................................................................................................................................... 235
14.2.1 Flashlight config ..................................................................................................................................... 235
15 Appendix .................................................................................................................................................. 236
15.1 Stream head ...................................................................................................................................... 236
15.2 Extend Header ................................................................................................................................... 237
15.2.1 Audio extend header ............................................................................................................................. 238
15.2.2 Video extend header ............................................................................................................................. 238
15.2.3 Channel title extend header .................................................................................................................. 239
15.2.4 Time zone extend header ...................................................................................................................... 239
5 Event flag extend header ....................................................................................................................... 240
15.2.
Page 12

1 Overview

Amcrest Technologies LLC | www.amcrest.com
10
This document specifies the HTTP based application programming interface of video products.
The HTT functions (PTZ, Focus etc.) and for getting and setting internal parameter values.
The video products serve as a server. The client sends requests to server, and then server handles requests and returns resources accordingly.
P-based interface provides the functionality for requesting snapshot and media stream, for controlling camera

2 References

[1]. RFC 2616 Hypertext Transfer Protocol-HT TP/1. 1 [2]. RFC 2396 Uniform Resource Identifiers (URI): Generic Syntax and Semantics [3]. RFC 2617 HTTP Authentication: Basic and Digest Access Authentication [4]. RFC 3986: Uniform Resource Identifiers (URI) Generic Syntax

3 Definitions

3.1 Abbreviations

The following abbreviations are used throughout this document
API Applica video products.
tion programming interface – in the document, it especially presents application programming interface of

3.2 Syntax convention

In URL syntax and in descriptions of API parameters, text in italic within angle brackets denotes content that should be
replaced with either a value or a string. When replacing the text string, the angle brackets must also be replaced. For example, <ser
String sh
Name-value p
own in bold face denotes a brief explanatory note of the string close to it.
ver> in the URL syntax is replaced with the string “192.168.1.108”.
air in square brackets denotes content that is optional. For example,
Page 13
“http ://<server>/cgi-bin/snapshot.cgi[?channel=<ChannelNo>]” can be like this
Amcrest Technologies LLC | www.amcrest.com
11
“http ://<server>/cgi-bin/snapshot.cgi”.
The API sy
spaces and other reserved characters (“;”, “/”, “?”, “:”, “@”, “=“, “+”, “,” and “$”) within a name-value pair should be replaced with %< ASCII hex>. For example, the blank should be replaced with %20.
To descr
integer not less than 0 and not larger than 100. “{0, 1, 2, 3}” denotes the valid value of an integer among 0, 1, 2 and 3.
“[]” following a string denotes an ar ray. The index is usually an integer and starts from 0. For example,
“Snap[channel]” may be “Snap[0]” or “Snap[1]”.
The variabl
“false”.
ntax must follow the standard of URI. (RFC 3986: Uniform Resource Identifiers (URI) Generic Syntax); that is,
ibe the range of a variable, we use some symbols such as “[]” and “{}”. For example:” [0-100]” denotes an
e may be different types: string, integer, bool or float. Integer is 32 bits. The range of bool is “true” and

3.3 API format

This section defines the syntax and semantics for APIs.
<protocol> ://<server><abs_path> [?query]
protocol: URL scheme for the particular request. The http and https protocols are both supported in this specification. So “http”, as most of the APIs’ default protocol except several RTSP APIs, can be replaced by “https”.
server: device. The port is the port number of server listening for TCP connections. If the port is not given, the default port is assumed. For H T TP, the default port is 80. For HTTPS, the default port is 443.
abs_p
“/cgi-bin/*.cgi”.
query: The query field is a string of information to be interpreted by the resource. It consists of resource-related parameters. And it must be listed in name-value pair syntax (p1=v1&p2=v2&…&pn=vn).
For exam
Server could be “hostname[: port]”. The hostname can be IP address or the fully qualified domain name of an IP
ath: The Request-URI for the resources is abs_path. The abs_path in this specification is most often of the form
ple:
http://192.168.1.108/cgi-bin/snapshot.cgi?channel=1
Page 14

3.4 Server responses

Amcrest Technologies LLC | www.amcrest.com
12
The server uses the standard HTTP status codes.
Return:
HT T P/1 . 1 <HTTP code> <HTTP text>\r\n
With the following HTTP code and meanings
Tabl e 3-1
HTTP code HTTP text Description
200 OK
400 Bad Request
401 Unauthorized
404 Not Found
500 Internal Server Error
Example: request doesn’t fit with syntax.
HTTP/1.1 404 Not Found\r\n
If the request fits with syntax but an error occurs while the server handles it, the response would like this:
The request has succeeded. The requested resource will be returned in the HTTP text.
The request had bad syntax or was inherently impossible to be satisfied.
The request requires user authentication or the authorization has been refused.
The server has not found anything matching the request.
The server encountered an unexpected condition that prevented it from fulfilling the request.
HTTP/1.1 200 OK
Error
ErrorID=<Error Code>, Detail=<Error Description>
Page 15
Example: Request spells wrong.
Amcrest Technologies LLC | www.amcrest.com
13
HTTP/1.1 200 OK
Error
ErrorID=2, Detail= Invalid Request!
All error codes are defined as below.
Tabl e 3-2
Error Code Detail Description
0 Invalid Authority! The user fails in authentication or doesn’t include the right
accessing the resource.
1 Request parses error! Request is incomplete.
2 Invalid Request! Request spells error.
3 Method not found! the resource not supported
4 Request invalid param! Parameters of request are invalid.
5 Server internal error! An error occurs when server handles the request.
6 Request Timeout! Timeout when server handles request.
7 Client keepalive failed! The client fails to keep alive.

3.5 Authentication

Video products support either basic authentication or digest authentication. If the http request does not provide valid “Authorization” information, video products would return HTTP status code 401 and information for authentication. Video products return the required resource only if authorization correct.
For example:
1. When basic authentication fails, response is:
Page 16
Amcrest Technologies LLC | www.amcrest.com
14
HT T P/1 . 1 401 Unauthorized
WWW-Authenticate: Basic realm=”XXXXXX”
The client encodes the username and password with base64, and then sends it to s e rv e r. A valid Authorization like this:
Authorization: Basic VXZVXZ
2. When digest authentication fails, response is:
HT T P/1 . 1 401 Unauthorized
WWW-Authenticate: Digest realm="DH_00408CA5EA04", nonce="000562fdY631973ef04f77a3ede7c1832ff48720ef95ad", stale=FALSE, qop="auth"
The client calculates the digest authorization using information like username, password, nonce, HTTP method and URI with MD5, and then sends it to s e r v e r. For example:
Authorization: Digest username="admin", realm="DH_00408CA5EA04", nc=00000001, cnonce="0a4f113b", qop="auth", nonce="000562fdY631973ef04f77a3ede7c1832ff48720ef95ad", uri="/cgi-bin/magicBox.cgi?action=getLanguageCaps", response="65002de02df697e946b750590b44f8bf"

4 General APIs

The requests specified in this section are supported by all video products.

4.1 APIs of RTSP

4.1.1 Get real-time stream

Tabl e 4-1
Syntax rtsp://<username>:<password>@<ip>:<port>/cam/realmonitor?channel=<ChannelNo>&subtype=<ty
Page 17
Description
Amcrest Technologies LLC | www.amcrest.com
15
peNo>
Get real-time media stream.
Example
Success Return media stream data
Comment
We request the extra stream 1 of channel 1, the URL is:
rtsp://admin:admin@10.7.6.67:554/cam/realmonitor?channel=1&subtype=1
<username>: a valid user’s username.
<password>: user’s password.
< ip>: the IP address of the video product.
<port >: the default port is 554. It can be omitted.
<ChannelNo>: integer, the video channel index which starts from 1.
<typeNo>: the stream type. The <typeNo> of main stream is 0, extra stream 1 is 1, extra stream 2 is 2. The extra stream counts can be obtained in GetMaxExtraStreamCounts. If the stream does not exist or not enabled, response will be error.
The IP Camera supports both TCP and UDP transmission forms.
It also supplies basic authentication and digest authentication ways. The authentication process is similar with Authentication.

4.1.2 Get playback stream

Tabl e 4-2
Syntax rtsp://<username>:<password>@<ip>:<port>/cam/playback?channel=<ChannelNo>&starttime=<starttime>
&endtime=<endtime>
Description
Example
Success Return media stream data
Comment
Get playback media stream.
rtsp://admin:admin@10.44.200.8:554/cam/playback?channel=1&starttime=2012_09_15_12_37_05&endti me=2012_09_15_18_34_14
It ’s similar with GetRtspStream. Except there are parameters “starttime” and “endtime”.
Page 18

4.1.3 Get file stream

username
password
port
server
GET
Amcrest Technologies LLC | www.amcrest.com
16
Tabl e 4-3
Syntax rtsp://<
Description
Example rtsp://admin:admin@10.44.200.8:554//mnt/sd/2015-09-16/001/dav/20/20.32.08-20.32.28[M][0@0][0].
Success Return media stream data
Comment
Get specific file stream.
dav
It’s similar with GetRtspStream.
filename: absolute path.
>:<
>@<ip>:<
>/<filename>

4.2 Special APIs

4.2.1 Get mjpg stream

Tabl e 4-4
Syntax http://<
Method
Description
Example
Success Return
Get a video stream encoded by mjpg.
To get a video stream of channel 1, main stream, the URL can be
http://192.168.1.108/cgi-bin/mjpg/video.cgi
or
http://192.168.1.108/cgi-bin/mjpg/video.cgi?channel=1&subtype=0
Video stream encoded by MJPG.
For example:
HTTP Code: 200 OK
Content-Type: multipart/x-mixed-replace; boundary=<boundary>
Body:
>/cgi-bin/mjpg/video.cgi[?channel=<ChannelNo>&subtype=<typeNo>]
--<boundary>
Page 19
Content-Type: image/jpeg
Amcrest Technologies LLC | www.amcrest.com
17
Content-Length:<image size>
<JPEG image data>
--<boundary>
Comment
ChannelNo: integer, the video channel index which starts from 1, default 1 if not specified.
typeNo: the stream type, default 0 if not specified. It can be the following value:
0-Main Stream
1-Extra Stream 1
2-Extra Stream 2

4.2.2 Get real-time stream

Tabl e 4-5
Syntax http://<server>/cgi-bin/realmonitor.cgi?action=getStream[&channel=<ChannelNo>&subtype=<typeNo
>]
Method GET
Description
Get a video stream.
Example http://192.168.1.108/cgi-bin/realmonitor.cgi?action=getStream&channel=1&subtype=0
Success Return
HTTP Code: 200 OK Content-Type: Application/octet-stream
Body:
<data>
<data>
Comment
ChannelNo: integer, the video channel index which starts from 1, default 1 if not specified..
typeNo: the stream type, default 0 if typeNo was not specified.
0-Main Stream
1-Extra Stream 1
2-Extra Stream 2
Page 20
Compared to 4.1.1 GetStream using RT SP, it is another way to get stream. This is a way to use http
Amcrest Technologies LLC | www.amcrest.com
18
protocol to get real monitor stream. The data format is shown in appendix.

4.2.3 Get playback stream

Tabl e 4-6
Syntax http://<server>/cgi-bin/playBack.cgi?action=getStream[&channel=<ChannelNo>&subtype=<typeNo>]
&startTime=<startTime>&endTime=<endTime>
Method GET
Description
Example http://192.168.1.108/cgi-bin/playBack.cgi?action=getStream&channel=1&subtype=0&startTime=2012-
Success Return
Playback stream using http protocol
10-8%2013:00:01&endTime=2012-10-8%2014:00:01
HTTP Code: 200 OK
Content-Type: Application/octet-stream
Comment
Body:
streamId=<streamId>\r\n
<data>
<data>
ChannelNo: integer, the video channel index which starts from 1, default 1 if not specified.
typeNo: the stream type, default 0 if not specified.
0-Main Stream
1-Extra Stream 1
2-Extra Stream 2
starttime & endtime: video start time and end time. Time format: yyyy-mm-dd hh:mm:ss
Compared to Playback using R T SP, it is another way of get playback stream. This is a way to use http protocol to get playback stream. The data format is shown in appendix.
Page 21

4.2.4 Control the playback stream

server
Amcrest Technologies LLC | www.amcrest.com
19
Tabl e 4-7
Syntax http://<
>/cgi-bin/playBack.cgi?action=control&streamId=<streamId>&cmd=<cmd>&<paramNa
me>=<paramValue>[&<paramName>=<paramValue>...]
Method GET
Description
Control the playback stream, used to control the stream which built by “action=getStream”.
Example http://192.168.1.108/cgi-bin/playBack.cgi?action=control&streamId=0&cmd=play&speed=1&iframe=0
Success Return
Pause/Cancel:
OK
Play:
OK
operateId=1
Comment
cmd=play
If cmd is play, there are three optional parameters:
speed=<speed>: optional, default speed=1, if speed > 0, play back forward, else if speed < 0, playback backward(param iframe is ignored, only support iframe playback backward);
iframe=<iframe>: optional, default iframe=0, if iframe=1, playback I frame only;
seekTime=<seekTime>: seek time, optional, default playback from the stream current point;
cmd=pause
pause the playback stream;
cmd=cancel
cancel the playback stream, and destroy the streamed;
operateId: represent current control operation, after control playback, the video extend header will has same operateid as this value.
Page 22

4.3 Audio

server
server
Amcrest Technologies LLC | www.amcrest.com
20

4.3.1 Get audio input channel numbers

Tabl e 4-8
Syntax http://<
Method GET
Description Get Audio input channel number.
Example http://192.168.1.108/cgi-bin/devAudioInput.cgi?action=getCollect
Success Return
Comment Above response means there are 2 audio input channels.
result=1
>/cgi-bin/devAudioInput.cgi?action=getCollect

4.3.2 Get audio output channel numbers

Tabl e 4-9
Syntax http://<server>/cgi-bin/devAudioOutput.cgi?action=getCollect
Method GET
Description Get Audio output channel number.
Example http://192.168.1.108/cgi-bin/devAudioOutput.cgi?action=getCollect
Success Return
result=1
Comment Above response means there are 2 audio output channels.

4.3.3 Post audio stream

Tabl e 4-10
Syntax http://<
=<paramValue>...]
Method POST
Description Post audio
Example
Example for single part
The URL of transmit a single part, channel 1 audio stream(encoded with G.711 A-law) is:
http://192.168.1.108/cgi-bin/audio.cgi?action=postAudio&httptype=singlepart&channel=1
>/cgi-bin/audio.cgi?action=postAudio&<paramName>=<paramValue>[&<paramName>
Page 23
example:
Amcrest Technologies LLC | www.amcrest.com
21
POST /cgi-bin/audio.cgi?action=postAudio&httptype=singlepart&channel=1 HT T P/1 . 1 Content-Type: Audio/G.711A
Content-Length: 9999999
<Audio data>
<Audio data>
Example for multipart
The URL of transmit a multipart, channel 1 audio stream(encoded with G.711 A-law) is:
http://192.168.1.108/cgi-bin/audio.cgi?action=postAudio&httptype=multipart&channel=1
example:
POST /cgi-bin/audio.cgi?action=postAudio&httptype=multipart&channel=1 HTTP/1.1 Content-Type: multipart/x-mixed-replace; boundary=<boundary>
--<boundary>
Content-Type: Audio/G.711A
Content-Length: 800
<Audio data>
--<boundary>
Success Return OK
Comment
Params in URL:
The paramName and paramValue are in the below table.
Appendix A: Parameters in URL
ParamName ParamValue type Description
httptype string singlepart: HTTP content is a continuous flow
of audio packets
multipart: HTTP content type is multipart/x-mixed-replace, and each audio
Page 24
packet ends with a boundary string
Amcrest Technologies LLC | www.amcrest.com
22
channel integer The audio channel
Appendix B: Audio Encode Type
MIME Description
Audio/PCM
Audio/ADPCM
Audio/G.711A
Audio/G.711Mu
Audio/G.726
Audio/G.729
Audio/MPEG2
Audio/AMR
Audio/AAC

4.3.4 Get audio stream

Table 4-11
Syntax http://<server>/cgi-bin/audio.cgi?action=getAudio&<paramName>=<paramValue>[&<paramName>=
<paramValue>...]
Method GET
Description
Get audio
Example
Example for single part
The URL of Request a single part, channel 1 audio stream(encoded with G.711 A-law) is:
http://192.168.1.108/cgi-bin/audio.cgi?action=getAudio&httptype=singlepart&channel=1
Page 25
Amcrest Technologies LLC | www.amcrest.com
23
If the request was successful, the server returns a continuous flow of audio packets. The content type is only set at the beginning of the connection.
Return:
HTTP Code: 200 OK Content-Type: Audio/G.711A
Body:
<Audio data>
<Audio data>
Example for multipart
The URL of Request a multipart, channel 1 audio stream(encoded with G.711 A-law) is:
http://192.168.1.108/cgi-bin/audio.cgi?action=getAudio&httptype=multipart&channel=1
If the request was successful, the server returns a continuous flow of audio packets. The content type is “multipart/x-mixed-replace” and each audio packet ends with a boundary string.
Return:
HTTP Code: 200 OK Content-Type: multipart/x-mixed-replace; boundary=<boundary>
--<boundary>
Content-Type: Audio/G.711A
Content-Length: 800
<Audio data>
--<boundary>
Success Return OK
Comment
Params in URL:
The paramName and paramValue are in the below table.
Appendix:
Page 26
ParamName ParamValue type Description
Method
GET
Amcrest Technologies LLC | www.amcrest.com
24
httptype string singlepart: HTTP content is a continuous flow
of audio packets
multipart: HTTP content type is multipart/x-mixed-replace, and each audio packet ends with a boundary string
channel integer The audio channel

4.4 Snapshot

4.4.1 Snap

Get snap config
Tabl e 4-12
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Snap
Description Get Snap config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Snap
Success Return
table.Snap[0].HolidayEnable=false
table.Snap[0].TimeSection[0][0]=6 00:00:00-23:59:59
table.Snap[0].TimeSection[0][1]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[0][2]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[0][3]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[0][4]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[0][5]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[1][0]=6 00:00:00-23:59:59
table.Snap[0].TimeSection[1][1]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[1][2]=0 00:00:00-23:59:59
Page 27
Comment
OK
Amcrest Technologies LLC | www.amcrest.com
25
Set snap config
Tabl e 4-13
table.Snap[0].TimeSection[1][3]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[1][4]=0 00:00:00-23:59:59
table.Snap[0].TimeSection[1][5]=0 00:00:00-23:59:59
Response format:
table. Snap[channel].TimeSection[weekday][configNo]=1 00:00:00-23:59:59
channel is video channel number, weekday range is [0-6] (Sunday - Saturday). configNo is the index of time section config. There are many time sections each day.
Syntax
http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para mName>=<paramValue>...]
Method GET
Description
Set Snap config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Snap[0].TimeSection[0][0]=1%201
2:00:00-18:00:00
Success Return
Comment
In below table,
ch = channel index
wd = week day index
ts = time section index
Appendix:
ParamName ParamValue
Snap[ch].TimeSection[wd][ts] string wd (week day) range is [0-6] (Sunday- Saturday)
Description
type
ts (time section) range is [0-23], it’s time section table index.
Page 28
: integer, the video channel index which starts from 1, default 1 if not specified.
Amcrest Technologies LLC | www.amcrest.com
26

4.4.2 Get a snapshot

Tabl e 4-14
Format: mask hh:mm:ss-hh:mm:ss
Mask: [0-65535], hh: [0-24], mm: [0-59], ss: [0-59]
Mask indicates record type by bits:
Bit0: regular snapshot
Bit1: motion detection snapshot
Bit2: alarm snapshot
Bit3: card snapshot
Syntax http://<server>/cgi-bin/snapshot.cgi[?channel=<ChannelNo>]
Method GET
Description Get a snapshot of a video channel.
Example
Success Return Image of jpg format.
Comment
To get a snapshot of video channel 1, the URL can be
http://192.168.1.108/cgi-bin/snapshot.cgi
or
http://192.168.1.108/cgi-bin/snapshot.cgi?channel=1
ChannelNo

4.4.3 Subscribe to snapshot

Tabl e 4-15
Syntax http://<server>/cgi-bin/snapManager.cgi?action=attachFileProc&Flags[0]=Event&Events=[<eventCode>
,<eventCode>,…] [&channel=<ChannelNo>]
Method GET
Description Subscribe pictures when that event of code eventCode happens.
Example http: / /192.168.1.1 08/ c g i-bin/snapManager.cgi?action=attachFileProc&Flags[0]=Event&Events=[VideoM
otion%2CVideoLoss]
Page 29
Success Return
Amcrest Technologies LLC | www.amcrest.com
27
--<boundary>\r\n
Content-Type: text/plain\r\n
Content-Length: <data length>\r\n
Events[0].Code=TrafficJunction
Events[0].CountInGroup=1
Events[0].IndexInGroup=1
Events[0].Lane=1
Events[0].Data.PTS= 42949485818.0
Events[0].TrafficCar.PlateNumber=A12345
Events[0].TrafficCar. DeviceAddress=杭州
……
Events[1].Code=TrafficJunction
……
Comment
--<boundary>
Content-Type: image/jpeg
Content-Length:<image size>
<JPEG image data>
--<boundary>
ChannelNo: integer, the video channel index which starts from 1, default 1 if not specified.
eventCode : it can be any one of the standard codes defined in DHIIF.
eventCode includes:
VideoMotion: motion detection event
VideoLoss: video loss detection event
VideoBlind: video blind detection event.
AlarmLocal: alarm detection event.
Page 30

4.5 Video attributes

server
http://<
>/cgi-bin/configManager.cgi?action=getConfig&name=VideoColor
Amcrest Technologies LLC | www.amcrest.com
28

4.5.1 Get max extra stream numbers

Tabl e 4-16
Syntax http://<
Method GET
Description Get max extra stream count
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getProductDefinition&name=MaxExtraStream
Success Return table.MaxExtraStream=1
Comment MaxExtraStream: max extra stream numbers. It can be 1, 2 or 3.
>/cgi-bin/magicBox.cgi?action=getProductDefinition&name=MaxExtraStream

4.5.2 Video color config

Get video color config
Tabl e 4-17
Syntax
Method GET
Description Get Video Color config
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=VideoColor
Success Return
head. Brightness=50
server
Comment
head. Contrast=50
head. Hue=50
head. Saturation=50
head. TimeSection=1 00:00:00-24:00:00
Params in Response:
head= table.VideoColor[ChannelNo][ColorConfigNo]
ChannelNo = video channel index,
colorConfigNo = color config index.
0 = Color Config 1
1 = Color Config 2
Page 31
Amcrest Technologies LLC | www.amcrest.com
29
Set video color config
Tabl e 4-18
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Video Color config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoColor[1][0].Brightness=50
Success Return OK
Comment
In below table, head=VideoColor[ChannelNo][ColorConfigNo]
ChannelNo = video channel index,
colorConfigNo = color config index,
0 = Color Config 1
1 = Color Config 2
Appendix:
ParamName ParamValue type Description
head. Brightness integer Brightness, range is [0-100]
head. Contrast integer Contrast, range is [0-100]
head. Hue integer Hue
head. Saturation integer Saturation
head.
TimeSection
string Effective time for this video color config.
Format is: mask starttime endtime
Mask range is {0, 1}.
Mask 0 – this video config is not effective
Mask 1 - this config is effective
Page 32
Starttime/Endtime format like 11:00:00.
Amcrest Technologies LLC | www.amcrest.com
30
Example:
0 01:00:00-02:00:00, means this config is not effective.
1 01:00:00-02:00:00, means this config is effective between 01:00:00 and 02:00:00

4.5.3 Get encode capability

Tabl e 4-19
Syntax http://<server>/cgi-bin/encode.cgi?action=getCaps
Method GET
Description Get encode capabilities.
Example http://192.168.1.108/cgi-bin/encode.cgi?action=getCaps
Success Return
caps.PlaybackCompressSplitNumList[0]=1
Comment
caps.PlaybackCompressSplitNumList[1]=2
caps.PlaybackCompressSplitNumList[2]=4
caps.PreviewMode=SplitSnap
caps.VideoEncodeDevices[0].CoverAreaPercent=100
caps.VideoEncodeDevices[0].CoverCount=4
caps.VideoEncodeDevices[0].LadenBitrate=162201600
caps.VideoEncodeDevices[0].MaxCIFPFrameSize=40
caps.VideoEncodeDevices[0].MaxExtraStream=1
caps.VideoEncodeDevices[0].MinCIFPFrameSize=7
caps.VideoEncodeDevices[0].RecordIndividualResolution=true
caps.VideoEncodeDevices[0].SupportIndividualResolution=true
caps.VideoEncodeDevices[0].TitleCount=4
Page 33

4.5.4 Get encode config capability

server
GET
Amcrest Technologies LLC | www.amcrest.com
31
Tabl e 4-20
Syntax http://<
>/cgi-bin/encode.cgi?action=getConfigCaps&channel=<ChannelNo>
Method
Description
Get encode config capabilities.
Example http://192.168.1.108/cgi-bin/encode.cgi?action=getConfigCaps&channel=1
Success Return
headMain.Video.BitRateOptions=448,2560
headMain.Video.CompressionTypes=H.264,MJPG
headMain.Video.FPSMax=25
headMain.Video.ResolutionTypes=2048 x 1536,1080,SXGA, 1280 x 960,720,D1,CIF
headExtra.Video.BitRateOptions=80,448
headExtra.Video.CompressionTypes=H.264,MJPG
headExtra.Video.FPSMax=25
headExtra.Video.ResolutionTypes=D1,CIF
headSnap.Video.CompressionTypes=H.264,MJPG
Comment
headSnap.Video.ResolutionTypes=2048 x 1536,1080,SXGA, 1280 x 960,720,D1,CIF
Params in URL:
ChannelNo: video channel index
Params in Response:
headMain= caps[Channel].MainFormat[RecordType]
headExtra = caps[Channel].ExtraFormat[ExtraStream]
headSnap = caps[Channel].SnapFormat[SnapType]
Channel: video channel index
RecordType:
0 = regular record
1 = motion detection record
2 = alarm record
ExtraStream:
Page 34
0 = extra stream 1
Amcrest Technologies LLC | www.amcrest.com
32
1 = extra stream 2
2 = extra stream 3
SnapType:
0 = regular snapshot
1 = motion detection snapshot
2 = alarm snapshot
Appendix A: Encode Config Capabilities
Field in response Value range Description
BitRateOptions string Before comma is minimum bit rate. (kbps), after comma is maximum bit
rate.(kbps)
BitRateOptions=80,448
80 is the minimum bitrates, 448 is maximum.
CompressionTypes
To video, it contains all supported video compression types, separated by comma. Range is {MPEG4, MPEG2, MPEG1, MJPG, H.263, H.264, H.265}
To audio, it contains all supported audio compression types, separated by
string
comma.
Range is {PCM, ADPCM, G.711A, G.711Mu, G.726, G.729, MPEG2, AMR}
FPSMax integer Maximum FPS.
ResolutionTypes
It contains all supported video resolutions.
string
Range is in below Resolution list.
Appendix B: Video Resolution
Fixed Resolution Name Size in PAL Size in NTSC
Page 35
"D1" 704 x 576 704 x 480
Amcrest Technologies LLC | www.amcrest.com
33
"HD1" 352 x 576 352 x 480
"BCIF"/"2CIF" 704 x 288 704 x 240
"CIF" 352 x 288 352 x 240
"QCIF" 176 x 144 176 x 120
"NHD" 640 x 360
"VGA" 640 x 480
"QVGA" 320 x 240
"SVCD" 480 x 480
"QQVGA" 160 x 128
"SVGA" 800 x 592
"SVGA1" 800 x 600
"WVGA" 800 x 480
"FWVGA" 854 x 480
"DVGA" 960 x 640
"XVGA" 1024 x 768
"WXGA" 1280 x 800
"WXGA2" 1280 x 768
"WXGA3" 1280 x 854
"WXGA4" 1366 x 768
"SXGA" 1280 x 1024
Page 36
"SXGA+" 1400 x 1050
Amcrest Technologies LLC | www.amcrest.com
34
"WSXGA" 1600 x 1024
"UXGA" 1600 x 1200
"WUXGA" 1920 x 1200
"ND1" 240 x 192
"720P" 1280 x 720
"1080P" 1920 x 1080
"QFHD" 3840 x 2160
"1_3M", "1280x960" 1280 x 960 (1.3 Mega Pixels)
"2_5M", "1872x1408" 1872 x 1408 (2.5 Mega Pixels)
"5M", "3744x1408" 3744 x 1408 (5 Mega Pixels)
"3M", "2048x1536" 2048 x 1536 (3 Mega Pixels)
"5_0M", "2432x2048" 2432 x 2048 (5 Mega Pixels)
"1_2M", "1216x1024" 1216 x 1024 (1.2 Mega Pixels)
"1408x1024" 1408 x 1024 (1.5 Mega Pixels)
"3296x2472" 3296 x 2472 (8 Mega Pixels)
"5_1M", "2560x1920" 2560 x 1920 (5 Mega Pixels)
"960H", 960 x 576 960 x 480
"DV720P" 960 x 720
"2560x1600" 2560 x 1600 (4 Mega Pixels)
"2336x1752" 2336 x 1752 (4 Mega Pixels)
Page 37
"2592x2048" 2592 x 2048
Amcrest Technologies LLC | www.amcrest.com
35
"2448x2048" 2448 x 2048
"1920x1440" 1920x1440
"2752x2208" 2752x2208
"3840x2160" 3840x2160
"4096x2160" 4096x2160
"3072x2048" 3072x2048
Appendix C: Audio Compression Type
Field in response Value range Description
CompressionTypes
string
It contains all supported audio compression types, separated by comma. Range is {PCM, ADPCM, G.711A, G.711Mu, G.726, G.729, MPEG2, AMR}

4.5.5 Encode of media

Get encode config
Tabl e 4-21
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Encode
Method GET
Description Get video encode config.
Example
Success Return
http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Encode
table.Encode[0].MainFormat[0].Audio.Bitrate=64
table.Encode[0].MainFormat[0].Audio.Channels[0]=0 table.Encode[0].MainFormat[0].Audio.Compression=G.711A table.Encode[0].MainFormat[0].Audio.Depth=16 table.Encode[0].MainFormat[0].Audio.Frequency=8000 table.Encode[0].MainFormat[0].Audio.Mode=0
Page 38
table.Encode[0].MainFormat[0].Audio.Pack=DHAV
Amcrest Technologies LLC | www.amcrest.com
36
table.Encode[0].MainFormat[0].AudioEnable=true table.Encode[0].MainFormat[0].Video.resolution=1920x1080 table.Encode[0].MainFormat[0].Video.BitRate=4096 table.Encode[0].MainFormat[0].Video.BitRateControl=CBR table.Encode[0].MainFormat[0].Video.Compression=H.264 table.Encode[0].MainFormat[0].Video.CustomResolutionName=1080P table.Encode[0].MainFormat[0].Video.FPS=18 table.Encode[0].MainFormat[0].Video.GOP=36 table.Encode[0].MainFormat[0].Video.Height=1080 table.Encode[0].MainFormat[0].Video.Pack=DHAV table.Encode[0].MainFormat[0].Video.Profile=High table.Encode[0].MainFormat[0].Video.Quality=4 table.Encode[0].MainFormat[0].Video.QualityRange=6 table.Encode[0].MainFormat[0].Video.SVCTLayer=1 table.Encode[0].MainFormat[0].Video.Width=1920 table.Encode[0].MainFormat[0].VideoEnable=true table.Encode[0].MainFormat[1].Audio.Bitrate=64 table.Encode[0].MainFormat[1].Audio.Channels[0]=0 table.Encode[0].MainFormat[1].Audio.Compression=G.711A table.Encode[0].MainFormat[1].Audio.Depth=16 table.Encode[0].MainFormat[1].Audio.Frequency=8000 table.Encode[0].MainFormat[1].Audio.Mode=0 table.Encode[0].MainFormat[1].Audio.Pack=DHAV table.Encode[0].MainFormat[1].AudioEnable=true table.Encode[0].MainFormat[1].Video.resolution=1920x1080 table.Encode[0].MainFormat[1].Video.BitRate=4096 table.Encode[0].MainFormat[1].Video.BitRateControl=CBR table.Encode[0].MainFormat[1].Video.Compression=H.264 table.Encode[0].MainFormat[1].Video.CustomResolutionName=1080P table.Encode[0].MainFormat[1].Video.FPS=18 table.Encode[0].MainFormat[1].Video.GOP=36 table.Encode[0].MainFormat[1].Video.Height=1080 table.Encode[0].MainFormat[1].Video.Pack=DHAV table.Encode[0].MainFormat[1].Video.Profile=High table.Encode[0].MainFormat[1].Video.Quality=4 table.Encode[0].MainFormat[1].Video.QualityRange=6 table.Encode[0].MainFormat[1].Video.SVCTLayer=1 table.Encode[0].MainFormat[1].Video.Width=1920 table.Encode[0].MainFormat[1].VideoEnable=true table.Encode[0].MainFormat[2].Audio.Bitrate=64 table.Encode[0].MainFormat[2].Audio.Channels[0]=0 table.Encode[0].MainFormat[2].Audio.Compression=G.711A table.Encode[0].MainFormat[2].Audio.Depth=16
Page 39
table.Encode[0].MainFormat[2].Audio.Frequency=8000
Amcrest Technologies LLC | www.amcrest.com
37
table.Encode[0].MainFormat[2].Audio.Mode=0 table.Encode[0].MainFormat[2].Audio.Pack=DHAV table.Encode[0].MainFormat[2].AudioEnable=true table.Encode[0].MainFormat[2].Video.resolution=1920x1080 table.Encode[0].MainFormat[2].Video.BitRate=4096 table.Encode[0].MainFormat[2].Video.BitRateControl=CBR table.Encode[0].MainFormat[2].Video.Compression=H.264 table.Encode[0].MainFormat[2].Video.CustomResolutionName=1080P table.Encode[0].MainFormat[2].Video.FPS=18 table.Encode[0].MainFormat[2].Video.GOP=36 table.Encode[0].MainFormat[2].Video.Height=1080 table.Encode[0].MainFormat[2].Video.Pack=DHAV table.Encode[0].MainFormat[2].Video.Profile=High table.Encode[0].MainFormat[2].Video.Quality=4 table.Encode[0].MainFormat[2].Video.QualityRange=6 table.Encode[0].MainFormat[2].Video.SVCTLayer=1 table.Encode[0].MainFormat[2].Video.Width=1920 table.Encode[0].MainFormat[2].VideoEnable=true table.Encode[0].MainFormat[3].Audio.Bitrate=64 table.Encode[0].MainFormat[3].Audio.Channels[0]=0 table.Encode[0].MainFormat[3].Audio.Compression=G.711A table.Encode[0].MainFormat[3].Audio.Depth=16 table.Encode[0].MainFormat[3].Audio.Frequency=8000 table.Encode[0].MainFormat[3].Audio.Mode=0 table.Encode[0].MainFormat[3].Audio.Pack=DHAV table.Encode[0].MainFormat[3].AudioEnable=true table.Encode[0].MainFormat[3].Video.resolution=704x576 table.Encode[0].MainFormat[3].Video.BitRate=2048 table.Encode[0].MainFormat[3].Video.BitRateControl=VBR table.Encode[0].MainFormat[3].Video.Compression=H.264 table.Encode[0].MainFormat[3].Video.FPS=25 table.Encode[0].MainFormat[3].Video.GOP=50 table.Encode[0].MainFormat[3].Video.Height=576 table.Encode[0].MainFormat[3].Video.Pack=DHAV table.Encode[0].MainFormat[3].Video.Profile=Main table.Encode[0].MainFormat[3].Video.Quality=4 table.Encode[0].MainFormat[3].Video.QualityRange=6 table.Encode[0].MainFormat[3].Video.SVCTLayer=1 table.Encode[0].MainFormat[3].Video.Width=704
table.Encode[0].MainFormat[3].VideoEnable=true
table.Encode[0].ExtraFormat[0].Audio.Bitrate=64
Page 40
The
Amcrest Technologies LLC | www.amcrest.com
38
table.Encode[0].SnapFormat[0].Audio.Bitrate=64
Comment
Params in Response:
The format of the config is head.configItems. The head can be:
headMain= table. Encode[Channel].MainFormat[Type]
headSnap = table. Encode[Channel].SnapFormat[Type]
headExtra =table. Encode[Channel].ExtraFormat[ExtraStream]
Channel: video channel index
Type:
0 = regular encode
1 = motion detection encode
2 = alarm encode
3= emergency encode
ExtraStream:
0 = extra stream 1
1 = extra stream 2
2 = extra stream 3
configItems are list as bellow.
Set encode config
Tabl e 4-22
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set encode config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Encode[1].MainFormat[0].Video.C
ompression=MPEG4
Success Return OK
Page 41
Comment
Amcrest Technologies LLC | www.amcrest.com
39
Params in URL:
In below table,
head=Encode[Channel].MainFormat[RecordType] (or)
Encode[Channel].ExtraFormat[ExtraStream]
Channel: video channel index
RecordType:
0 = regular record
1 = motion detection record
2 = alarm record
ExtraStream:
0 = extra stream 1
1 = extra stream 2
2 = extra stream 3
Appendix A: Video Encode Config
ParamName ParamValue type Description
head.Video.BitRate integer Unit is Kbps
Range depends on capability in GetVideoConfigCaps
head.Video.BitRateControl string Range is {CBR, VBR}
CBR: constant bitrates
VBR: variable bitrates
head.Video.Compression String Range is {MPEG4, MPEG2, MPEG1, MJPG, H.263, H.264, H.265}
head.Video.FPS float Range is [0.2-30].
Depends on capacity in GetVideoConfigCaps
Frames per second.
Page 42
< 1.0: several seconds/frame, FPS=0.3333: 3 seconds per frame.
Amcrest Technologies LLC | www.amcrest.com
40
>1.0: several frames/second. FPS=3: 3 frames per second.
head.Video.GOP integer Range is [1-100].
Group of picture, it’s the interval of I Frame,
Example: GOP=50, means there is one I frame every 49 P or B frames
head.Video.Height integer Video height
head.Video.Width integer Video Width
head.Video.Profile String Range is { Baseline, Main , Extended , High }
Only when video compression is H.264, it’s effective.
head.Video.Quality integer Range is [1-6].
Image Quality, available when Video.BitRateControl=VBR
1: worst quality
6: best quality
head.VideoEnable bool True: enable video
Appendix B: Audio Encode Config
ParamName ParamValue type Description
head.Audio.Bitrate integer Unit is kbps
Range depends on capacity in
GetAudioConfigCaps
head.Audio.Compression string Range depends on capacity in
GetAudioConfigCaps
head.Audio.Depth integer Audio sampling depth
head.Audio.Frequency integer Audio sampling frequency
head.Audio.Mode integer Range is {0,1,2,3,4,5,6,7}
Page 43
Audio encode mode.
server
Amcrest Technologies LLC | www.amcrest.com
41
0: 4.75kbps,
1: 5.15 kbps,
2: 5.9 kbps,
3: 6.7 kbps,
4: 7.4 kbps,
5: 7.95 kbps,
6: 10.2 kbps,
7: 12.2 kbps,
head.AudioEnable bool Enable/Disable audio

4.5.6 Encode of region interested

Get encode config of region interested
Tabl e 4-23
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=VideoEncodeROI
Method GET
Description Get video encode config of region interested.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=V ideoEncodeROI
Success Return head.DynamicTrack=false
Comment Params in Response :
head=table.VideoEncodeROI[ChannelNo] ChannelNo = array index starts from 0, which means video channel.
Set encode config of region interested
Tabl e 4-24
Syntax http://<
mName>=<paramValue>...]
Method GET
Description Set video encode config of region interested.
>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
Page 44
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoEncodeROI[0].DynamicTrack=t
Amcrest Technologies LLC | www.amcrest.com
42
rue
Success Return OK
Comment Params in URL:
paramName and paramValue are as below table. In below table,
head = VideoEncodeROI[ChannelNo] ChannelNo = array index starts from 0, which means video channel.
Appendix:
ParamName ParamValue
type
head. DynamicTrack bool Enable/Disable
Description

4.5.7 Channel title

Get channel title
Tabl e 4-25
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=ChannelTitle
Method GET
Description Get the title of the video channel.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=ChannelT itle
Success Return table.ChannelTitle[Channel].Name=CAM1
Comment
Params in Response:
Channel = video channel index
Set channel title
Tabl e 4-26
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>
Method GET
Page 45
Description
server
server
Amcrest Technologies LLC | www.amcrest.com
43
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&ChannelTitle[1].Name=test
Success Return OK
Comment
Set the title of the channel.
If VideoWidget[Channel].ChannelTitle.EncodeBlend is true, this title is blended to the video frames.
Please refer to SetVideoWidgetConfig.
Params in URL:
Channel Name Format:
ChannelTitle[Channel].Name
Channel : array index which means video channel, equals to video channel index -1 and start from 0.

4.5.8 Get video input channels device supported

Tabl e 4-27
Syntax http://<
Method GET
Description Get the video input channel numbers that supported.
Example http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=getCollect
Success Return result=1
Comment -
>/cgi-bin/devVideoInput.cgi?action=getCollect

4.5.9 Get video output channels device supported

Tabl e 4-28
Syntax http://<
Method GET
Description Get the video output channel numbers that supported.
Example http://192.168.1.108/cgi-bin/devVideoOutput.cgi?action=getCollect
Success Return result=2
Comment -
>/cgi-bin/devVideoOutput.cgi?action=getCollect
Page 46

4.5.10 Get max remote input channels

GET
Comment
MaxRemoteInputChannels: max remote input channels.
Success Return
table.VideoStandard=PAL
server
Amcrest Technologies LLC | www.amcrest.com
44
Tabl e 4-29
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getProductDefinition&name=MaxRemoteInputChannels
Method
Description Get max remote input channels
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getProductDefinition&name=MaxRemoteInputCha
nnels
Success Return table.MaxRemoteInputChannels=16

4.5.11 Video standard

Get video standard
Tabl e 4-30
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=V ideoStandard
Method GET
Description Get Video Standard config
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=V ideoStandard
Comment -
Set video standard
Tabl e 4-31
Syntax http://<
Method GET
Description
Set Video Standard config
>/cgi-bin/configManager.cgi?action=setConfig&VideoStandard=<paramValue>
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoStandard=PAL
Success Return OK
Comment VideoStandard: string, range is {PAL, NTSC} Video Standard.
Page 47

4.5.12 Video widget

Amcrest Technologies LLC | www.amcrest.com
45
Get video widget config
Tabl e 4-32
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=V ideoWidget
Method GET
Description Video Widget config contains Channel Title, Covers and Time Title parameters, defines the background
color, front color and positions of channel title and time title, and defines the regions which are not visible (cover).
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=V ideoWidget
Success Return
head.BackColor[0]=0
head.BackColor[1]=0
head.BackColor[2]=0
head.BackColor[3]=128
head.EncodeBlend=true
Comment
head.FrontColor[0]=255
head.FrontColor[1]=255
head.FrontColor[2]=255
head.FrontColor[3]=0
head.Rect[0]=0
head.Rect[1]=8191
head.Rect[2]=0
head.Rect[3]=8191
Params in Response:
head=table.VideoWidget[Channel].ChannelTitle (or)
table.VideoWidget[Channel].Covers[CoReg] (or)
table.VideoWidget[Channel].TimeTitle
Channel: video channel index
CoReg: Cover Region, Covers is an array which sustains multi- Cover regions
Page 48
0 = region 1
&VideoWidget[1].Covers[0].BackColor[3]=0
Amcrest Technologies LLC | www.amcrest.com
46
1 = region 2
2 = region 3
3 = region 4
Set video widget config
Tabl e 4-33
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Video Widget config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoWidget[1].Covers[0].BackCol
or[0]=128&VideoWidget[1].Covers[0].BackColor[1]=128&VideoWidget[1].Covers[0].BackColor[2]=128
Success Return OK
Comment
Params in URL:
In below table,
headChannelTitle = VideoWidget[Channel].ChannelTitle
headCover = VideoWidget[Channel].Covers[CoReg]
headTimeTitle = VideoWidget[Channel].TimeTitle
Channel: video channel index
CoReg: Cover region index. Covers is an array which contains multiple cover regions
0 = region 1
1 = region 2
2 = region 3
3 = region 4
Appendix:
ParamName ParamValue type Description
Page 49
headCover.BackColor[0]
Amcrest Technologies LLC | www.amcrest.com
47
integer Range is [0-255].
headCover.BackColor[1]
headCover.BackColor[2]
headCover.BackColor[3]
BackColor[0]:red value
BackColor[1]:green value
BackColor[2]:blue value
BackColor[3]: alpha value
headCover.EncodeBlend bool false - widget blend is disabled.
headCover.FrontColor[0]
headCover.FrontColor[1]
headCover.FrontColor[2]
headCover.FrontColor[3]
integer Range is [0-255].
FrontColor[0]:red value
FrontColor[1]:green value
FrontColor[2]:blue value
FrontColor[3]: alpha value
headCover.Rect[0]
headCover.Rect[1]
integer Range is [0-8191].
Rect[0]: top left corner x coordinate (left)
headCover.Rect[2]
headCover.Rect[3]
headChannelTitle.BackColor[0]
integer Range is the same with headCover
headChannelTitle.BackColor[1]
headChannelTitle.BackColor[2]
headChannelTitle.BackColor[3]
headChannelTitle.EncodeBlend bool
headChannelTitle.FrontColor[0]
integer
headChannelTitle.FrontColor[1]
headChannelTitle.FrontColor[2]
headChannelTitle.FrontColor[3]
Rect[1]: top left corner y coordinate (top)
Rect[2]: bottom right x coordinate (right)
Rect[3]: bottom right y coordinate (bottom)
headChannelTitle.Rect[0] integer Only use the value of (left, top),the value of (right, bottom) is
Page 50
headChannelTitle.Rect[1]
Amcrest Technologies LLC | www.amcrest.com
48
the same as (left, top)
headChannelTitle.Rect[2]
headChannelTitle.Rect[3]
headTimeTitle.BackColor[0]
integer Range is the same with headChannelTitle
headTimeTitle.BackColor[1]
headTimeTitle.BackColor[2]
headTimeTitle.BackColor[3]
headTimeTitle.EncodeBlend bool
headTimeTitle.FrontColor[0]
integer
headTimeTitle.FrontColor[1]
headTimeTitle.FrontColor[2]
headTimeTitle.FrontColor[3]
Rect[0], Rect[1] are used, and Rect[2] must be same with Rect[0], Rect[3] must be same with Rect[1].
These are configs about time title.
headTimeTitle.Rect[0]
integer
headTimeTitle.Rect[1]
headTimeTitle.Rect[2]
headTimeTitle.Rect[3]
headTimeTitle.ShowWeek bool True: Display week within the time title.

4.5.13 Get video input capability

Tabl e 4-34
Syntax http://<server>/cgi-bin/devVideoInput.cgi?action=getCaps&channel=<ChannelNo>
Method GET
Description
Get video input capabilities.
Example http://192.168.1.108/cgi-bin/devV ideoInput.cgi?action=getCaps&channel=1
Success Return
caps. AutoSyncPhase=false
caps. Backlight=2
Page 51
caps. BrightnessCompensation=true
Amcrest Technologies LLC | www.amcrest.com
49
caps. ChipID=0
caps. CoverCount=4
caps. CoverType=1
caps. CustomManualExposure=true
caps. DayNightColor=true
caps. DayNightColorIO=0
caps. DoubleExposure=0
caps. DownScaling=false
caps. EEModeRange=100
caps. ElectricFocus=false
caps. Exposure=16
caps. ExposureMode=31
caps. ExternalSyncInput=0
caps. FishEye=false
caps. FlashAdjust=false
caps. Flip=true
caps. FormatCount=5
caps. Gain=true
caps. GainAuto=true
caps. Gamma=true
caps. GammaModeRange=100
caps. GlareInhibition=1
caps. HorizontalBinning=0
caps. IRCUT=true
caps. ImageEnhancement.LevelRange[0]=0
caps. ImageEnhancement.LevelRange[1]=100
caps. ImageEnhancement.Support=true
caps. InfraRed=true
Page 52
caps. Iris=true
Amcrest Technologies LLC | www.amcrest.com
50
caps. IrisAuto=true
caps. LadenBitrate=972000
caps. LimitedAutoExposure=true
caps. MaxExposureTime=300
caps. MaxExposureTime1=0
caps. MaxHeight=1080
caps. MaxMultiProfile=3
caps. MaxWidth=1920
caps. MeteringRegionCount=0
caps. MinExposureTime=1
caps. MinExposureTime1=0
caps. Mirror=true
caps. MultiOptions=false
caps. NightOptions=true
caps. ReferenceLevel=false
caps. Rotate90=true
caps. SetColor=true
caps. SignalFormats=Inside
caps. SignalType[0]=VGA
caps. SnapshotExposure=false
caps. SupportProfile=false
caps. SupportWhiteLevel=true
caps. SupportWriteLevel=false
caps. SyncChipChannels=false
caps. SyncFocus=0
caps. T itleCount=4
caps. TridimDenoise=2
caps. TridimDenoiseDetails=0
Page 53
Comment
Amcrest Technologies LLC | www.amcrest.com
51
caps. UTC=0
caps. UpScaling=false
caps. Version=0
caps. VerticalBinning=0
caps. V ideoInDenoise.2D.LevelRange[0]=0
caps. V ideoInDenoise.2D.LevelRange[1]=100
caps. V ideoInDenoise.2D.Support=true
caps. V ideoInDenoise.3D.3DAutoType.ModRange[0]=0
caps. V ideoInDenoise.3D.3DAutoType.ModRange[1]=100
caps. V ideoInDenoise.3D.Support=true
caps. V ideoInDenoise.Support=true
caps. WhiteBalance=3
caps. WideDynamicRange=1
Params in URL:
ChannelNo: video channel index
Params in Response:
see below table
Appendix:
Field in response Value type Description
Backlight bool True: support backlight
ChipID String ID of chips in this channel
CoverCount integer The maximum cover region count.
CoverType integer 0: don’t support cover
1: support realtime cover
CustomManualExposure bool, true: support use defined manual exposure time
2: support non-realtime cover
Page 54
DayNightColor bool true: support color alternate between day and night.
Amcrest Technologies LLC | www.amcrest.com
52
DownScaling bool true: support down scaling, binning mode not included.
Exposure integer Exposure grade. 0 – don’t support exposure control.
ExternalSyncInput bool true: support HD signal external synchronization.
FlashAdjust bool true: support flash adjust
Flip bool true: support picture flip.
Gain bool true: support gain control.
GainAuto bool true: support auto gain.
HorizontalBinning integer Horizontal/Vertical pixel binning mask,
VerticalBinning integer
1 – support 2 pixel binning,
2 – support 3 pixel binning
4 - support 4 pixel binning
2^n – support n+2 pixel binning
InfraRed bool true: support Infra compensation
Iris bool true: support Iris adjust
IrisAuto bool true: support auto Iris adjust
LadenBitrate integer Unit is Kbps.
Maximum value of video stream bitrates, 16bpp, not in binning mode.
LimitedAutoExposure bool true: support auto exposure with time limit.
MaxHeight integer Maximum video height
MaxWidth integer Maximum video width
Page 55
Mirror bool true: support picture mirror.
channel=<ChannelNo>]
Amcrest Technologies LLC | www.amcrest.com
53
NightOptions bool true: support night options.
ReferenceLevel bool true: support reference level.
Rotate90 bool
true: support clockwise/anticlockwise 90°rotate
SetColor bool true: support color set.
SignalFormats string It’s a string contains supported video input signal formats for
this channel. Signal formats are separated by comma.
Range is {Inside, BT656, 720p, 1080p, 1080i, 1080sF, 1_3M}
Inside – inside input.
1_3M - 1280*960
SyncChipChannels bool True: channels in same chip should be synchronized.
Synchronized means video resolution of these channels should be the same.
TitleCount integer Maximum count of blending titles.
UpScaling bool true: support up scaling.
WhiteBalance integer Range is {0, 1, 2, 3}
0 – don’t support white balance.
1 – support auto white balance
2 - support auto and pre defined white balance.
3 - support auto, pre defined and user defined white balance

4.5.14 Adjust focus

Tabl e 4-35
Syntax http://<server>/cgi-bin/devVideoInput.cgi?action=adjustFocus&focus=<focusNo>&zoom=<zoomNo>[&
Page 56
Method GET
server
Amcrest Technologies LLC | www.amcrest.com
54
Description
Example http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=adjustFocus&focus=0.5&zoom=-0.5
Success Return OK
Comment
Ajust magnification and the focus.
Params in URL:
focusNo : float, the range is between 0 and 1; -1 means reset to position 0.
zoomNo : float, the range is between 0 and 1; -1 means reset to position 0.
ChannelNo: integer, the video channel index which starts from 1.

4.5.15 Adjust focus continuously

Tabl e 4-36
Syntax http://<
<zoomNo>[&channel=<ChannelNo>]
Method GET
Description
Example
Success Return OK
Comment
Adjust magnification and the focus continuously.
If we want to adjust focus, the API like this:
http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=adjustFocusContinuously&focus=0.02&zoom=
-1
and when the motor is moving, we send below command to let it stop:
http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=adjustFocusContinuously&focus=0&zoom=-1
Params in URL:
focusNo: float, the range is -1 < focus < 1; 0 means stop.
zoomNo: float, the range is -1 < zoom< 1; 0 means stop.
ChannelNo: integer, the video channel index which starts from 1.
>/cgi-bin/devVideoInput.cgi?action=adjustFocusContinuously&focus=<focusNo>&zoom=
The value means the moving speed of motor lens, positive value means move forwards, negative value means move backwards. This command is used to drive the lens move continuously, until it reaches end. When the motor is moving, you can send this command again with “focus or “zoomparameter as 0
Page 57
to stop it immediately.
server
ChannelNo
GET
server
ChannelNo
Amcrest Technologies LLC | www.amcrest.com
55
In this command, when you adjust the focus parameter, the zoom parameter should be -1, and the focus parameter should be -1 when adjust the zoom parameter.

4.5.16 Auto focus

Tabl e 4-37
Syntax http://<
Method
Description Auto focus.
Example http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=autoFocus
Success Return OK
Comment -
>/cgi-bin/devVideoInput.cgi?action=autoFocus[&channel=<

4.5.17 Get focus status

Tabl e 4-38
Syntax http://<
Method GET
Description Get device focus status.
Example http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=getFocusStatus
Success Return
status.Focus=0.5
>/cgi-bin/devVideoInput.cgi?action=getFocusStatus[&channel=<
>]
>]
status.Zoom=0.5
status.Status=Normal
Comment
Params in Response :
The range of status.Status is “Normal” and “Autofocus”. This command must be continual executed until status.Status is “Normal”.

4.5.18 Get coordinates of current window

Tabl e 4-39
Syntax http://<server>/cgi-bin/devVideoInput.cgi?action=getCurrentWindow&channel=<ChannelNo>
Page 58
Method GET
ct[1]=0&rect[2]=5000&rect[3]=5000
Amcrest Technologies LLC | www.amcrest.com
56
Description Get the coordinates of the current window.
Example http://192.168.1.108/cgi-bin/devV ideoInput.cgi?action=getCurrentWindow&channel=1
Success Return
Comment
rect[0]=500
rect[1]=500
rect[2]=5000
rect[3]=5000
Params in URL:
ChannelNo: integer, the video channel index which starts from 1.
Params in Response :
rect[n] : relative coordinates, range is 0-8192.{0,0,0,0} top-left,
{8192,0,0,0} top-right, {0,8192,0,0} bottom-left, {8192,8192,0,0} bottom-right

4.5.19 Set coordinates of current window

Tabl e 4-40
Syntax http://<server>/cgi-bin/devVideoInput.cgi?action=setCurrentWindow&channel=<ChannelNo>&rect[0]
=<rect0>&rect[1]=<rect1>&rect[2]=<rect2>&rect[3]=<rect3>
Method GET
Description Set the coordinates of the current window.
Example http://192.168.1.108/cgi-bin/devVideoInput.cgi?action=setCurrentWindow&channel=1&rect[0]=0&re
Success Return OK
Comment
Params in URL:
ChannelNo: integer, the video channel index which starts from 1.
rect0 & rect1 & rect2 & rect3 : relative coordinates, range is 0-8192.{0,0,0,0} top-left,
{8192,0,0,0} top-right, {0,8192,0,0} bottom-left, {8192,8192,0,0} bottom-right

4.5.20 Video in options

Get video in options
Page 59
Tabl e 4-41
server
GET
Amcrest Technologies LLC | www.amcrest.com
57
Syntax http://<
>/cgi-bin/configManager.cgi?action=getConfig&name=VideoInOptions
Method
Description Get Video In Options config, including Backlight, ExposureSpeed, DayNightColor, DayOptions,
NightOptions, NormalOptions and so on.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=V ideoInOptions
Success Return
head. Backlight=0
head. DayNightColor=false
head. ExposureSpeed=0
head. ExposureValue1=0.100000
head. ExposureValue2=80.000000
head. ExternalSync=0
head. ExternalSyncPhase=0
head. FlashControl.Mode=0
head. FlashControl.Pole=0
head. FlashControl.Value=0
head. FlashControl.PreValue=0
head. Flip=false
head. Gain=50
head. GainAuto=true
head. IrisAuto=false
head. Mirror=false
head. NightOptions.AntiFlicker=0
head. NightOptions.Backlight=0
head. NightOptions.BacklightRegion[0]=3096
head. NightOptions.BacklightRegion[1]=3096
head. NightOptions.BacklightRegion[2]=5096
head. NightOptions.BacklightRegion[3]=5096
head. NightOptions.BrightnessThreshold=50
head. NightOptions.DayNightColor=2
Page 60
head. NightOptions.ExposureMode=0
Amcrest Technologies LLC | www.amcrest.com
58
head. NightOptions.ExposureSpeed=0
head. NightOptions.ExposureValue1=0
head. NightOptions.ExposureValue2=40
head. NightOptions.ExternalSyncPhase=125
head. NightOptions.Flip=false
head. NightOptions.Gain=50
head. NightOptions.GainAuto=true
head. NightOptions.GainBlue=50
head. NightOptions.GainGreen=50
head. NightOptions.GainMax=50
head. NightOptions.GainMin=0
head. NightOptions.GainRed=50
head. NightOptions.GlareInhibition=0
head. NightOptions.IrisAuto=true
head. NightOptions.Mirror=false
head. NightOptions.Profile=3
head. NightOptions.ReferenceLevel=50
head. NightOptions.Rotate90=0
head. NightOptions.SunriseHour=0
head. NightOptions.SunriseMinute=0
head. NightOptions.SunriseSecond=0
head. NightOptions.SunsetHour=23
head. NightOptions.SunsetMinute=59
head. NightOptions.SunsetSecond=59
head. NightOptions.SwitchMode=4
head. NightOptions.WhiteBalance=Auto
head. NightOptions.WideDynamicRange=0
head. NightOptions.WideDynamicRangeMode=0
Page 61
head. NormalOptions.AntiFlicker=0
Amcrest Technologies LLC | www.amcrest.com
59
head. NormalOptions.Backlight=0
head. NormalOptions.BacklightRegion[0]=3096
head. NormalOptions.BacklightRegion[1]=3096
head. NormalOptions.BacklightRegion[2]=5096
head. NormalOptions.BacklightRegion[3]=5096
head. NormalOptions.BrightnessThreshold=50
head. NormalOptions.DayNightColor=1
head. NormalOptions.ExposureMode=0
head. NormalOptions.ExposureSpeed=0
head. NormalOptions.ExposureValue1=0
head. NormalOptions.ExposureValue2=40
head. NormalOptions.ExternalSyncPhase=125
head. NormalOptions.Flip=false
head. NormalOptions.Gain=50
head. NormalOptions.GainAuto=true
head. NormalOptions.GainBlue=50
head. NormalOptions.GainGreen=50
head. NormalOptions.GainMax=50
head. NormalOptions.GainMin=0
head. NormalOptions.GainRed=50
head. NormalOptions.GlareInhibition=0
head. NormalOptions.IrisAuto=true
head. NormalOptions.Mirror=false
head. NormalOptions.Profile=0
head. NormalOptions.ReferenceLevel=50
head. NormalOptions.Rotate90=0
head. NormalOptions.SunriseHour=0
head. NormalOptions.SunriseMinute=0
Page 62
Comment
Amcrest Technologies LLC | www.amcrest.com
60
head. NormalOptions.SunriseSecond=0
head. NormalOptions.SunsetHour=23
head. NormalOptions.SunsetMinute=59
head. NormalOptions.SunsetSecond=59
head. NormalOptions.SwitchMode=0
head. ReferenceLevel=50
head. ReferenceLevelEnable=false
head. Rotate90=0
head. SignalFormat=BT656
head. WhiteBalance=Disable
Params in Response:
head = table.VideoInOptions[ChannelNo]
ChannelNo = video channel index.
Set video in options
Tabl e 4-42
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Video In Options config, including Backlight, ExposureSpeed, DayNightColor, DayOptions, NightOptions, and NormalOptions and so on.
Example
Set Auto Exposure:
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].ExposureMode =0&VideoInOptions[0].ExposureSpeed=0
Set Low Noise:
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].ExposureMode =1&VideoInOptions[0].ExposureSpeed=0&VideoInOptions[0].GainMin=0&VideoInOptions[0].GainMax =60
Page 63
Set Low Motion Blur:
Amcrest Technologies LLC | www.amcrest.com
61
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].ExposureMode =2&VideoInOptions[0].ExposureSpeed=0&VideoInOptions[0].GainMin=0&VideoInOptions[0].GainMax =50&VideoInOptions[0].ExposureValue1=0&VideoInOptions[0].ExposureValue2=20
Set Manual:
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].ExposureMode =4&VideoInOptions[0].ExposureSpeed=32&VideoInOptions[0].GainMin=0&VideoInOptions[0].GainMa x=50&VideoInOptions[0].ExposureValue1=40&VideoInOptions[0].ExposureValue2=40
Set SmartIRExposure:
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&V ideoInOptions[0].SmartIRExposure =true
Set Video Rotate: Filp: http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&V ideoInOptions[0].Flip=true Mirror: http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&V ideoInOptions[0].Mirror=true Or turn 90°: http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].Rotate90=1
Set White Balance: http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].WhiteBalance=Ni ght Or http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].WhiteBalance= Custom&VideoInOptions[0].GainRed=50&VideoInOptions[0].GainBlue=50&VideoInOptions[0].GainGre en=50 (Sometimes you should set mode first before set GainRed or GainBlue: http: / /192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&VideoInOptions[0].WhiteBalance=C ustom )
Success Return OK
Comment
Params in URL:
In below table, head =VideoInOptions[ChannelNo]
ChannelNo = video channel index.
Appendix:
Page 64
ParamName ParamValue
Amcrest Technologies LLC | www.amcrest.com
62
Description
type
head. Backlight integer Range is [0-n]
n depends on capability in GetVideoInputCaps
0 – backlight closed.
1 – backlight grade 1
n – backlight grade n
head. DayNightColor integer Range is {0,1,2}
0: always multicolor
1: autoswitch along with brightness,
2: always monochrome
head. ExposureMode integer Range is {0,1,2, 4}
0: AutoExposure
1: Gain first
2: Exposure first
4: Manual.
head. ExposureSpeed integer Range is [0 - n+1]
n depends on capability in GetVideoInputCaps
0: AutoExposure
1-n-1: manual Exposure grade
n: AutoExposure with time limit.
n+1: manualExposure with user-defined time
(n is supported maximum exposure grade )
head. ExposureValue1 float Range is [0.1-80], unit is millisecond
If ExposureSpeed is 0(AutoExposure enable), it’s lower limit of AutoExposure time, otherwise it’s time of manualExposure
Page 65
head. ExposureValue2 float Range is [0.1-80], unit is millisecond
Amcrest Technologies LLC | www.amcrest.com
63
Upper limit of AutoExposure time, should be bigger than ExposureValue1
head. ExternalSync integer Range is {0,1}
External Synchronous
0: Internal Synchronization
1: External Synchronous
head. ExternalSyncPhase integer Range is [0°-360°]
External Synchronous Signal Phase
head. SmartIRExposure bool true: enable, false: disable
head. FlashControl.Mode integer Range is {0,1,2}
0: forbid flash
1: always flash
2: auto flash
head. FlashControl.Pole integer Range is {0,1, 2, 3}
Trigger mode:
0: low level
1: high level
rising-edge
2:
3: falling-edge
head. FlashControl.Value integer Range is [0-15]
Flashlight time-unit:
0 - 0us,
1 - 64us,
2 - 128us,
3 – 192us
...
Page 66
15 - 960us
Amcrest Technologies LLC | www.amcrest.com
64
head. FlashControl.PreValue integer Range is [0-100]
It is threshold of brightness value: if brightness is less than this value,
flash light will begin to work.
head. Flip bool true: enable video flip function
false: disable video flip function
head. Gain integer Range is [0-100]
If GainAuto is true, it’s upper limit of auto gain, else it’s the fixed gain adjust value.
head. GainBlue integer Range is [0-100]
Gain for blue value, Value is effective when WhiteBalance is “Custom.”
head. GainRed integer Range is [0-100]
Gain for red value, Value is effective when WhiteBalance is “Custom.”
head. GainGreen integer Range is [0-100]
Gain for green value, Value is effective when WhiteBalance is “Custom.”
head. GainAuto bool true: GainAuto
false: No GainAuto
head. IrisAuto bool true: IrisAuto
false: No IrisAuto
head. Mirror bool true: enable video mirror function
false: disable video mirror function
head. WhiteBalance String White balance Mode.
Range is {Disable, Auto, Custom, Sunny, Cloudy, Home, Office, Night}
Some IPC supports common modes: “Disable”, “Auto”, “Sunny”,
“Night”, "Outdoor", ”Custom”
Page 67
Sometimes the device support other advanced modes:
Amcrest Technologies LLC | www.amcrest.com
65
"CustomColorTemperature”, “Indoor", "ATW", "Manual", "AutoOutdoor", “ManualDatum” and so on.
head. ReferenceLevel integer Range is [0-100]
The expected average brightness level of video frames.
head. Rotate90 integer Range is {0,1,2}
Video rotation:
0: No rotate
1: clockwise rotate 90°
2: anticlockwise rotate 90°
head. SignalFormat String Range is {Inside, BT656, 720p, 1080p, 1080i, 1080sF}
Input Signal Mode
head. AntiFlicker integer Range is {0,1,2}
AntiFlicker mode:
0: Outdoor
1: 50 Hz AntiFlicker
2: 60 Hz AntiFlicker
head. GlareInhibition integer Range is [0-100]
GlareInhibition:
0: Close GlareInhibition.
head. NightOptions.BrightnessThreshold
integer NightOptions contain a set of parameters used when brightness is not
enough.
Range is [0-100]
when brightness is less than the BrightnessThreshold, parameters change to Nightoptions.
head. NightOptions.IrisAuto bool true: IrisAuto
false: No IrisAuto
Page 68
head. NightOptions.SunriseHour integer Range is [00-23]
Amcrest Technologies LLC | www.amcrest.com
66
Sunrise hour.
head. NightOptions.SunriseMinute integer Range is [00-59]
Sunrise minute
head. NightOptions.SunriseSecond integer Range is [00-59]
Sunrise second
head. NightOptions.SunsetHour integer Sunset time. Its range is same with sunrise time, and it should be
after sunrise time.
head. NightOptions.SunsetMinute integer
NightOptions are used if time is after sunset time and before sunrise
time.
head. NightOptions.SunsetSecond integer
head. NightOptions.SwitchMode integer Range is {0,1,2}
0: NoSwitch, always use day options.
1: Switch depends on brightness.
2: Switch depends on time, switch to NightOptions when time is after
sunset time and before sunrise.
3: NoSwitch, always use NightOptions.
4: No switch, always use NormalOptions.
head. NightOptions.Profile integer Range is {0,1,2,3}
0: use temporary day options.
1: use temporary NightOptions.
2: use temporary NormalOptions.
3: depends on head.NightOptions.SwitchMode
head. NightOptions.ExposureSpeed
head. NightOptions.ExposureValue1
integer Range is the same as relevant items of day options in this table.
Example:
float
Value range of head.NightOptions.ExposureSpeed is the same with
head. ExposureSpeed.
head. float
Page 69
NightOptions.ExposureValue2
Amcrest Technologies LLC | www.amcrest.com
67
head. NightOptions.Gain integer
head. NightOptions.GainAuto bool
head. NightOptions.GainBlue integer
head. NightOptions.GainGreen integer
head. NightOptions.GainRed integer
head. NightOptions.WhiteBalance String
head. NightOptions.ReferenceLevel integer
head.
integer
NightOptions.ExternalSyncPhase
head. NightOptions.AntiFlicker integer
head. NightOptions.Backlight integer
head. NightOptions.DayNightColor integer
head. NightOptions.ExposureMode integer
head. NightOptions.GlareInhibition integer
head. NightOptions.Mirror integer
head. NightOptions.Flip integer
head. NightOptions.Rotate90 integer
head.
NomalOptions.BrightnessThreshol d
head. NormalOptions.IrisAuto bool
head. NormalOptions.SunriseHour integer
integer NomalOptions contain a set of parameters similar with NightOptions.
Range is the same as relevant items of NightOptions in this table.
Page 70
head.
Amcrest Technologies LLC | www.amcrest.com
68
NormalOptions.SunriseMinute
integer
head.
integer
NormalOptions.SunriseSecond
head. NormalOptions.SunsetHour integer
head.
integer
NormalOptions.SunsetMinute
head.
integer
NormalOptions.SunsetSecond
head.
integer
NormalOptions.ExposureSpeed
head.
float
NormalOptions.ExposureValue1
head.
float
NormalOptions.ExposureValue2
head. NormalOptions.Gain integer
head. NormalOptions.GainAuto bool
head. NormalOptions.GainBlue integer
head. NormalOptions.GainGreen integer
head. NormalOptions.GainRed integer
head.
String
NormalOptions.WhiteBalance
head.
integer
NormalOptions.ReferenceLevel
head.
integer
NormalOptions.ExternalSyncPhase
Page 71
head. NormalOptions.AntiFlicker integer
Amcrest Technologies LLC | www.amcrest.com
69
head. NormalOptions.Backlight integer
head.
integer
NormalOptions.DayNightColor
head.
integer
NormalOptions.ExposureMode
head.
integer
NormalOptions.GlareInhibition
head. NormalOptions.Mirror integer
head. NormalOptions.Flip integer
head. NormalOptions.Rotate90 integer

4.5.21 Video out

Get video out config
Tabl e 4-43
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=V ideoOut
Method GET
Description Get Video Out config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=V ideoOut
Success Return
head.Margin[0]=0
head.Margin[1]=0
head.Margin[2]=0
head.Margin[3]=0
head.Color.Brightness=50
head.Color. Contrast =50
head.Color. Satuation =50
Page 72
head.Color. Hue =50
Amcrest Technologies LLC | www.amcrest.com
70
head.Mode. Width =800
head.Mode. Height=600
head.Mode. BPP =16
head.Mode. Format =“Auto”
head.Mode. RefreshRate =60
Comment
Params in Response:
head = table.VideoOut[channel].
channel: video channel index
Set video out config
Tabl e 4-44
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Video Out config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&table.VideoOut[1].Color.Brightness
=50
Success Return OK
Comment
Params in URL:
In below table,
head = table.VideoOut[channel].
channel: video channel index
Appendix:
ParamName ParamValue type Description
Page 73
head. Margin[0]
Amcrest Technologies LLC | www.amcrest.com
71
head. Margin[1]
head. Margin[2]
head. Margin[3]
head. Color.Brightness integer Brightness
head. Color.Contrast =50 integer Contrast
head.Color.Satuation =50 integer Satuation
head. Color.Hue =50 integer Hue
integer Margin
head. Mode.Width =800
head. Mode.Height=600
head. Mode.BPP =16 integer
head.Mode.Format=“Auto” string The range is {“Auto”, “TV”, “VGA”, “DVI”}
head.Mode.RefreshRate=60 integer Refresh rate.
integer Resolution

4.6 System

4.6.1 General

Get general config
Tabl e 4-45
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=General
Method GET
Description Get General config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=General
Success Return
table.General.MachineName=Test001
Page 74
table.General. LocalNo=8
OK
server
http://192.168.1.108/cgi-bin/global.cgi?action=getCurrentTime
Amcrest Technologies LLC | www.amcrest.com
72
table.General. MachineAddress=“binjiangqv jiangnandadao weiyelu”
table.General. MachineGroup=“jiaojing yidui
Comment -
Set general config
Tabl e 4-46
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description Set General config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&General.MachineName=MyIPC
Success Return
Comment -
Appendix:
ParamName ParamValue type Description
General.MachineName string Device name or serial number.
General. LocalNo integer Local number for remote controller
General. MachineAddress string Address machine places in
General. MachineGroup string Group machine belongs to

4.6.2 Get current time

Tabl e 4-47
Syntax http://<
Method GET
Description Get current time.
Example
Success Return result = 2011-7-3 21:02:32
Comment The time format is "Y-M-D H-m-S". It’s not be effected by Locales. TimeFormat in SetLocalesConfig.
>/cgi-bin/global.cgi?action=getCurrentTime
Page 75

4.6.3 Set current time

server
GET
Amcrest Technologies LLC | www.amcrest.com
73
Tabl e 4-48
Syntax http://<
Method
Description Set current time.
Example http://192.168.1.108/cgi-bin/global.cgi?action=setCurrentTime&time=2016-01-01%2021:02:32
Success Return OK
Comment The time format is "Y-M-D H-m-S". It’s not be effected by Locales. TimeFormat in SetLocalesConfig.
>/cgi-bin/global.cgi?action=setCurrentTime&time=2011-7-3%2021:02:32

4.6.4 Locales

Get locales config
Tabl e 4-49
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Locales
Method GET
Description Get Locales config
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Locales
Success Return
table.Locales.DSTEnable=false
table.Locales.DSTEnd.Day=1
table.Locales.DSTEnd.Hour=0
table.Locales.DSTEnd.Minute=0
table.Locales.DSTEnd.Month=1
table.Locales.DSTEnd.Week=2
table.Locales.DSTEnd.Year=2011
table.Locales.DSTStart.Day=0
table.Locales.DSTStart.Hour=0
table.Locales.DSTStart.Minute=0
table.Locales.DSTStart.Month=1
table.Locales.DSTStart.Week=1
table.Locales.DSTStart.Year=2011
Page 76
table.Locales.TimeFormat=yyyy-MM-dd HH:mm:ss
Amcrest Technologies LLC | www.amcrest.com
74
Comment -
Set locales config
Tabl e 4-50
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Locales config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Locales.DSTEnable=false
Success Return OK
Comment -
Appendix:
ParamName ParamValue
Description
type
Locales.DSTEnable bool Enable/Disable DST (daylight saving time)
Locales.DSTEnd.Day integer Range is [0-6] or [1-31]
[0-6]: week day, 0 = Sunday, 6 = Saturday
[1-31]: month day
If Locales.DSTEnd.Week is 0, use month day, otherwise, use week day.
Locales.DSTEnd.Hour integer Range is [0-23]
Locales.DSTEnd.Minute integer Range is [0-59]
Locales.DSTEnd.Month integer Range is [1-12]
Locales.DSTEnd.Week Integer Range is {1, 2, 3, 4, -1, 0}.
0 = Use month day
[1, 2, 3, 4, -1]: use week day.
1 = first week, 2 = second, 3 = third, 4 = fourth, -1 = last.
Page 77
Locales.DSTEnd.Year Integer Range is [2000-2038]
Amcrest Technologies LLC | www.amcrest.com
75
Locales.DSTStart.Day Range is the same with items in Locales.DSTEnd.
Locales.DSTStart.Hour
time range of DST.
Locales.DSTStart.Minute
Locales.DSTStart.Month
Locales.DSTStart.Week
Locales.DSTStart.Year
Locales.TimeFormat string Defines time format displayed in video time title.
String form is: year-month-day hour:mm:ss.
Position of year, month and day can be exchanged.
Range of year is {yy, yyyy}
yy = year without century, yyyy = year with century.
Locales.DSTStart table and Locales.DSTEnd table define the
Range of month is {M, MM, MMMM}
M = 1 for January, MM = 01 for January, MMMM = Jan for January
Range of day is {d, dd}
d = 1 for first day, dd = 01 for first day
Range of hour is {H, HH, h, hh}
H = 1 for 1:00, HH = 01 for 1:00, range is 0-23
h = 1 for 1:00, hh = 01 for 1:00, time range is 1-12
Example:
yyyy-MM-dd HH:mm:ss or
MM-dd-yyyy HH:mm:ss or
dd-M-yy hh:mm:ss
Page 78

4.6.5 Get language capability

server
GET
server
server
NOTE: After changing language setting, system will automatically reboot!
Amcrest Technologies LLC | www.amcrest.com
76
Tabl e 4-51
Syntax http://<
Method
Description Get the list of supported languages.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getLanguageCaps
Success Return Languages=SimpChinese,English,French
Comment
response is a string contains languages with comma separated.
Languages include
{English, SimpChinese, TradChinese, Italian, Spanish, Japanese, Russian, French, German}
>/cgi-bin/magicBox.cgi?action=getLanguageCaps

4.6.6 Language

Get language config
Tabl e 4-52
Syntax http://<
Method GET
Description Get system language config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Language
Success Return table.Language=SimpChinese
Comment -
Set language config
Tabl e 4-53
Syntax http://<
mName>=<paramValue>...]
Method GET
Description Set system language config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Language=SimpChinese
Success Return OK
Comment
>/cgi-bin/configManager.cgi?action=getConfig&name=Language
>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
Page 79
Appendix:
server
Amcrest Technologies LLC | www.amcrest.com
77
ParamName ParamValue type Description
Language string The language range is get from interface in GetLanguageCaps

4.6.7 Client access filter

Get access filter config
Tabl e 4-54
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=AccessFilter
Method GET
Description Get Access Filter config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=AccessFilter
Success Return
table.AccessFilter.BannedList[bannedIndex]=10.6.10.1
table.AccessFilter. TrustList[trustIndex]=1.2.3.4
table.AccessFilter.Enable=false
table.AccessFilter.Type=BannedList
Comment
Params in Response:
bannedIndex is the banned IP list index.
trustIndex is the trust IP list index.
Set access filter config
Tabl e 4-55
Syntax http://<
>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description Set Access Filter config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&AccessFilter.BannedList[0]=192.16
8.1.1&AccessFilter.Type=BannedList
Success Return OK
Comment
Params in Response:
Page 80
In below table,
Amcrest Technologies LLC | www.amcrest.com
78
index is the IP list index, it's range is [0-255]
Appendix:
ParamName ParamValue type Description
AccessFilter.BannedList[index] string Banned IP address list
AccessFilter.TrustList[index] string Trusted IP address list
AccessFilter.Enable bool Enable/Disable access filter function
AccessFilter.Type string Range is {TrustList, BannedList},
TrustList: Trust list is used, banned list is not used.
BannedList: Banned list is used, trust list is not used.

4.6.8 Auto maintain

Get auto maintain config
Tabl e 4-56
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=AutoMaintain
Method GET
Description Get Auto Maintain config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=AutoMaintain
Success Return
table.AutoMaintain. AutoRebootDay=3
table.AutoMaintain. AutoRebootHour=0
table.AutoMaintain. AutoRebootMinute=0
table.AutoMaintain. AutoShutdownDay=1
table.AutoMaintain. AutoShutdownHour=0
Page 81
table.AutoMaintain. AutoShutdownMinute=0
Amcrest Technologies LLC | www.amcrest.com
79
table.AutoMaintain. AutoStartUpDay=1
table.AutoMaintain. AutoStartUpHour=2
table.AutoMaintain. AutoStartUpMinute=0
Comment -
Set auto maintain config
Tabl e 4-57
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description Set Auto Maintain config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&AutoMaintain.AutoRebootDay=7
Success Return OK
Comment -
Appendix:
ParamName ParamValue
Description
type
AutoMaintain. AutoRebootDay integer Range is [-1-7].
Auto restart day.
-1 = never auto restart
0- 6 = Sunday-Saturday
7 = restart every day
AutoMaintain. AutoRebootHour integer Range is [0-23].
Auto restart hour
AutoMaintain. AutoRebootMinute integer Range is [0-59].
AutoMaintain. AutoShutdownDay integer auto reboot time
Auto restart minute
Page 82
AutoMaintain. AutoShutdownHour
Comment
-
Amcrest Technologies LLC | www.amcrest.com
80
Range is same with AutoOpenDay, AutoOpenHour and AutoOpenMinute.
AutoMaintain. AutoShutdownMinute
AutoMaintain. AutoStartUpDay integer Auto shutdown time.
AutoMaintain. AutoStartUpHour
AutoOpenMinute.
AutoMaintain. AutoStartUpMinute

4.6.9 Holiday management

Get holiday config
Tabl e 4-58
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Holiday
Method GET
Description Get holiday config for record or snap.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Holiday
Range is same with AutoOpenDay, AutoOpenHour, and
Success Return
table.Holiday.MonthMask[0]=3
table.Holiday.MonthMask[1]=0
table.Holiday.MonthMask[2]=0
table.Holiday.MonthMask[3]=0
table.Holiday.MonthMask[4]=0
table.Holiday.MonthMask[5]=0
table.Holiday.MonthMask[6]=0
table.Holiday.MonthMask[7]=0
table.Holiday.MonthMask[8]=0
table.Holiday.MonthMask[9]=1610612739
table.Holiday.MonthMask[10]=0
table.Holiday.MonthMask[11]=0
Page 83
server
Amcrest Technologies LLC | www.amcrest.com
81
Set holiday config
Tabl e 4-59
Syntax http://<
>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set holiday config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Holiday.MonthMask[0]=3
Success Return OK
Comment
Params in URL:
In below table,
monthIndex presents the index of a month. 0 presents January, 1 presents February, 11 presents December.
Appendix:
ParamName ParamValue type Description
Holiday.MonthMask[monthIndex] integer It is the mask of a month.Every bit present a day. For
example, 0x0001 presents the first day of a month is holiday. 0x0002 presents the second day of a month is holiday, 0x0003 presents the first day and second day of a month is holiday.

4.6.10 Get device type

Tabl e 4-60
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getDeviceType
Method GET
Description Gets the device type displaying which is not the true type.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getDeviceType
Success Return type=DVR
Comment -
Page 84

4.6.11 Get hardware version

server
GET
server
Amcrest Technologies LLC | www.amcrest.com
82
Tabl e 4-61
Syntax http://<
Method
Description Get the device hardware version.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getHardwareVersion
Success Return version=1.00
Comment -
>/cgi-bin/magicBox.cgi?action=getHardwareVersion

4.6.12 Get serial number of device

Tabl e 4-62
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getSerialNo
Method GET
Description Get the device serial number.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getSerialNo
Success Return sn=YZC0GZ05100020
Comment -

4.6.13 Get machine name

Tabl e 4-63
Syntax http://<
Method GET
Description Get the device machine name.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getMachineName
Success Return name=YZC0GZ05100020
Comment -
>/cgi-bin/magicBox.cgi?action=getMachineName

4.6.14 Get system information

Tabl e 4-64
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getSystemInfo
Page 85
Method GET
Comment
-
http://<
>/cgi-bin/magicBox.cgi?action=getSoftwareVersion
Amcrest Technologies LLC | www.amcrest.com
83
Description Get the system information.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getSystemInfo
Success Return
Comment -
serialNumber= PA1FQ15900207
deviceType=27
processor= ST7108

4.6.15 Get vendor information

Tabl e 4-65
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getVendor
Method GET
Description Get the Vendor information.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getVendor
Success Return vendor=TTT

4.6.16 Get software information

Tabl e 4-66
Syntax
Method GET
Description Get the software information.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getSoftwareVersion
Success Return version=2.212.0000.0.R,build:2013-11-14
Comment -
server

4.6.17 Get version of Onvif

Tabl e 4-67
Syntax http://<server>/cgi-bin/IntervideoManager.cgi?action=getVersion&Name=Onvif
Method GET
Description Get Onvif version.
Page 86
Example http://192.168.1.108/cgi-bin/IntervideoManager.cgi?action=getVersion&Name=Onvif
server
http://192.168.1.108/cgi-bin/IntervideoManager.cgi?action=getVersion&Name=CGI
Amcrest Technologies LLC | www.amcrest.com
84
Success Return version=2.4.2
Comment -

4.6.18 Get version of HTTP API

Tabl e 4-68
Syntax http://<
Method GET
Description Get CGI version.
Example
Success Return version=2.0.0
Comment -
>/cgi-bin/IntervideoManager.cgi?action=getVersion&Name=CGI

4.6.19 Get device class

Tabl e 4-69
Syntax http://<server>/cgi-bin/magicBox.cgi?action=getDeviceClass
Method GET
Description Get the Device Class.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=getDeviceClass
Success Return class=HDVR
Comment -

4.6.20 Onvif service authorization

Get config of Onvif service authorization
Tabl e 4-70
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=UserGlobal
Method GET
Description Get User Global config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=UserGlobal
Success Return table.UserGlobal.OnvifLoginCheck=false
Page 87
Comment If “OnvifLoginCheck” is false, you can get Onvif service directly; if true, you should enter your
server
Example
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&UserGlobal.OnvifLoginCheck=true
Amcrest Technologies LLC | www.amcrest.com
85
ID/username and password.
Set config of Onvif service authorization
Tabl e 4-71
Syntax http://<
>/cgi-bin/configManager.cgi?action=setConfig&UserGlobal.OnvifLoginCheck=<flag>
Method GET
Description Enable Onvif login check or not.
Success Return OK
Comment
Params in URL:
flag : range is {true, false}.

4.6.21 Backup of config

Tabl e 4-72
Syntax http://<server>/cgi-bin/Config.backup?action=All
Method GET
Description Download all the settings of a device as a file named Config. Backup default.
Example http://192.168.1.108/cgi-bin/Config.backup?action=All
Success Return
HTTP/1.1 200 OK
CONTENT-LENGTH: 743087
CONNECTION: close
Content-type: application/binarytet-stream; charset=utf-8
{
"ATM" : {
"DataSource" : "RS232",
"DisplayPostion" : "lefttop",
"EncodeBlend" : true,
"PreviewBlend" : true,
Page 88
"ProtocolAbility" : [ "POS" ],
server
Amcrest Technologies LLC | www.amcrest.com
86
"ProtocolName" : "ATM\/POS",
"RecordChannels" : [ 0, 1, 2, 3 ]
}
……
}
Comment -

4.6.22 Restore the config

Tabl e 4-73
Syntax http://<
Method GET
Description Restore config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=restore&names[0]=UPnP
Success Return OK
Comment
Params in URL:
xxx and yyy is config name which need to be restore
>/cgi-bin/configManager.cgi?action=restore&names[0]=<xxx>&names[1]=<yyy>[&...]

4.6.23 Restore except the config

Tabl e 4-74
Syntax http://<server>/cgi-bin/configManager.cgi?action=restoreExcept&names[0]=<xxx>&names[1]=<yyy>[
&...]
Method GET
Description
Restore all config except several.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=restoreExcept&names[0]=UPnP
Success Return OK
Comment
Params in URL:
All the config file but xxx and yyy will be restored.
Page 89

4.6.24 Reboot

Comment
If successful, response OK. If fail, response Error.
http://<
>/cgi-bin/magicBox.cgi?action=shutdown
Amcrest Technologies LLC | www.amcrest.com
87
Tabl e 4-75
Syntax
Method GET
Description Reboot the device
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=reboot
Success Return OK
http://<server>/cgi-bin/magicBox.cgi?action=reboot[&delay=<paramValue>]

4.6.25 Shutdown

Tabl e 4-76
Syntax
Method GET
Description Shutdown the device.
Example http://192.168.1.108/cgi-bin/magicBox.cgi?action=shutdown
Success Return OK
Comment If successful, response OK. If fail, response Error.
server

4.7 Network

4.7.1 Get network interfaces

Tabl e 4-77
Syntax http://<server>/cgi-bin/netApp.cgi?action=getInterfaces
Method GET
Description Get all of the system network interfaces.
Example http://192.168.1.108/cgi-bin/netApp.cgi?action=getInterfaces
Success Return
netInterface[0].Name=eth0
netInterface[0].Type=Normal
Page 90
Comment
name, host name), and configuration of each network interface.
Amcrest Technologies LLC | www.amcrest.com
88
netInterface[0].Valid=true
result item value:
Name: network interface name.
“eth0” - wired network interface
“eth2” - wireless network interface
“3G” - 3G network interface
Type: “Normal” – wired network
“Wireless” – wireless network
"Auto", "TD-SCDMA", "WCDMA", "CDMA1x", "EDGE", "EVDO" – 3G network types.
Valid: network interface is valid if netInterface[n].Valid is true.

4.7.2 Network basic config

Get network config
Tabl e 4-78
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Network
Method GET
Description Get network basic config. Basic config contains basic network parameters (Default interface, domain
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Network
Success Return
table.Network.DefaultInterface=eth0
table.Network.Domain=ttt
table.Network.Hostname=badak
table.Network.interface.DefaultGateway=10.7.0.1
table.Network.interface.DhcpEnable=false
Page 91
table.Network.interface.DnsServers[0]=221.123.33.228
Amcrest Technologies LLC | www.amcrest.com
89
table.Network.interface.DnsServers[1]=221.12.1.228
table.Network.interface.IPAddress=10.7.2.3
table.Network.interface.MTU=1500
table.Network.interface.PhysicalAddress=00:10:5c:f2:1c:b4
table.Network.interface.SubnetMask=255.255.0.0
Comment interface in response is network interface name, such as eth0, eth2…
Set network config
Tabl e 4-79
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set network basic config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&NetWork.Domain=ttt&NetWork.et
h0.DhcpEnable=true
Success Return OK
Comment interface in below ParamName is network interface name, such as eth0, eth2…
Appendix:
ParamName ParamValue type Description
Network. DefaultInterface string Set default network interface when multiple
interfaces exist.
Range of interfaces is depends on GetInterfaces
.
Network. Domain string Domain name.
Network. Hostname string Hostname and Domain compose a network address.
Network. interface.DefaultGateway
Network. interface.DhcpEnable bool Enable/Disable DHCP.
string IP address.
Page 92
Network. interface.DnsServers[0] string IP address of first DNS server.
http://<
>/cgi-bin/configManager.cgi?action=getConfig&name=PPPoE
table.PPPoE.UserName=123456
Amcrest Technologies LLC | www.amcrest.com
90
Network. interface.DnsServers[1] string IP address of second DNS server.
Network. interface.IPAddress string Interface IP address.
Network. interface.MTU integer Interface MTU.
Network. interface.PhysicalAddress
string MAC address of interface.
HEX string in the form of:
xx:xx:xx:xx:xx:xx.
Range of x is [0-9, a-f, A-F]
Example:
00:10:5c:f2:1c:b4
00:10:5C:F2:1C:B5
Network. interface.SubnetMask string Network mask string:
In the form of x.x.x.x, range of x is [0-255]
Example:
255.255.255.0

4.7.3 PPPoE

Get PPPoE config
Tabl e 4-80
Syntax
Method GET
Description Get PPPoE config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=PPPoE
Success Return
table.PPPoE.Enable=false
table.PPPoE.Password=123456
server
Page 93
Comment -
Amcrest Technologies LLC | www.amcrest.com
91
Set PPPoE config
Tabl e 4-81
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set PPPoE config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&PPPoE.UserName=user1&PPPoE.P
assword=123456
Success Return OK
Comment -
Appendix:
ParamName ParamValue type Description
PPPoE. Enable bool Enable/Disable PPPoE.
PPPoE. UserName string PPPoE user name.
PPPoE. Password string PPPoE user password.

4.7.4 DDNS

Get DDNS config
Tabl e 4-82
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=DDNS
Method GET
Description Get DDNS config
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=DDNS
Success Return
table.DDNS[index].Address=www.ttt.com
table.DDNS[index].Enable=true
Page 94
table.DDNS[index].HostName=www.ttt.com
Amcrest Technologies LLC | www.amcrest.com
92
table.DDNS[index].KeepAlive=10
table.DDNS[index].Password=none
table.DDNS[index].Port=5050
table.DDNS[index].Protocol= Quick DDNS
table.DDNS[index].UserName=user1
table.DDNS[index].DefaultHostName.Enable=false
table.DDNS[index].DefaultHostName.HostName=9002A9D77133.quickddns.com
Comment
index in response is the DDNS protocol table index, start from 0.
the meaning of params can refer to SetDDNSConfig chapter.
Set DDNS config
Tabl e 4-83
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set DDNS config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&DDNS[0].Address=www.ttt.com&D
DNS[0].Enable=true
Success Return OK
Comment index in below ParamName is the DDNS protocol table index, start from 0.
Appendix:
ParamName ParamValue type Description
DDNS[index].Address string DDNS server IP address or name.
DDNS[index].Enable bool Multiple DDNS hostname can be
configured, but Only one hostname can be enabled, others should be disabled.
DDNS[index].HostName String Hostname of this device.
Page 95
DDNS[index].KeepAlive integer Range is [1-65535].
Amcrest Technologies LLC | www.amcrest.com
93
Unit is minutes.
DDNS[index].Password string DDNS user password
DDNS[index].Port integer Range is [1-65535].
Port of DDNS server
DDNS[index].Protocol string DDNS protocol type.
Range is {"NO-IP DDNS", "Dyndns DDNS", "Private DDNS", "DHDDNS", "QUICK DDNS”}.
DDNS[index].UserName string DDNS user name
DDNS[index].DefaultHostName.Enable bool Only protocol is in range {"Private DDNS",
"DHDDNS", "QUICK DDNS"}, it effects.
true : use the DefaultHostName.HostName
false: use the HostName
DDNS[index].DefaultHostName.HostName string The default hostname. It cannot be
modified.

4.7.5 Email

Get email config
Tabl e 4-84
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=Email
Method GET
Description Get Email config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=Email
Success Return
table.Email.Address=www.ttt.com
table.Email.Anonymous=true
Page 96
table.Email.AttachEnable=true
Amcrest Technologies LLC | www.amcrest.com
94
table.Email.AttachmentEnable=true
table.Email.Enable=true
table.Email.HealthReport.Enable=false
table.Email.HealthReport.Interval=61
table.Email.Password=123456
table.Email.Port=26
table.Email.Receivers[0]=x@tttt.com
table.Email.Receivers[1]=y@ttt.com
table.Email.Receivers[2]=z@ttt.com
table.Email.SendAddress=x@ttt.com
table.Email.SslEnable=false
table.Email.Title=DVRMessage
table.Email.UserName=anonymity
Comment -
Set email config
Tabl e 4-85
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Set Email config.
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&Email.Address=mail.ttt.com&Email
.Anonymous=false
Success Return OK
Comment -
Appendix:
ParamName ParamValue type Description
Email. Address string SMTP server IP address or name.
Page 97
Email. Anonymous bool Enable/Disable anonymous email.
Amcrest Technologies LLC | www.amcrest.com
95
Email. AttachEnable bool Enable/Disable email attachment
Email. AttachmentEnable bool Enable/Disable email attachment
Email. Enable bool Enable/Disable email function
Email. HealthReport.Enable bool Enable/Disable report device status by email.
Email. HealthReport.Interval integer Range is [30-1440].
Unit is minutes
Email. Password string User password of email account.
Email. Port integer Range is [1-65535]
Email. Receivers[0] string Email addresses of 3 receivers.
Email. Receivers[1] string
Email. Receivers[2] string
Email. SendAddress string Sender email address.
Email. SslEnable bool True: enable SSL email.
Email. Title string Title of email.
Email. UserName string User name of email account.

4.7.6 WLan

Get WLan config
Tabl e 4-86
Syntax http://<server>/cgi-bin/configManager.cgi?action=getConfig&name=WLan
Method GET
Page 98
Description Get Wlan config
Amcrest Technologies LLC | www.amcrest.com
96
Example http://192.168.1.108/cgi-bin/configManager.cgi?action=getConfig&name=WLan
Success Return
table.WLan.eth2.Enable=true
table.WLan.eth2.Encryption=off
table.WLan.eth2.KeyFlag=false
table.WLan.eth2.KeyID=0
table.WLan.eth2.KeyType=Hex
table.WLan.eth2.Keys[0]=password1
table.WLan.eth2.Keys[1]=password2
table.WLan.eth2.Keys[2]=password3
table.WLan.eth2.Keys[3]=password4
table.WLan.eth2.LinkMode=Auto
table.WLan.eth2.SSID=ttt
Comment -
Set WLan config
Tabl e 4-87
Syntax http://<server>/cgi-bin/configManager.cgi?action=setConfig&<paramName>=<paramValue>[&<para
mName>=<paramValue>...]
Method GET
Description
Example
Set WLan config.
http://192.168.1.108/cgi-bin/configManager.cgi?action=setConfig&WLan.eth2.Enable=true&WLan.eth
2.KeyType=Hex
Success Return OK
Comment In below ParamName, interface is name of wireless interface.
Appendix:
ParamName ParamValue type Description
WLan.interface.Enable bool True: Enable WLan on this interface.
Page 99
WLan.interface.Encryption string Range is {Off, On, WEP64Bits, WEP128Bits,
server
Amcrest Technologies LLC | www.amcrest.com
97
WPA-PSK-TKIP, WPA-PSK-CCMP}
Encryption mode.
WLan.interface.KeyFlag bool true: key is configured.
WLan.interface.KeyID integer Range is [0-3]
Indicates which key is used.
0: WLan.interface.Keys[0] is used.
WLan.interface.KeyType string Range is {Hex, ASCII]
WLan.interface.Keys[0] string For ASCII key type: 64bits encryption key
length is 5, 128bits encryption key length is 13,
WLan.interface.Keys[1] string
consists of [0-9, a-z, A-Z]
WLan.interface.Keys[2] string
For HEX key type: 64bits encryption key length
WLan.interface.Keys[3] string
is 10, 128bits encryption key length is 26, consists of [0-9, a-z, A-Z]
WLan.interface.LinkMode string Range is {Auto, Ad-hoc, and Infrastructure}.
Auto – select suitable mode automatically.
Ad-hoc – Device with wireless network adapter can connect to each other without Access Point.
Infrastructure – Integrate wire and wireless LAN together to share network resource, access point is need in this mode.
WLan.interface.SSID string

4.7.7 Scan Wlan devices

Tabl e 4-88
Syntax http://<
Name>=<paramValue>...]
>/cgi-bin/wlan.cgi?action=scanWlanDevices&<paramName>=<paramValue>[&<param
Page 100
Method GET
server
Description
Get UPnP config.
Amcrest Technologies LLC | www.amcrest.com
98
Description
Search Wi-Fi device information
Example http://192.168.1.108/cgi-bin/wlan.cgi?action=scanWlanDevices&SSID=xia_yuguo 13098 Internet
Success Return
found=1
wlanDevice[0].ApConnected=0
wlanDevice[0].ApMaxBitRate=54000000
wlanDevice[0].ApNetWorkType=255
wlanDevice[0].AuthMode=7
wlanDevice[0].BSSID=28:2c:b2:5c:de:36
wlanDevice[0].EncrAlgr=3
wlanDevice[0].LinkMode=0
wlanDevice[0].LinkQuality=31
wlanDevice[0].RSSIQuality=0
wlanDevice[0].SSID=xia_yuguo 13098 Internet
Comment -
Appendix:
ParamName ParamValue type Description
SSID string Specified SSID, if not include any SSID, all Wi-Fi
information will be searched and displayed.

4.7.8 UPnP

Get UPnP config
Tabl e 4-89
Syntax http://<
Method GET
>/cgi-bin/configManager.cgi?action=getConfig&name=UPnP
Loading...