Documentation for Axxon One 1.0.

Previous page Get camera events using WebSocket  Working with layouts and videowalls Next page

Working with layouts and videowalls

Sequence of actions

Before one starts working with layouts and videowalls HTTP API, run this command in the command prompt:

netsh http add urlacl url=http://IP-Adress:8888/ user=DOMAIN\username

Note

On Linux, no additional commands are required.

where DOMAIN\username relates to Windows (whoami command in the command prompt). Port 8888 is to be vacant, antivirus and/or firewall are to be disabled.

Attention!

All requests for working with layouts and videowalls are performed on the Client that is to be run as administrator.

The Client's IP-Address is to be specified in the requests.

Attention!

If there are any errors, run the command prompt as administrator and then run the command once again.

When the command is successfully executed, one can make requests listed below.

Getting the list of layouts

GET http://IP-adress:8888/GetLayouts − getting available layouts for current logged user.

Sample response:

{
    "Description": "",
    "Status": "OK",
    "LayoutInfo": [
        {
            "Id": "102",
            "Name": "Layout name 2"
        },
        { 
			"Id": "103",
            "Name": "Layout name 3"
        }
    ]
}

Here is an example of an error message:

 {
\"result\":\"no layouts\"
}

Note

An error can occur while requesting the list of Server layouts if the UAC is enabled on the Server. Disable this function in order to eliminate the error.

Switching the layout on the screen

GET http://IPaddress:8888/SwitchLayout
ParametrRequiredDescription
layoutIdYesLayout id (see Getting the list of layouts).
displayIdYesMonitor id (see Getting the list of displays).

Sample request:

GET http://127.0.0.1:8888/SwitchLayout?layoutId=102&displayId=\\.\DISPLAY1

Sample response:

{
    "Description": "",
    "Status": "OK"
}

Here is an example of an error message:

{
	\"result\":\"error\"
}

Note

An error can occur if a layout with non-existent ID is specified.

Getting the list of cameras displayed on the layout

GET http://IPaddress:8888/GetCameras
ParametrRequiredDescription
layoutIdYes

Layout id (see Getting the list of layouts).

If the layout with specified id will not be found, then the query will return the list of cameras of the current layout for the specified display.

displayIdYesMonitor id (see Getting the list of displays).

Sample request:

GET http://127.0.0.1:8888/GetCameras?layoutId=102&displayId=\\.\DISPLAY1

Sample response:

{
    "Description": "",
    "Status": "OK",
    "CameraInfo": [
        {
            "DisplayName": "1.Camera",
            "Id": "1",
            "Name": "host/HOSTNAME/DeviceIpint1/SourceEndPoint.video:0:0"
        },
        {
            "DisplayName": "2.Camera",
            "Id": "2",
            "Name": " host/HOSTNAME/DeviceIpint2/SourceEndPoint.video:0:0"
        }
    ]
}

Adding and removing cameras

Removing a camera from the current layout

GET http://IP-address:8888/RemoveCamera

ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.

Sample request:

GET http://127.0.0.1:8888/RemoveCamera?displayId=\\.\DISPLAY1&cameraName=host/HOSTNAME/DeviceIpint1/SourceEndPoint.video:0:0

Sample responce:

{ 
	"Description": "", 
	"Status": "OK" 
}

Here is an example of an error message:

{ 
	"Description": "Error description", 
	"Status": "ERROR" 
}

Removing all cameras from the current layout

GET http://IP-address:8888/RemoveAllCameras

ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).

Sample request:

GET http://127.0.0.1:8888/RemoveAllCameras?displayId=\\.\DISPLAY1

Adding a camera to the current layout

GET http://IP-address:8888/AddCamera

ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.


Sample request:

GET http://127.0.0.1:8888/AddCamera?displayId=\\.\DISPLAY1&cameraName=host/HOSTNAME/DeviceIpint1/SourceEndPoint.video:0:0

Getting the list of displays

GET http://IP-address:8888/GetDisplays − getting available displays for current logged user.

Sample response:

{
    "Description": "",
    "Status": "OK",
    "DisplayInfo": [
        {
            "Id": "\\\\.\\DISPLAY1",
            "IsMainForm": true
        },
        {
            "Id": "\\\\.\\DISPLAY2",
            "IsMainForm": false
        }
    ]
}
ParametrDescription
id

Display ID.

IsMainForm

The 'true' value corresponds to the main display.

Attention! In other requests, use the monitor Id in the following format: \\.\DISPLAY1.

Here is an example of an error message:

{
	"{\"result\":\"no displays\"}"
}

Selecting active display

GET http://IP-address:8888/SelectDisplay
ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).

Sample request:

GET http://127.0.0.1:8888/SelectDisplay?displayId=\\.\DISPLAY1

Sample responce:

{
"Description": "",  
"Status": "OK"
}

Here is an example of an error message:

{
	\"result\":\"error\"
}

Switching camera to archive mode

GET http://IPaddress:8888/GotoArchive
ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.

timestampYes

Time in ISO format.

Sample request:

GET http://127.0.0.1:8888/GotoArchive?displayId=\\.\DISPLAY2&cameraName=hosts/SERVER1/DeviceIpint.1/SourceEndpoint.video:0:0&timestamp=2017-04-07T00:00:00.000

Note

Use the following query to get the list of groups:

GET http://IPaddress:8888/GetGroups.

Sample responce:

 Id	"4308f2e2-e57c-4cd0-8a4f-826e8b16d39c"
   Name	"Default"

Switching to layout with camera in forensic search mode

GET http://IP-address:8888/SearchArchive
ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.

timestampYes

Time in ISO format.

Sample request:

GET http://127.0.0.1:8888/GoToArchive?displayId=\\.\DISPLAY2&cameraName=hosts/SERVER1/DeviceIpint.1/SourceEndpoint.video:0:0×tamp=2017-04-07T00:00:00.000

Switching to saved forensic search results

GET http://IP-address:8888/SearchArchive

ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.

query

Yes

Name of the saved search query (see Saving search queries).

Sample request:

GET http://127.0.0.1:8888/SearchArchive?displayId=\\.\DISPLAY1&cameraName=host/HOSTNAME/DeviceIpint1/SourceEndPoint.video:0:0&query=query1

Switching to layout with camera in immersion mode

GET http://IP-address:8888/GotoImmersion
ParametrRequiredDescription
displayIdYesMonitor id (see Getting the list of displays).
cameraNameYes

Camera name from the response to Getting the list of cameras displayed on the layout request.

Sample request:

GET http://127.0.0.1:8888/GotoImmersion?displayId=\\.\DISPLAY1&cameraName=hosts/SERVER1/DeviceIpint.1/SourceEndpoint.video:0:0

Content

  • No labels