{"id":2696,"date":"2023-12-20T18:51:31","date_gmt":"2023-12-20T18:51:31","guid":{"rendered":"https:\/\/developers.maplink.global\/list-of-parameters-3\/"},"modified":"2026-11-16T18:37:58","modified_gmt":"2026-11-16T18:37:58","slug":"list-of-parameters-matrix","status":"publish","type":"post","link":"https:\/\/developers.maplink.global\/en\/list-of-parameters-matrix\/","title":{"rendered":"List of parameters"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\"><strong>Mandatory parameters<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>calculationMode<\/code>  &#8211; Indicates the calculation mode for the route. Supports types:\n<ul class=\"wp-block-list\">\n<li><code>THE_FASTEST<\/code>  &#8211; Consider it the fastest way.<\/li>\n\n\n\n<li><code>THE_SHORTEST<\/code>  &#8211; Consider the route with the lowest mileage.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><code>destinations<\/code>  &#8211; Description of destination points with:\n<ul class=\"wp-block-list\">\n<li><code>siteId<\/code>  &#8211; Stop point identifier.<\/li>\n\n\n\n<li><code>latitude<\/code>  &#8211; Latitude coordinate in decimal degrees.<\/li>\n\n\n\n<li><code>longitude<\/code>  &#8211; Longitude coordinate in decimal degrees.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><code>origins<\/code>  &#8211; Description of points of origin with:\n<ul class=\"wp-block-list\">\n<li><code>siteId<\/code>  &#8211; Stop point identifier.<\/li>\n\n\n\n<li><code>latitude<\/code>  &#8211; Latitude coordinate in decimal degrees.<\/li>\n\n\n\n<li><code>longitude<\/code>  &#8211; Longitude coordinate in decimal degrees.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong><em>Example with mandatory parameters<\/em><\/strong><\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"json\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">{\n    \"calculationMode\": \"THE_FASTEST\",\n    \"destinations\": [\n        {\n            \"latitude\": -23.561402303338195, \n            \"longitude\": -46.63862145421187,\n            \"siteId\": \"destination1Liberdade\"\n        }\n    ],\n    \"origins\": [\n        {\n            \"latitude\": -23.55363650451996,\n            \"longitude\": -46.620810158377516,\n            \"siteId\": \"origin1Mooca\"\n        }\n    ]\n}<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Optional parameters<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li><code>linearThreshold<\/code>\u00a0\u2013 Numeric value. Maximum distance, in kilometers, for taking roads into account in the distance matrix calculation. First, all distances are calculated in a straight line. Then, those below this limit are recalculated along roads. This prevents points that are very far apart from increasing processing time. The default value is <code>1000<\/code> (1,000 km).<\/li>\n\n\n\n<li><code>avoidanceTypes<\/code> &#8211; Indicates that the route will have to deviate from certain types of road system elements. Allowed values are:\n<ul class=\"wp-block-list\">\n<li><code>TUNNELS<\/code> \u2013 The route will bypass tunnels;<\/li>\n\n\n\n<li><code>BRIDGES<\/code> \u2013 The route will bypass bridges;<\/li>\n\n\n\n<li><code>CITY<\/code> \u2013 The route will bypass urban areas;<\/li>\n\n\n\n<li><code>UNPAVED<\/code> \u2013 The route will bypass unpaved roads;<\/li>\n\n\n\n<li><code>FERRIES<\/code> \u2013 The route will bypass ferries.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><code>callback<\/code> &#8211; Object that contains the webhook data that will be used to receive the problem calculation events. This way, it will not be necessary to check the status of the problem to check if it has been processed. The API will notify the&nbsp;webhook&nbsp;when the solution is available for query. For more details, see:&nbsp;<a href=\"https:\/\/developers.maplink.global\/en\/how-to-receive-the-current-status-of-the-problem-via-webhook\/\">How to receive the current status of the problem via webhook?<\/a>\n<ul class=\"wp-block-list\">\n<li><code>url<\/code>  &#8211; URL with the address that will receive the <em>callback<\/em>.<\/li>\n\n\n\n<li><code>user<\/code>  &#8211; (Optional) Text with the user name if the endpoint requires authentication<em>.<\/em><\/li>\n\n\n\n<li><code>password<\/code>  &#8211; (Optional) Password text if the endpoint requires authentication.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><code>restrictionZones<\/code>  &#8211; Array with the text of the name of the restriction area previously registered in the <a href=\"https:\/\/developers.maplink.global\/en\/building-requests-for-the-restriction-zone-api\/\" data-type=\"post\" data-id=\"1321\">Restriction Zone API<\/a>.<\/li>\n<\/ul>\n\n\n\n<h3 class=\"wp-block-heading\"><strong><em>Example with optional parameters<\/em><\/strong><\/h3>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"json\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">{\n    \"avoidanceTypes\": [\n        \"TUNNELS\",\n        \"BRIDGES\",\n        \"FERRIES\"\n    ],\n    \"calculationMode\": \"THE_FASTEST\",\n    \"destinations\": [\n        {\n            \"latitude\": -23.682211,\n            \"longitude\": -46.546867,\n            \"siteId\": \"SantoAndre\"\n        }\n    ],\n    \"origins\": [\n        {\n            \"latitude\": -23.337132,\n            \"longitude\": -46.835427,\n            \"siteId\": \"Cajamar\"\n        }\n    ],\n    \"linearThreshold\": 500,\n    \"restrictionZones\": []\n}<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Mandatory parameters Example with mandatory parameters Optional parameters Example with optional parameters<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[165],"tags":[],"class_list":["post-2696","post","type-post","status-publish","format-standard","hentry","category-distance-matrix-en"],"acf":[],"_links":{"self":[{"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/posts\/2696","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/comments?post=2696"}],"version-history":[{"count":6,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/posts\/2696\/revisions"}],"predecessor-version":[{"id":4480,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/posts\/2696\/revisions\/4480"}],"wp:attachment":[{"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/media?parent=2696"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/categories?post=2696"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/developers.maplink.global\/en\/wp-json\/wp\/v2\/tags?post=2696"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}