POST /async_matrix/create_task/get_dist_matrix
OpenAPI Specification
2GIS Navigation API (6.0.0)
Creating a task to get information about travel distance and time between points
Creating a task to get information about travel distance and time between points
query Parameters
key required | string Developer API key |
version required | string Default: "2.0" API version |
response_format | string Default: "json" Enum: "protobuf" "json" Response format:
|
Request Body schema: */*
Request parameters
required | Array of objects (RequestPoint) non-empty An array of points. |
sources required | Array of integers non-empty Which points from the |
targets required | Array of integers non-empty Which points from the |
string or null Date and time to use instead of the current date and time. Specified in RFC 3339 format (e.g., 2020-05-15T15:52:01Z). | |
transport | string Default: "driving" Enum: "driving" "truck" Routing type:
|
type | string Default: "jam" Enum: "jam" "statistics" "shortest" Route type:
|
Array of RequestFilter (strings) or RequestFilter (string) or null | |
boolean or null If true, the route may include driving on closed roads. | |
Array of objects (ExcludeObject) An array of areas to avoid when building a route. Not more than 25 areas. | |
TruckParams (object) or null | |
number or null Average speed limit, km/h | |
pass_zone_pass_ids | Array of integers Default: [] Identifier of a pass for a zone (array of numbers). |
Responses
Response Schema: application/json
string or null Task ID | |
string or null Additional information about the task status | |
integer or null Status code | |
TaskStatus (string) or null | |
string or null Link to the solution file |
Response Schema: application/json
string or null Error description |
Response Schema: application/json
Array of DMAsyncValidationError (objects) or null Error description |
Response samples
- 200
- 400
- 422
{- "task_id": "string",
- "message": "string",
- "code": 0,
- "status": "TASK_CREATED",
- "result_link": "string"
}