Найдите нужную информацию в разделе частых вопросов, документации или обратитесь к нашему AI-помощнику для получения поддержки
Methods in this section are related to the Forguard solution.
The specificity of Forguard accounts lies in assigning a client plan upon creation, wherein service providers (dealers) determine the available account limits and control specific application features/modules when creating a client plan.
The client plan, in turn, is built upon partner plans offered by the GPS-Trace platform.
Client plans consist of two sections:
Quotas include limits on unit quantity per account, geofence quantity, and maximum data storage limit.
"quotas": {
"unit": number,
"geofence": number,
"unit_storage": number
}
Modules are specific features or functionalities within the Forguard application that partners can choose to enable or disable in a client plan for a client account at their discretion.
Currently, the following modules are available:
Providers uses a partner plan to create a client plan, adjusting the limits based on the partner plan.
For instance, if a partner plan has a 10 units limit per account, the service provider can set a lower value but not exceed 10 units in the client plan.
Scheme for creating a Forguard account:
This API endpoint allows for the creation of a client plan, which is used in the process of creating Forguard accounts.
POST /provider/client-plans
The mandatory field for this request:
Request body example:
curl -X 'POST' \
'https://api.gps-trace.com/provider/client-plans \
-H 'accept: application/json' \
-H 'X-AccessToken: <your token>' \
-H 'Content-Type: application/json' \
-d '{"name": "Client Plan",
"description": "Client plan description",
"quotas": {
"unit": 30,
"geofence": 50,
"unit_storage": 204800},
"modules": [
"command",
"google_maps",
"geofence",
"statistics",
"tools",
"extended_notification",
"unit_event",
"sharing",
"timeline",
"notification",
"maintenance",
"service_mode"
],
"managed_plan_id": "string",
"app_id": "b901da51-ce00-4af2-b978-8d0fca8ae1ea"
}'
Modules 'account', 'unit', and 'fuel' are always enabled by default in Forguard accounts. They can only be seen in the response to the request.
201 Response example:
{
"quotas": {
"unit": 30,
"geofence": 50,
"unit_storage": 204800
},
"creator_id": number,
"app_id": "b901da51-ce00-4af2-b978-8d0fca8ae1ea",
"updated_at": number,
"description": "Client plan description",
"managed_plan_id": "string",
"modules": [
"notification",
"command",
"account",
"geofence",
"service_mode",
"sharing",
"unit_event",
"timeline",
"statistics",
"extended_notification",
"maintenance",
"tools",
"unit",
"google_maps"
],
"name": "Client Plan",
"created_at": number,
"id": "string"
}
This API endpoint allows you to obtain a list of created client plans.
GET /provider/client-plans
200 Response example:
[
{
"id": "string",
"quotas": {
"unit": 20,
"geofence": 0,
"unit_storage": 10240
},
"name": "Test",
"creator_id": number,
"app_id": "b901da51-ce00-4af2-b978-8d0fca8ae1ea",
"managed_plan_id": "string",
"updated_at": number,
"description": null,
"created_at": number,
"modules": [
"service_mode",
"account",
"unit"
]
},
{
"id": "string",
"quotas": {
"unit": 10,
"unit_storage": 102400,
"geofence": 50
},
"name": "Test2",
"creator_id": number,
"app_id": "b901da51-ce00-4af2-b978-8d0fca8ae1ea",
"managed_plan_id": "string",
"updated_at": number,
"description": null,
"created_at": number,
"modules": [
"tools",
"unit_event",
"command",
"google_maps",
"statistics",
"unit",
"maintenance",
"service_mode",
"notification",
"account",
"extended_notification"
"sharing",
"timeline",
"fuel",
"geofence"
]
}
The response includes information about client plans available, with each plan represented by an object containing the following fields:
This API endpoint allows you to get information about a specific client plan by its ID
GET /provider/client-plans/{id}
200 Response example:
{
"id": "string",
"quotas": {
"unit": 20,
"geofence": 0,
"unit_storage": 10240
},
"name": "Test",
"creator_id": number,
"app_id": "b901da51-ce00-4af2-b978-8d0fca8ae1ea",
"managed_plan_id": "string",
"updated_at": number,
"description": null,
"created_at": number,
"modules": [
"service_mode",
"account",
"unit"
]
}
This API endpoint allows you to delete client plan by its ID
DELETE /provider/client-plans/{id}
Upon successful deletion, a response with status code 200 will be returned, along with the ID of the client plan that was removed.
200 Response example:
"string"
This endpoint allows to retrieve information about the modules used in creating client plans.
GET /provider/client-plans/modules
Creating Forguard account requires assigning a client plan to it.
Client plans are made based on partner plans provided by the GPS-Trace platform.
Partner plans consist of two main parts:
Example of limits:
"limits": {
"geofence": {
"default": 35,
"max": 70,
"min": 0,
"step": 1
},
"unit": {
"default": 35,
"max": 70,
"min": 1,
"step": 1
},
"unit_storage": {
"default": 102400,
"max": 204800,
"min": 10240,
"step": 10240
}
}
Currently, the following modules are available:
Client plans based on partner plans and include specific quotas and modules.
Quotas for geofences, units, and data storage volume are set during client plan creation, within the limits of the partner plan. Providers can activate or deactivate modules available in the partner plan.
For instance, a service provider might select a partner plan allowing 70 units, create a client plan based on it, set a 50-unit limit, and apply this plan to a Forguard account for the client to track up to 50 units.
Modules 'account', 'unit', and 'fuel' are always enabled by default in Forguard accounts. They can only be seen in the response to the request.
200 Response example:
[
{
"default_included": false,
"name": "tools",
"hidden": false,
"required": false,
"depended_on": [],
"default_access": 15,
"access_list": [ 15 ]
},
{
"default_included": false,
"name": "service_mode",
"hidden": false,
"required": false,
"depended_on": [],
"default_access": 15,
"access_list": [ 15 ]
},
...