Skip to main content
POST
Get Matrix

Request contract

  • Method and path: POST /apis/v1/graphhopper/get-matrix
  • Availability: enabled
  • Request URL template: https://api.aisa.one/apis/v1/graphhopper/get-matrix
Complete OpenAPI definition Effective request declaration (including authentication and referenced schemas):

Cost and request rules

Usage-based pricing. Default request estimate: $0.0803 USD. The final charge depends on actual usage. Your account price may differ; use a request quote where supported.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
point
string[]
required

Specify multiple points in 'latitude,longitude' format for which the matrix should be calculated. The starts are identical to the destinations. If there are N points, then NxN entries will be calculated. Specify at least three points. Cannot be used together with from_point or to_point.

Required array length: 1 - 20 elements
profile
enum<string>
required

The routing profile. It determines the network, speed and other physical attributes used when computing the route. Valid values include 'car', 'bike', 'foot', 'hike', 'mtb', 'racingbike', 'scooter', 'truck', and 'small_truck'.

Available options:
car
curbside
enum<string>[]

Optional parameter. Specifies on which side a point should be relative to the driver when she leaves/arrives at a start/target/via point. Must be 'any', 'left', or 'right'. Specify for either none or all points.

Available options:
any,
left,
right
fail_fast
boolean
default:true

Specifies whether or not the matrix calculation should return with an error as soon as possible in case some points cannot be found or some points are not connected. If set to false, the matrix will be calculated for all valid points and contain null values for entries that could not be calculated.

from_curbside
enum<string>[]

Curbside setting for the from_point parameter. Must be 'any', 'left', or 'right'.

Available options:
any,
left,
right
from_point
string[]

The origin points for the routes in 'latitude,longitude' format. Use together with to_point for asymmetric matrices.

Example:
from_point_hint
string[]

For the from_point parameter. Specifies a hint to prefer a certain street for the closest location lookup.

out_array
enum<string>[]

Specifies which arrays should be included in the response. Specify one or more of 'weights', 'times', 'distances'. The units of distances are meters, times are seconds, and weights are arbitrary.

Available options:
weights,
times,
distances
Example:
point_hint
string[]

Optional parameter. Specifies a hint for each point parameter to prefer a certain street for the closest location lookup.

snap_prevention
enum<string>[]

Optional parameter to prevent snapping to specific types of roads. Supported values: 'motorway', 'trunk', 'ferry', 'tunnel', 'bridge', 'ford'.

Available options:
motorway,
trunk,
ferry,
tunnel,
bridge,
ford
to_curbside
enum<string>[]

Curbside setting for the to_point parameter. Must be 'any', 'left', or 'right'.

Available options:
any,
left,
right
to_point
string[]

The destination points for the routes in 'latitude,longitude' format. Use together with from_point for asymmetric matrices.

Example:
to_point_hint
string[]

For the to_point parameter. Specifies a hint to prefer a certain street for the closest location lookup.

Response

Tool result data

info
object
required
distances
((number | null)[])[]
hints
object[]
times
((number | null)[])[]
weights
((number | null)[])[]