Return Message of URL

> The return message of URL are defined as followed the HTTP standard. To all devices, there are two parts of the return message of the URL. These two parts of message were sent in two TCP packets. The first part is the HTTP status header for return code and the second part is the return message of URL.

> Example of the return message of the URL to read WAN_TYPE.

> HTTP/1.0 200 OK
> Content-type: text/plain
> WAN_TYPE='1'

> Example of the return message of the URL to set WAN_TYPE=1

> HTTP/1.0 200 OK
> Content-type: text/plain
> OK: WAN_TYPE='1'

> Example of the return message of the URL to set WAN_TYPE=0 (incorrect argument)

> HTTP/1.0 200 OK
> Content-type: text/plain
> ERROR: WAN_TYPE='1'

HTTP Status Header

> The format of the HTTP status code is

> HTTP/1.0 <HTTP_CODE> <HTTP_TEXT> \r\n

> The most used HTTP codes are listed below.

> HTTP_CODE | HTTP_TEXT | Description
> 200 | OK | Valid URL Comnand
> 400 | Unauthorize | Error in authentication
> 401 | Not Found | General Error

Return Message

> In general, there are five types of the return message of the URL.

> 1. CMD='VALUE'
> 2. OK: CMD='VALUE'
> 3. OK
> 4. ERROR: CMD='VALUE'
> 5. ERROR: Descriptions of Error

> Please refer the Description of URL to get the format of URL for further details.

> Note that the HTTP return code is 200 in the return message type 4 and 5. User should not use the HTTP return code to check if the device accepts the URL command or not.

> 1. CMD='VALUE'

> This return message is used in the READ URL command. The device will echo this URL command and give the value in the two ' ' symbols.

> If there is more than one URL in the URL command, the return message of every URL will be shown. For example,

> Return Message of the URL WAN_TYPE is

> WAN_TYPE='1'

> Return Message of the URL WAN_TYPE&WAN_IP is

> WAN_TYPE='1'
> WAN_IP='192.168.0.100'

> 2. OK: CMD='VALUE'

> This return message is used in the WRITE URL command. The device will echo this URL command and give the value after this command in the two ' ' symbols.

> If there is more than one URL in the URL command, the return message of every URL will be shown. For example,

> Return Message of the URL WAN_TYPE=1 is

> OK: WAN_TYPE='1'

> Return Message of the URL WAN_TYPE=1&WAN_IP=192.168.1.100 is

> OK: WAN_TYPE='1'
> OK: WAN_IP='192.168.0.100'

> 3. OK

> This return message is used in the ACTION URL command like SAVE, REBOOT, FACTORY_DEFAULT and so on. There is no value returned for this command. For example,

> Return Message of the URL REBOOT is

> OK

> 4. ERROR: CMD='VALUE'

> This return message is used in the WRITE URL command but the input argument is incorrect. The device will echo this URL command and give the value which is the setting in the device.

> If there is more than one URL in the URL command, the return message of every URL will be shown. For example,

> Return Message of the URL WAN_TYPE=0 where the range of WAN_TYPE is 1~3:

> ERROR: WAN_TYPE='1'

> It shows the current WAN_TYPE setting inn the device is 1.

> Return Message of the URL WAN_TYPE=0&WAN_IP=192.168.1.100 is

> ERROR: WAN_TYPE='1'
> OK: WAN_IP='192.168.0.100'

> It shows the argument of WAN_TYPE setting is incorrect and the WAN_TYPE configuration is not updated, but the WAN_IP setting is updated successfully.

> 5: ERROR: Description of Error

> This return message is for the error condition which could not be described in the ERROR: CMD='VALUE' format. The URL likes read or write only command or action command might have such kind to return message. Here is the summary of the possible error return message in this format.

> Description of Error | Description
> missing USER/PWD | The USER or PWD command was not found in the Type1 URL
> bad account/password | The user account name or password is incorrect in the Type1 URL.
> missing CHANNEL | The CHANNEL command was not found
> bad CHANNEL=n | The channel n Video Server is not active in the Multi-Channel Encoder device or the channel n is out of range in the Multi-Channel Encoder device
> CMD not found | The device does not support this CMD
> CMD is write-only | The CMD is write only in the device
> CMD is read-only | The CMD is read only in the device
> not authorized | The CMD is not allow to be execute because of lower logon level.
> invalid parameters | The input argument is incorrect in the Write-Only Command.
> no command | There is no URL command
> firmware imagenote1 | Firmware image file is corrupted or MD5 check error in firmware upgrade URLs
> firmware versionnote1 | Firmware version mismatches in firmware upgrade URLs
> firmware typenote1 | Firmware Type error (AC/NB mismatches) in firmware upgrade URLs
> config image | Configuration file is corrupted
> oem image | OEM image file is corrupted
> profile image | Camera Profile image file is corrupted
> profile IDnote1 | Profile ID mismatches in profile upgrade URLs
> internal error <more description> | There is an error internally. There might be more description of the error

> note1 : In Multi-Channel Encoder, the firmware or profile upgrade URLs could update many Video Servers. The error message for these URLs will give the CHANNEL ID to identify which video server fails of upgrading. For example, the error message might look like that.

> ERROR: CHANNEL=1 firmware image

Back to

> HOME