# Compute a matrix Calculate a matrix of travel times and/or distances between N origins and M destinations. This includes the common cases of routes from one origin to many destinations, or from many origins to one destination. Endpoint: POST /matrix Version: 1.0.0 Security: api_key ## Response 200 fields (application/json): - `distances` (array) The distance matrix for the specified points in the same order as the time matrix. The distances are in meters. If the matrix will contain for connections that could not be found. Example: [[0,97653,48887],[97426,0,121035],[49006,121049,0]] - `times` (array) The time matrix for the specified points in the order [[from1->to1, from1->to2, ...], [from2->to1, from2->to2, ...], ...]. The times are in seconds. If the matrix will contain for connections that could not be found. Example: [[0,4197,2994],[4192,0,6074],[3006,6062,0]] - `weights` (array) The weight matrix for the specified points in the same order as the time matrix. The weights for different vehicle profiles can have a different unit but the weights array is perfectly suited as input for Vehicle Routing Problems as it is currently faster to calculate. If the matrix will contain for connections that could not be found. Example: [[0,5662.551,3727.147],[5653.807,0,7889.653],[3741.528,7878.365,0]] - `info` (object) Additional information for your request Example: {"copyrights":["GraphHopper","OpenStreetMap contributors"]} - `info.copyrights` (array) Attribution according to our documentation is necessary if no white-label option included. Example: ["GraphHopper","OpenStreetMap contributors"] - `info.took` (number) - `hints` (array) Optional. Additional response data. - `hints.message` (string) Short description of this hint - `hints.details` (string) Details of this hint - `hints.invalid_from_points` (array) Optional. An array of from_point indices of points that could not be found. Will only be added if and some s were not found.` - `hints.invalid_to_points` (array) Optional. An array of to_point indices of points that could not be found. Will only be added if and some s were not found.` - `hints.point_pairs` (array) Optional. An array of two-element arrays representing the from/to_point indices of points for which no connection could be found. Will only be added if and some connections were not found.