Go to documentation repository
To get the identifier of the detector mask, it is necessary to run a query of the following type:
{
"method":"axxonsoft.bl.config.ConfigurationService.ListUnits",
"data":{
"unit_uids": ["hosts/Server1/AppDataDetector.1"]
}
}
where unit_uids is the name of the required detector (see Manage devices using gRPC API methods (ConfigurationService)).
Find the units parameter group in the query response:
"units": [
{
"uid": "hosts/Server1/AppDataDetector.1/VisualElement.76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
"display_id": "76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
"type": "VisualElement",
"display_name": "Polyline",
"access_point": "",
"properties": [
{
"id": "polyline",
"name": "Polyline",
"description": "Polyline.",
"type": "SimplePolygon",
"readonly": false,
"internal": false,
"value_simple_polygon": {
"points": [
{
"x": 0.01,
"y": 0.01
},
{
"x": 0.01,
"y": 0.99
},
{
"x": 0.99,
"y": 0.99
},
{
"x": 0.99,
"y": 0.01
}
]
}
}
where
- uid is a mask identifier.
- x, y are coordinates of the point apex.
To change the points of the mask, it is necessary to run a query using the obtained mask uid:
{
"method": "axxonsoft.bl.config.ConfigurationService.ChangeConfig",
"data": {
"changed": [
{
"uid": "hosts/Server1/AppDataDetector.1/VisualElement.76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
"type": "VisualElement",
"properties": [
{
"id": "polyline",
"value_simple_polygon": {
"points": [
{
"x": 0.01,
"y": 0.01
},
{
"x": 0.01,
"y": 0.99
},
{
"x": 0.99,
"y": 0.99
},
{
"x": 0.99,
"y": 0.01
}
]
}
}
]
}
]
}
You can also add and remove the polygon points of the mask using this query.
Overview
Content Tools