create_zone_by_track

The create_zone_by_track function is used to create geofences from tracks.

Copied!
svc=resource/create_zone_by_track&params={"layerName":"<text>",
				 						  "itemId":<uint>,
				 						  "unitId":<uint>,
				 						  "n":"<text>",
				 						  "c":<int>,
				 						  "w":<int>
										 }

Parameters

Name Description
layerName Track layer name.
itemId Resource ID.
unitId Unit ID.
n Geofence name.
c Colour (ARGB). Optional. The default value is 0x009933.
w Line thickness. Optional. The default value is 100.

Returned result

Copied!
{
	"all_zones":<uint>, 	/* the number of new geofences (the maximum number of points in one geofence is 10000) */
	"created_zone":<uint>	/* the number of created geofences */
}

Possible error codes:

Code Description
7 Failed to fetch the resource with the desired ACL (ADF_ACL_AVL_RES_EDIT_ZONES).
6 Failed to fetch the renderer or no geofences created.
4 Failed to get messages or wrong input parameters.

If you find a mistake in the text, please select it and press Ctrl+Enter.