{"openapi":"3.1.0","info":{"title":"Routing APIs","description":"Precisely Data Integrity Suite offers different routing services that can be used for routing operations.\nThese services include capabilities to determine drive or walk time or distance boundaries from a location\nand also provide routing information for a set of two distinct points or multiple points.\n\n<details>\n    <summary>Error Codes</summary>\n\nAPIs will return the following error codes in case of any error:\n\n| Error Code                 | Description\n|----------------------------|-------------------------------------------------------\n|DIS-1001                   |Invalid token.\n|DIS-1002                   |Not Authorized to access this API.\n|DIS-1003                   |Issue with internal services.\n|DIS-1004                   |Workspace Id is missing from Bearer Token.\n|DIS-1005                   |Rate limit exceeded.\n|DIS-1008                   |Invalid request ID, maximum allowed length is 38 characters.\n</details>\n","version":"1.0"},"servers":[{"url":"https://api.cloud.precisely.com"}],"security":[{"bearerAuth":[]}],"paths":{"/v1/matrix/location":{"get":{"tags":["Travel Matrix Api"],"description":"The Travel Matrix Flexible API provides ETAs and distances using truck-specific routes, departure times, traffic, and route preferences by setting the option parameter to flexible. It supports both HTTPS GET and POST, with POST allowing larger origin-destination sets.","operationId":"getNBMatrixRequest","parameters":[{"name":"X-Request-Id","in":"header","description":"The X-Request-Id header is optional but incredibly useful for developers. It serves as a unique identifier for requests within our system. When you encounter any problems with your requests, providing us with the X-Request-Id will enable us to pinpoint the specific request in question without the need for extensive manual searching. This means faster and more efficient troubleshooting.","schema":{"type":"string"}},{"name":"coordOrder","in":"query","description":"Specifies the order of coordinates in the request. Use 'LonLat' when providing coordinates in Longitude,Latitude order (X,Y). If not specified or set to 'LatLon', coordinates are expected in Latitude,Longitude order. This parameter applies to 'origins' and 'destinations' parameters. Default: LatLon. Example: LatLon","schema":{"type":"string","enum":["LatLon","LonLat"]}},{"name":"origins","in":"query","description":"origins are the starting point of your route. Ensure that origins are routable land locations. Multiple origins should be separated by a comma symbol (,).","required":true,"schema":{"type":"string"},"example":"41.349302,2.136480,41.389925,2.136258,41.357961,2.097878"},{"name":"destinations","in":"query","description":"destinations are the ending coordinates of your route. Ensure that destinations are routable land locations. Multiple destinations should be separated by a comma symbol (,).","required":true,"schema":{"type":"string"},"example":"41.349302,2.136480,41.389925,2.136258,41.357961,2.097878"},{"name":"mode","in":"query","description":"Set which driving mode the service should use to determine a route; for example, using car returns a route suitable for cars, while truck returns a truck-appropriate route considering routing restrictions, with default truck dimensions of height 214 cm, width 183 cm, length 519 cm, and weight 5000 kg—custom dimensions can be set using truck_weight and truck_size parameters, but note that only the car profile is enabled by default and custom profiles like truck may not be available in all regions.","schema":{"type":"string","enum":["car","truck"]},"example":"car"},{"name":"avoid","in":"query","description":"Set this parameter to avoid specific route objects using a comma (,) separator for multiple values; this acts as a flexible filter (effective only with route_type=fastest) and still returns a route if no alternatives exist—except for bbox, tunnel, and geofence_id, which enforce strict avoidance and return a 4xx error if no route is found; for bbox, boundaries must be defined in the format bbox:min_lat,min_lng,max_lat,max_lng, supporting multiple boxes (max perimeter 500 km), and for sharp_turn, the default permissible angle range is [120,240] clockwise (customizable via turn_angle_range); when using geofence_id; ferry routes are avoided by default unless this parameter is explicitly set, and specifying none with other values causes an error as no valid route can be generated.","schema":{"type":"string","enum":["toll","highway","ferry","sharp_turn","uturn","service_road","left_turn","right_turn","bbox","geofence_id","tunnel","none"]},"example":"ferry"},{"name":"exclude","in":"query","description":"This parameter is a strict filter that ensures routes exclude the specified object(s), separated by a comma (`,`); effective only when `route_type=fastest`, it returns a 4xx error if no valid route exists, with default `sharp_turn` angles in [120,240] (override via `turn_angle_range`), and using `none` with other values results in an error.","schema":{"type":"string","enum":["toll","ferry","highway","service_road","uturn","sharp_turn","left_turn","right_turn","none"]},"example":"none"},{"name":"approaches","in":"query","description":"A semicolon-separated list specifying the side of the road to approach each waypoint; use `unrestricted` to approach from either side, `curb` to approach from the driving side, with the number of values being one more than the waypoints—skipped values can be left blank using `;`.","schema":{"type":"string","enum":["unrestricted","curb"]},"example":"unrestricted;unrestricted;unrestricted"},{"name":"departure_time","in":"query","description":"Use this parameter to set a departure time, expressed as UNIX epoch timestamp in seconds, for calculating the isochrone contour. The response will consider the typical traffic conditions at the given time and return a contour which can be reached under those traffic conditions. Please note that if no input is provided for this parameter then the traffic conditions at the time of making the request are considered.","schema":{"type":"integer"},"example":1563254734},{"name":"local_departure_time","in":"query","description":"Use this parameter to specify departure time in local time format (day name and time). Format: 'DayName HH:mm'. The API will automatically convert this to the appropriate UTC timestamp based on the timezone of the first origin location. Cannot be used together with departure_time parameter.  Examples: Monday 08:00","schema":{"type":"string"}},{"name":"truck_size","in":"query","description":"This defines the dimensions of a truck in centimeters (cm). This parameter is effective only when the mode=truck. Maximum dimensions are as follows: Height = 1000 cm ,Width = 5000 cm ,Length = 5000 cm.Format: height,width,length","schema":{"type":"string"}},{"name":"truck_weight","in":"query","description":"This parameter defines the weight of the truck including trailers and shipped goods in kilograms (kg). This parameter is effective only when mode=truck. Minimum: 1 ,Maximum: 100000","schema":{"type":"integer"},"example":11770},{"name":"route_type","in":"query","description":"Set the route type that needs to be returned.","schema":{"type":"string","enum":["fastest","shortest"]},"example":"fastest"},{"name":"cross_border","in":"query","description":"Specify if crossing an international border is expected for operations near border areas. When set to false, the API will prohibit routes crossing the borders. When set to true, the service will return routes which cross the borders between countries, if required for the given set destination and waypoints.This feature is available in North America region only. Please get in touch with support@nextbillion.ai to enquire/enable other areas.","schema":{"type":"boolean"},"example":false},{"name":"truck_axle_load","in":"query","description":"Specify the total load per axle (including the weight of trailers and shipped goods) of the truck, in tonnes. When used, the service will return routes which are legally allowed to carry the load specified per axle. Please note this parameter is effective only when `mode=truck`.","schema":{"type":"number"}},{"name":"hazmat_type","in":"query","description":"Specify the type of hazardous material being carried and the service will avoid roads which are not suitable for the type of goods specified. Multiple values can be separated using a comma operator ',' .Please note that this parameter is effective only when mode=truck.","schema":{"type":"string","enum":["explosives","gas","flammable_liquid","flammable_gas","organic","toxic","radioactive","corrosive","other"]}},{"name":"turn_angle_range","in":"query","description":"Specify the turn angles that can be taken safely by the vehicle. The permissible turn angles are calculated as [0 + turn_angle_range , 360 - turn_angle_range]. Please note that this parameter is effective only when avoid = sharp_turn. It is worth highlighting here that providing smaller angles might lead to 4xx errors as route engine might not be able find routes satisfying the smaller turn angle criteria for all turns in the route.","schema":{"type":"integer"}},{"name":"route_failed_prompt","in":"query","description":"A prompt to modify the response in case no feasible route is available for a given pair of origin and destination. When set to true a value of -1 is returned for those pairs in which either origin or the destination can not be snapped to a nearest road. Please note that if all the origins and destinations in a request can't be snapped to their nearest roads, a 4xx error is returned instead, as the entire request failed both origin and destination can be snapped to the nearest road but the service can't find a valid route between them.However, a value of \"0\" is returned if both the origin and destination are snapped to the same location.false is the default value. In this case, a 0 value is returned for all the above cases. A 4xx error is returned, in this case as well, when all origins and destinations in the request can't be snapped to their nearest road.","schema":{"type":"boolean"},"example":false},{"name":"bearings","in":"query","description":"Limits the search to road segments with given bearing, in degrees, towards true north in clockwise direction. Each bearings should be in the format of degree,range, where the degree should be a value between [0, 360] and range should be a value between [0, 180].Please note that the number of bearings should be two more than the number of waypoints. This is to account for the bearing of origin and destination. If a route can approach a waypoint or the destination from any direction, the bearing for that point can be specified as 0,180. Format: degree0,range0;degree1,range1;...","schema":{"type":"string"}},{"name":"emission_class","in":"query","description":"Specify the emission class to which the vehicle (engine) belongs to. The service will use this setting to generate routes that are permissible for that engine class. Only the emission classifications in the EU regions are supported currently.","schema":{"type":"string","enum":["euro0","euro1","euro2","euro3","euro4","euro5","euro6","euro7","euro8","euro9"]}},{"name":"option","in":"query","description":"Use this option to switch to time based routing or if you want to choose between the fastest and shortest route types.","required":true,"schema":{"type":"string","enum":["flexible"]},"example":"flexible"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlexibleMatrixResponseModel"},"example":{"status":"Ok","rows":[{"elements":[{"duration":{"value":0},"distance":{"value":0}},{"duration":{"value":1063},"distance":{"value":6344}},{"duration":{"value":599},"distance":{"value":7839}}]},{"elements":[{"duration":{"value":987},"distance":{"value":6239}},{"duration":{"value":0},"distance":{"value":0}},{"duration":{"value":1048},"distance":{"value":8529}}]},{"elements":[{"duration":{"value":686},"distance":{"value":7633}},{"duration":{"value":986},"distance":{"value":7378}},{"duration":{"value":93},"distance":{"value":334}}]}]}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"1c986743-f958-4d6d-8923-f5219c69fa95","errors":[{"code":"DIS-RT-403","detail":"The 'mode' provided in the input, ca, is invalid with option=flexible. Valid values for 'mode' are car, motorcycle, bike, truck, walk for flexible routing (setting option=flexible)."}]}}}},"401":{"description":"Unauthorized: Invalid token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1001","detail":"Unauthorized"}]}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1002","detail":"Not Authorized to access this API"}]}}}},"429":{"description":"Too many requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1004","detail":"Too many requests"}]}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}}},"security":[{"bearerAuth":[]},{"ApiKeyAuth":[]}]},"post":{"tags":["Travel Matrix Api"],"description":"The Travel Matrix Flexible API provides ETAs and distances using truck-specific routes, departure times, traffic, and route preferences by setting the option parameter to flexible. It supports both HTTPS GET and POST, with POST allowing larger origin-destination sets.","operationId":"postNBMatrixRequest","parameters":[{"name":"X-Request-Id","in":"header","description":"The X-Request-Id header is optional but incredibly useful for developers. It serves as a unique identifier for requests within our system. When you encounter any problems with your requests, providing us with the X-Request-Id will enable us to pinpoint the specific request in question without the need for extensive manual searching. This means faster and more efficient troubleshooting.","schema":{"type":"string"}},{"name":"option","in":"query","description":"Use this option to switch time based routing or if you want to choose between the fastest and shortest route types.","required":true,"schema":{"type":"string","enum":["flexible"]},"example":"flexible"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object"},"examples":{"Coordinates based example":{"description":"post request example for Matrix api","value":{"coordOrder":"LatLon","origins":"41.349302,2.136480|41.389925,2.136258|41.357961,2.097878","destinations":"41.349302,2.136480|41.389925,2.136258|41.357961,2.09787","mode":"car","avoid":"ferry","exclude":"none","approaches":"unrestricted;unrestricted;unrestricted","departure_time":1563254734,"route_type":"fastest","cross_border":false,"route_failed_prompt":false}},"post request address based example":{"description":"post request address based example","value":{"originAddresses":[{"address":"6 Wall Street","country":"USA"},{"address":"10 Goldmine Avenue, Mass","country":"USA"}],"destinationAddresses":[{"address":"1 Wall Street","country":"USA"},{"address":"2 Wall Street","country":"USA"}],"mode":"car","geometry":"geojson","alternatives":true,"altcount":3,"avoid":"ferry","exclude":"none","departure_time":1563254734,"route_type":"fastest","road_info":"max_speed","cross_border":false,"drive_time_limits":"500, 400, 400","rest_times":"500, 300, 100"}}}}},"required":true},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlexibleMatrixResponseModel"},"examples":{"example":{"description":"successful response for Matrix api","value":{"status":"Ok","rows":[{"elements":[{"duration":{"value":0},"distance":{"value":0}},{"duration":{"value":1063},"distance":{"value":6344}},{"duration":{"value":599},"distance":{"value":7839}}]},{"elements":[{"duration":{"value":987},"distance":{"value":6239}},{"duration":{"value":0},"distance":{"value":0}},{"duration":{"value":1048},"distance":{"value":8529}}]},{"elements":[{"duration":{"value":686},"distance":{"value":7633}},{"duration":{"value":986},"distance":{"value":7378}},{"duration":{"value":93},"distance":{"value":334}}]}]}}}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"1c986743-f958-4d6d-8923-f5219c69fa95","errors":[{"code":"DIS-RT-403","detail":"The 'mode' provided in the input, ca, is invalid with option=flexible. Valid values for 'mode' are car, motorcycle, bike, truck, walk for flexible routing (setting option=flexible)."}]}}}},"401":{"description":"Unauthorized: Invalid token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1001","detail":"Unauthorized"}]}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1002","detail":"Not Authorized to access this API"}]}}}},"429":{"description":"Too many requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1004","detail":"Too many requests"}]}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}}},"security":[{"bearerAuth":[]},{"ApiKeyAuth":[]}]}},"/v1/isochrone/batch":{"post":{"tags":["regional-route-controller"],"operationId":"processIsochroneBatch","parameters":[{"name":"Authorization","in":"header","required":false,"schema":{"type":"string"}},{"name":"X-Request-Id","in":"header","required":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IsochroneRequest"}}},"required":true},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BatchIsoResponseModel"}}}}}}}},"/v1/direction/location":{"get":{"tags":["Route Api"],"description":"The Route Flexible API provides customizable routing with features like truck routing, time-based paths, and traffic-aware routes. It supports both GET and POST methods, with differences in waypoint limits.","operationId":"getNBDirectionRequest","parameters":[{"name":"X-Request-Id","in":"header","description":"The X-Request-Id header is optional but incredibly useful for developers. It serves as a unique identifier for requests within our system. When you encounter any problems with your requests, providing us with the X-Request-Id will enable us to pinpoint the specific request in question without the need for extensive manual searching. This means faster and more efficient troubleshooting.","schema":{"type":"string"}},{"name":"coordOrder","in":"query","description":"Specifies the order of coordinates in the request. Use 'LonLat' when providing coordinates in Longitude,Latitude order (X,Y). If not specified or set to 'LatLon', coordinates are expected in Latitude,Longitude order. This parameter applies to 'origin', 'destination', and 'waypoints' parameters. Default: LatLon. Example: LatLon","schema":{"type":"string","enum":["LatLon","LonLat"]}},{"name":"originAddress","in":"query","description":"The origin address of the location from where you want to start your route. Example: POINT REYES STATION CA","schema":{"type":"string"}},{"name":"originCountry","in":"query","description":"Origin country name used only when the starting location is provided as originAddress. Example: USA","schema":{"type":"string"}},{"name":"destinationAddress","in":"query","description":"The destination address of the location to where you want to end your route. Example: Lagunitas CA","schema":{"type":"string"}},{"name":"destinationCountry","in":"query","description":"Destination Country name used only when the destination location is provided as destinationAddress. Example: USA","schema":{"type":"string"}},{"name":"origin","in":"query","description":"origin is the starting point of your route. Ensure that the origin is a routable land location.","schema":{"type":"string"},"example":"48.87862672840649, 2.2724349629292195"},{"name":"destination","in":"query","description":"destination is the ending coordinates of your route. Ensure that the destination is a routable land location..","schema":{"type":"string"},"example":"48.73000636636801, 2.3044168556664175"},{"name":"waypoints","in":"query","description":"waypoints are coordinates along the route between the origin and destination. It is a comma-separated list of coordinate pairs. Please note that the route returned will arrive at the waypoints in the sequence they are provided in the input request. The maximum number of `waypoints` that can be added in a single request is 50.","schema":{"type":"string"},"example":"48.43000636636801, 2.2044168556664175,48.93000636636801, 2.1044168556664175"},{"name":"mode","in":"query","description":"Set which driving mode the service should use to determine a route; for example, using car returns a route suitable for cars, while truck returns a truck-appropriate route considering routing restrictions, with default truck dimensions of height 214 cm, width 183 cm, length 519 cm, and weight 5000 kg—custom dimensions can be set using truck_weight and truck_size parameters, but note that only the car profile is enabled by default and custom profiles like truck may not be available in all regions.","schema":{"type":"string","enum":["car","truck"]},"example":"car"},{"name":"geometry","in":"query","description":"Sets the output format of the route geometry in the response. On providing polyline and polyline6 as input, respective encoded geometry is returned.Default: polyline6.","schema":{"type":"string","enum":["polyline","polyline6","geojson"]},"example":"geojson"},{"name":"avoid","in":"query","description":"Set this parameter to avoid specific route objects using a pipe comma separator for multiple values; this acts as a flexible filter (effective only with route_type=fastest) and still returns a route if no alternatives exist—except for bbox, tunnel, and geofence_id, which enforce strict avoidance and return a 4xx error if no route is found; for bbox, boundaries must be defined in the format bbox:min_lat,min_lng,max_lat,max_lng, supporting multiple boxes (max perimeter 500 km), and for sharp_turn, the default permissible angle range is [120,240] clockwise (customizable via turn_angle_range); when using geofence_id; ferry routes are avoided by default unless this parameter is explicitly set, and specifying none with other values causes an error as no valid route can be generated.","schema":{"type":"string","enum":["toll","highway","ferry","sharp_turn","uturn","service_road","left_turn","right_turn","bbox","geofence_id","tunnel","none"]},"example":"ferry"},{"name":"exclude","in":"query","description":"This parameter is a strict filter that ensures routes exclude the specified object(s), separated by a pipe (`,`); effective only when `route_type=fastest`, it returns a 4xx error if no valid route exists, with default `sharp_turn` angles in [120,240] (override via `turn_angle_range`), and using `none` with other values results in an error.","schema":{"type":"string","enum":["toll","ferry","highway","service_road","uturn","sharp_turn","left_turn","right_turn","none"]},"example":"none"},{"name":"approaches","in":"query","description":"A semicolon-separated list specifying the side of the road to approach each waypoint; use `unrestricted` to approach from either side, `curb` to approach from the driving side, with the number of values being one more than the waypoints—skipped values can be left blank using `;`.","schema":{"type":"string","enum":["unrestricted","curb"]},"example":"unrestricted;unrestricted;unrestricted"},{"name":"departure_time","in":"query","description":"Use this parameter to set a departure time, expressed as UNIX epoch timestamp in seconds, for calculating the isochrone contour. The response will consider the typical traffic conditions at the given time and return a contour which can be reached under those traffic conditions. Please note that if no input is provided for this parameter then the traffic conditions at the time of making the request are considered.","schema":{"type":"integer"},"example":1563254734},{"name":"local_departure_time","in":"query","description":"Use this parameter to specify departure time in local time format (day name and time). Format: 'DayName HH:mm'. The API will automatically convert this to the appropriate UTC timestamp based on the timezone of the origin location. Cannot be used together with departure_time parameter. Examples: Monday 08:00","schema":{"type":"string"}},{"name":"truck_size","in":"query","description":"This defines the dimensions of a truck in centimeters (cm). This parameter is effective only when the mode=truck. Maximum dimensions are as follows: Height = 1000 cm ,Width = 5000 cm ,Length = 5000 cm.Format: height,width,length","schema":{"type":"string"}},{"name":"truck_weight","in":"query","description":"This parameter defines the weight of the truck including trailers and shipped goods in kilograms (kg). This parameter is effective only when mode=truck. Minimum: 1 ,Maximum: 100000","schema":{"type":"integer"},"example":11770},{"name":"route_type","in":"query","description":"Set the route type that needs to be returned.","schema":{"type":"string","enum":["fastest","shortest"]},"example":"fastest"},{"name":"altcount","in":"query","description":"Sets the number of alternative routes to return. It is effective only when alternatives is true.Please note that adding alternative route count does not guarantee matching number of routes to be returned if potential alternative routes do not exist.Minimum: 1 ,Maximum: 3","schema":{"type":"integer"},"example":3},{"name":"alternatives","in":"query","description":"When true the API will return alternate routes.The alternatives is effective only when there are no waypoints included in the request and the route_type is set to shortest.You can set the number of alternate routes to be returned in the altcount property.","schema":{"type":"boolean"},"example":false},{"name":"road_info","in":"query","description":"Use this parameter to receive additional information about the road segments returned in the response. Currently, following inputs are supported: max_speed : segment-wise maximum speed information of roads in the response. toll_distance : returns the total distance travelled on the road segments having tolls. toll_cost: returns the range of toll charges, in local currency, that can be incurred for the suggested route.Please note that this parameter is effective only when option=flexible.","schema":{"type":"string","enum":["max_speed","toll_distance","toll_cost"]},"example":"max_speed"},{"name":"cross_border","in":"query","description":"Specify if crossing an international border is expected for operations near border areas. When set to false, the API will prohibit routes crossing the borders. When set to true, the service will return routes which cross the borders between countries, if required for the given set destination and waypoints.This feature is available in North America region only. Please get in touch with support@nextbillion.ai to enquire/enable other areas.","schema":{"type":"boolean"},"example":false},{"name":"truck_axle_load","in":"query","description":"Specify the total load per axle (including the weight of trailers and shipped goods) of the truck, in tonnes. When used, the service will return routes which are legally allowed to carry the load specified per axle. Please note this parameter is effective only when `mode=truck`.","schema":{"type":"number"}},{"name":"hazmat_type","in":"query","description":"Specify the type of hazardous material being carried and the service will avoid roads which are not suitable for the type of goods specified. Multiple values can be separated using a comma operator ',' .Please note that this parameter is effective only when mode=truck.","schema":{"type":"string","enum":["explosives","gas","flammable_liquid","flammable_gas","organic","toxic","radioactive","corrosive","other"]}},{"name":"turn_angle_range","in":"query","description":"Specify the turn angles that can be taken safely by the vehicle. The permissible turn angles are calculated as [0 + turn_angle_range , 360 - turn_angle_range]. Please note that this parameter is effective only when avoid = sharp_turn. It is worth highlighting here that providing smaller angles might lead to 4xx errors as route engine might not be able find routes satisfying the smaller turn angle criteria for all turns in the route.","schema":{"type":"integer"}},{"name":"drive_time_limits","in":"query","description":"An array of durations, in seconds, for which the driver can drive continuously before taking a rest. Multiple drive time limits can be separated by a ,. After driving for the given duration the driver will take a rest for a fixed period, specified in rest_times . Once the rest duration is over, the subsequent driving duration starts and the process continues until all drive times and rest periods are exhausted or if the driver reaches the destination. This feature is useful in complying with Hours of Service regulations and calculates actual ETAs with regulated driving periods. As an example, a drive_time_limits = [500, 300] means that driver can drive for 500 seconds before the first rest period and then drive for another 300 seconds before taking a rest next time. Please note that, If the trip duration is smaller than the first input of drive_time_limits, then there will be no rest actions scheduled by the service. If the trip duration is larger than the scheduled time, then a warning is returned in the response - along with details of last leg of the trip - to indicate the same.Format: drive_time_limits_1, drive_time_limits_2,...","schema":{"type":"string"},"example":"500, 400, 400"},{"name":"rest_times","in":"query","description":"An array of durations, in seconds, for which the driver should rest after completing the corresponding continuous driving interval (provided in drive_time_limits). Multiple rest times can be separated by a , . Ideally, the number of rest_times provided should be equal to the number of drive_time_limits provided for proper scheduling of driver breaks. As an example, a rest_times = [500, 300] means that driver can rest for 500 seconds after the first continuous driving session and rest for 300 seconds after the next continuous driving session. Please note that: If the number of rest_times provided are less than the number of drive_time_limits, the service will schedule a rest period of 0 seconds after each such drive time period which does not have a corresponding entry in rest_times. If the number of rest_times provided is more than the number of drive times provided, the additional rest times are never applied.Format: rest_times_1,rest_times_2,rest_times_3,....","schema":{"type":"string"},"example":"500, 300, 100"},{"name":"bearings","in":"query","description":"Limits the search to road segments with given bearing, in degrees, towards true north in clockwise direction. Each bearings should be in the format of degree,range, where the degree should be a value between [0, 360] and range should be a value between [0, 180].Please note that the number of bearings should be two more than the number of waypoints. This is to account for the bearing of origin and destination. If a route can approach a waypoint or the destination from any direction, the bearing for that point can be specified as 0,180. Format: degree0,range0;degree1,range1;...","schema":{"type":"string"}},{"name":"emission_class","in":"query","description":"Specify the emission class to which the vehicle (engine) belongs to. The service will use this setting to generate routes that are permissible for that engine class. Only the emission classifications in the EU regions are supported currently.","schema":{"type":"string","enum":["euro0","euro1","euro2","euro3","euro4","euro5","euro6","euro7","euro8","euro9"]}},{"name":"option","in":"query","description":"Use this option to switch to time based routing or if you want to choose between the fastest and shortest route types.","required":true,"schema":{"type":"string","enum":["flexible"]},"example":"flexible"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlexibleDirectionResponseModel"},"example":"{\n    \"status\": \"Ok\",\n    \"routes\": [\n        {\n            \"geometry\": \"yriiHyyzLFaA`@iH@M?ApAuSBQ@O??@M??HaAL{ADm@Fi@Da@BWp@RLD??FBHDFFHHd@j@PVRZ~@pA\\\\j@b@v@PZJPFF^v@??P\\\\^r@PTX\\\\\\\\TNJXPRRPNLLXVLJ^Z??`Av@h@`@??hA|@?@r@j@NJd@^h@`@?@jAbA\\\\\\\\hDhCf@b@NN??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@d@i@|@{@HGv@m@FC??FCVOTMPIRK@?VKNG\\\\IZILEXEh@Ih@GXC`@ChBO??n@EXAx@Cn@?`@?d@B\\\\BH???VBzAR??HBTBVBf@Hb@Jh@Lb@H`@HXHVH\\\\Lp@Rb@P\\\\NLF??b@V^V\\\\Tv@h@j@d@`@Xf@b@??RRTX`CtC~ArBz@fArA~AjAhARTTP^XZTTNRLTLd@VlAd@~@XbAXbAPv@HtAJ??tF`@`@DxFd@bAHzBPp@FL@f@Fr@Jd@JRF^LbA^??TNPJLHTPXPXV??XTNNRR^`@Zb@RV^l@?@\\\\j@??^x@HN\\\\z@N`@FN?@FTFTBFBJFRNl@FXFVDPDXBRF\\\\Fd@Fh@Fb@B^BRFnAFrA@N?@@t@?@@d@???h@AVAl@IbCMfBE~@ARIjA[jFOnC?@g@nIc@rHYzC??E`@G\\\\QpAM`A??In@OrA??O`BOnCAj@AfA?pA?x@FhADdABX@H??J|@PnADTP~@FZDNDP??Vz@HVVr@HV??DJj@nAl@zAb@dAd@bAb@z@\\\\TNz@f@`@ZTPVTRPt@t@^^h@t@PX\\\\b@Vb@n@bAJN??FJ^r@??T^T^d@v@b@x@jCrEVb@Zh@^n@l@bAvBvDPX\\\\l@h@~@|@|AJPFJh@`Ab@t@\\\\j@NV^p@h@`ArBjDz@xAR^??JXHb@HJJRP\\\\JTTb@BDNX??d@~@h@rAHR~@dC@PBLFRPj@Lj@BJBR@T?V?TCVETI\\\\GLMNIHOJYL_@Jq@Z??qBA??oAI??i@Eg@G?sACo@SiECg@CYC]EWCc@Gw@W{BEKKK??O?QAQ@[HcAVi@P]LSP??MU??ES]m@A?L]FKDGBEBCHCj@ObA[`@M\",\n    \"distance\": 183895.266,\n    \"duration\": 11237.266,\n    \"start_location\": {\"latitude\": 48.87869,\"longitude\": 2.27245},\n    \"end_location\": {\"latitude\": 48.73002,\"longitude\": 2.30448}\n}\n"}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"1c986743-f958-4d6d-8923-f5219c69fa95","errors":[{"code":"DIS-RT-403","detail":"The 'mode' provided in the input, ca, is invalid with option=flexible. Valid values for 'mode' are car, motorcycle, bike, truck, walk for flexible routing (setting option=flexible)."}]}}}},"401":{"description":"Unauthorized: Invalid token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1001","detail":"Unauthorized"}]}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1002","detail":"Not Authorized to access this API"}]}}}},"429":{"description":"Too many requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1004","detail":"Too many requests"}]}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}}},"security":[{"bearerAuth":[]},{"ApiKeyAuth":[]}]},"post":{"tags":["Route Api"],"description":"The Route Flexible API provides customizable routing with features like truck routing, time-based paths, and traffic-aware routes. It supports both GET and POST methods, with differences in waypoint limits.","operationId":"postNBDirectionRequest","parameters":[{"name":"X-Request-Id","in":"header","description":"The X-Request-Id header is optional but incredibly useful for developers. It serves as a unique identifier for requests within our system. When you encounter any problems with your requests, providing us with the X-Request-Id will enable us to pinpoint the specific request in question without the need for extensive manual searching. This means faster and more efficient troubleshooting.","schema":{"type":"string"}},{"name":"option","in":"query","description":"Use this option to switch time based routing or if you want to choose between the fastest and shortest route types.","required":true,"schema":{"type":"string","enum":["flexible"]},"example":"flexible"}],"requestBody":{"content":{"application/json":{"schema":{"type":"object"},"examples":{"CoordinatesBasedExample":{"description":"post request example for Direction api(coordinates)","value":{"coordOrder":"LatLon","origin":"48.87862672840649, 2.2724349629292195","destination":"48.73000636636801, 2.3044168556664175","mode":"car","waypoints":"48.43000636636801, 2.2044168556664175|48.93000636636801, 2.1044168556664175","geometry":"geojson","alternatives":true,"altcount":3,"avoid":"ferry","exclude":"none","approaches":"unrestricted;unrestricted;unrestricted","departure_time":1563254734,"route_type":"fastest","road_info":"max_speed","cross_border":false,"drive_time_limits":"500, 400, 400","rest_times":"500, 300, 100"}},"post request address based example":{"description":"post request address based example","value":{"originAddress":"POINT REYES STATION CA","originCountry":"USA","destinationAddress":"Lagunitas CA","destinationCountry":"USA","waypointAddresses":[{"address":"Lagunitas-Forest Knolls","country":"USA"},{"address":"Lagunitas-Forest Knolls","country":"USA"}],"mode":"car","geometry":"geojson","alternatives":true,"altcount":3,"avoid":"ferry","exclude":"none","departure_time":1563254734,"route_type":"fastest","road_info":"max_speed","cross_border":false,"drive_time_limits":"500, 400, 400","rest_times":"500, 300, 100"}}}}},"required":true},"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlexibleDirectionResponseModel"},"examples":{"example":{"description":"successful response for Direction api","value":"{\n    \"status\": \"Ok\",\n    \"routes\": [\n        {\n            \"geometry\": \"yriiHyyzLFaA`@iH@M?ApAuSBQ@O??@M??HaAL{ADm@Fi@Da@BWp@RLD??FBHDFFHHd@j@PVRZ~@pA\\\\j@b@v@PZJPFF^v@??P\\\\^r@PTX\\\\\\\\TNJXPRRPNLLXVLJ^Z??`Av@h@`@??hA|@?@r@j@NJd@^h@`@?@jAbA\\\\\\\\hDhCf@b@NN??TRNP|A`Bj@t@BD@?NTd@j@TXPTTXNP??VXd@j@PR??FF~@`An@p@|AnAj@b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BO??n@EXAx@Cn@?`@?d@B\\\\BH???VBzAR??HBTBVBf@Hb@Jh@Lb@H`@HXHVH\\\\Lp@Rb@P\\\\NLF??b@V^V\\\\Tv@h@j@d@`@Xf@b@??RRTX`CtC~ArBz@fArA~AjAhARTTP^XZTTNRLTLd@VlAd@~@XbAXbAPv@HtAJ??tF`@`@DxFd@bAHzBPp@FL@f@Fr@Jd@JRF^LbA^??TNPJLHTPXPXV??XTNNRR^`@Zb@RV^l@?@\\\\j@??^x@HN\\\\z@N`@FN?@FTFTBFBJFRNl@FXFVDPDXBRF\\\\Fd@Fh@Fb@B^BRFnAFrA@N?@@t@?@@d@???h@AVAl@IbCMfBE~@ARIjA[jFOnC?@g@nIc@rHYzC??E`@G\\\\QpAM`A??In@OrA??O`BOnCAj@AfA?pA?x@FhADdABX@H??J|@PnADTP~@FZDNDP??Vz@HVVr@HV??DJj@nAl@zAb@dAd@bAb@z@\\\\TNz@f@`@ZTPVTRPt@t@^^h@t@PX\\\\b@Vb@n@bAJN??FJ^r@??T^T^d@v@b@x@jCrEVb@Zh@^n@l@bAvBvDPX\\\\l@h@~@|@|AJPFJh@`Ab@t@\\\\j@NV^p@h@`ArBjDz@xAR^??JXHb@HJJRP\\\\JTTb@BDNX??d@~@h@rAHR~@dC@PBLFRPj@Lj@BJBR@T?V?TCVETI\\\\GLMNIHOJYL_@Jq@Z??qBA??oAI??i@Eg@G?sACo@SiECg@CYC]EWCc@Gw@W{BEKKK??O?QAQ@[HcAVi@P]LSP??MU??ES]m@A?L]FKDGBEBCHCj@ObA[`@M\",\n    \"distance\": 183895.266,\n    \"duration\": 11237.266,\n    \"start_location\": {\"latitude\": 48.87869,\"longitude\": 2.27245},\n    \"end_location\": {\"latitude\": 48.73002,\"longitude\": 2.30448}\n}\n"}}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"1c986743-f958-4d6d-8923-f5219c69fa95","errors":[{"code":"DIS-RT-403","detail":"The 'mode' provided in the input, ca, is invalid with option=flexible. Valid values for 'mode' are car, motorcycle, bike, truck, walk for flexible routing (setting option=flexible)."}]}}}},"401":{"description":"Unauthorized: Invalid token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1001","detail":"Unauthorized"}]}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1002","detail":"Not Authorized to access this API"}]}}}},"429":{"description":"Too many requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1004","detail":"Too many requests"}]}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}}},"security":[{"bearerAuth":[]},{"ApiKeyAuth":[]}]}},"/v1/isochrone/location":{"get":{"tags":["Travel Boundary Api"],"description":"Travel Boundary API computes areas reachable within a specific time or distance from a given point. It returns these as polygons or lines for easy map visualization and zone planning.","operationId":"getIsoChroneRequest","parameters":[{"name":"X-Request-Id","in":"header","description":"The X-Request-Id header is optional but incredibly useful for developers. It serves as a unique identifier for requests within our system. When you encounter any problems with your requests, providing us with the X-Request-Id will enable us to pinpoint the specific request in question without the need for extensive manual searching. This means faster and more efficient troubleshooting.","schema":{"type":"string"}},{"name":"coordOrder","in":"query","description":"Specifies the order of coordinates in the request. Use 'LonLat' when providing coordinates in Longitude,Latitude order (X,Y). If not specified or set to 'LatLon', coordinates are expected in Latitude,Longitude order. This parameter applies to the 'coordinates' parameter. Default: LatLon, Example: LatLon","schema":{"type":"string","enum":["LatLon","LonLat"]}},{"name":"address","in":"query","description":"The address of the location which acts as the starting point for which the isochrone lines need to be determined. Example: POINT REYES STATION CA","schema":{"type":"string"}},{"name":"country","in":"query","description":"Country name used only when the starting location is provided as an address. Example: USA","schema":{"type":"string"}},{"name":"coordinates","in":"query","description":"The coordinates of the location which acts as the starting point for which the isochrone lines need to be determined. Format will be latitude, longitude.","schema":{"type":"string"},"example":"38.62283557773102, -90.22415391657728"},{"name":"contours_minutes","in":"query","description":"The time, in minutes, for which an isochrone contour needs to be determined. You can request up to 4 time based contours in a single request using a , as a separator.Please note that, when requesting multiple isochrones, the times must be provided in an increasing order.The maximum time that can be specified is 40 minutes.This parameter is mandatory when contours_meters is not provided in the request.","schema":{"type":"string"},"example":"2,5"},{"name":"contours_meters","in":"query","description":"The distance, in meters, for which an isochrone contour needs to be determined. You can request up to 4 distance based contours in a single request using a , as a separator.Please note that, when requesting multiple isochrones, the distances must be provided in an increasing order.The maximum distance that can be specified is 60000 meters (60km).This parameter is mandatory when contours_minutes is not provided in the request.","schema":{"type":"string"},"example":"2500,3000"},{"name":"mode","in":"query","description":"Set which driving mode the service should use to determine the contour.For example, if you use car, the API will return an isochrone contour that a car can reach within the specified time or after driving the specified distance. Using truck will return a contour that a truck can reach after taking into account appropriate truck routing restrictions.[Note: Only the car profile is enabled by default. Please note that customized profiles (including truck) might not be available for all regions.","schema":{"type":"string","enum":["car","truck"]},"example":"car"},{"name":"contours_colors","in":"query","description":"The hex code of the color to fill isochrone contour. When requesting multiple contours, it is recommended to provide color codes for each of the requested contours, separated by a ,. If no colors are specified, the Isochrone API will assign a random color scheme to the output.","schema":{"type":"string"},"example":"ff0000,bf4040"},{"name":"polygons","in":"query","description":"When true the contour is returned as a GeoJSON polygon. The contour is returned as a linestring when this parameter is false. Default value is false","schema":{"type":"boolean"},"example":false},{"name":"denoise","in":"query","description":"A floating point value from 0.0 to 1.0 that can be used to remove smaller contours. A value of 1.0 will only return the largest contour for a given value. A value of 0.5 drops any contours that are less than half the area of the largest contour in the set of contours for that same value. Minimum: 0,Maximum: 1 and  Default is 1","schema":{"type":"number"},"example":0.5},{"name":"generalize","in":"query","description":"A positive floating point value, in meters, used as the tolerance for Douglas-Peucker generalization. There is no upper bound. As the generalization value goes higher, more and more straight lines form the resulting contour because of higher approximation of actual contour boundary. If no value is specified in the request, the Isochrone API will choose the most optimized generalization to use for the request.Please note that the generalization of contours can lead to self-intersections, as well as intersections of adjacent contours. Values under 2 metres are going to time out and are not sensible, since if you want to generalize you should use at least 10 or more meters","schema":{"type":"number"},"example":110.3},{"name":"departure_time","in":"query","description":"Use this parameter to set a departure time, expressed as UNIX epoch timestamp in seconds, for calculating the isochrone contour. The response will consider the typical traffic conditions at the given time and return a contour which can be reached under those traffic conditions. Please note that if no input is provided for this parameter then the traffic conditions at the time of making the request are considered.","schema":{"type":"integer"},"example":1563254734},{"name":"local_departure_time","in":"query","description":"Use this parameter to specify departure time in local time format (day name and time). Format: 'DayName HH:mm'. The API will automatically convert this to the appropriate UTC timestamp based on the timezone of the start location. Cannot be used together with departure_time parameter. Examples: Monday 08:00","schema":{"type":"string"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IsoChroneResponseModel"},"example":{"type":"FeatureCollection","features":[{"type":"Feature","properties":{"fill":"#8D5A9E","fillOpacity":0.33,"fillColor":"#8D5A9E","color":"#8D5A9E","contour":1.0,"opacity":0.33,"metric":"time"},"geometry":{"type":"LineString","coordinates":[[-0.087369,48.648116],[-0.087404,48.647783],[-0.088191,48.647925],[-0.088369,48.647856],[-0.088521,48.6479],[-0.089153,48.647963],[-0.089369,48.648068],[-0.089686,48.648064],[-0.090031,48.647747],[-0.090201,48.647579],[-0.090369,48.647564],[-0.090856,48.647235],[-0.090879,48.647237],[-0.091369,48.647112],[-0.091736,48.647115],[-0.091998,48.647118],[-0.092369,48.64712],[-0.092707,48.647085],[-0.092742,48.646747],[-0.092988,48.646366],[-0.093369,48.646211],[-0.093839,48.646218],[-0.093897,48.646219],[-0.094369,48.646225],[-0.09485,48.646229],[-0.094887,48.646229],[-0.095369,48.646233],[-0.095692,48.646071],[-0.095854,48.645747],[-0.09603,48.645408],[-0.096369,48.645235],[-0.096848,48.645227],[-0.096891,48.645225],[-0.097369,48.645216],[-0.097829,48.645208],[-0.097911,48.645205],[-0.098369,48.645196],[-0.098811,48.64519],[-0.098929,48.645187],[-0.099369,48.645181],[-0.099792,48.64517],[-0.099954,48.645161],[-0.087241,48.647875],[-0.087369,48.648116]]}}],"status":"Ok"}}}},"400":{"description":"Invalid request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"b2192a09-9087-45bf-90fb-7c5ddfafe44e","errors":[{"code":"DIS-RT-400","detail":"No location coordinates provided in the input request. Please provide valid locations to proceed."}]}}}},"401":{"description":"Unauthorized: Invalid token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1001","detail":"Unauthorized"}]}}}},"500":{"description":"Internal Server Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}},"403":{"description":"Forbidden","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1002","detail":"Not Authorized to access this API"}]}}}},"429":{"description":"Too many requests","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1004","detail":"Too many requests"}]}}}},"503":{"description":"Service Unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"},"example":{"id":"124fe974-cc53-4722-861e-7f4bf582a5ec","errors":[{"code":"DIS-1003","detail":"Issue with internal services"}]}}}}},"security":[{"bearerAuth":[]},{"ApiKeyAuth":[]}]}}},"components":{"schemas":{"Distance":{"type":"object","properties":{"value":{"type":"integer","format":"int32"}}},"Duration":{"type":"object","properties":{"value":{"type":"integer","format":"int32"}}},"Element":{"type":"object","properties":{"duration":{"$ref":"#/components/schemas/Duration"},"distance":{"$ref":"#/components/schemas/Distance"}}},"FlexibleMatrixResponseModel":{"type":"object","properties":{"status":{"type":"string"},"warning":{"type":"array","items":{"type":"string"}},"rows":{"type":"array","items":{"$ref":"#/components/schemas/Row"}}}},"Row":{"type":"object","properties":{"elements":{"type":"array","items":{"$ref":"#/components/schemas/Element"}}}},"ErrorDetail":{"type":"object","description":"Details of Error","properties":{"code":{"type":"string","description":"A unique code representing the specific error","example":"DIS-1001"},"detail":{"type":"string","description":"A detailed message describing the error.","example":"Unauthorized"}}},"ErrorResponse":{"type":"object","description":"Error response containing request ID and error details","properties":{"id":{"type":"string","description":"Unique identifier for the error","example":"ad45c1aded938181a05f256e5a1b594d"},"errors":{"type":"array","description":"List of error details","items":{"$ref":"#/components/schemas/ErrorDetail"}}}},"IsochroneRequest":{"type":"object","properties":{"travelBoundaries":{"type":"array","items":{"$ref":"#/components/schemas/IsochroneRequest"}},"coordinates":{"type":"string"},"contours_meters":{"type":"string"},"contours_minutes":{"type":"string"},"mode":{"type":"string"},"contours_colors":{"type":"string"},"polygons":{"type":"boolean"},"denoise":{"type":"number","format":"double"},"generalize":{"type":"number","format":"double"},"departure_time":{"type":"integer","format":"int64"},"local_departure_time":{"type":"string"}}},"BatchIsoResponseModel":{"type":"object","properties":{"type":{"type":"string"},"features":{"type":"array","items":{"$ref":"#/components/schemas/IsoFeature"}},"status":{"type":"string"}}},"IsoFeature":{"type":"object","properties":{"type":{"type":"string"},"properties":{"$ref":"#/components/schemas/IsoProperties"},"geometry":{"$ref":"#/components/schemas/IsoGeometry"}}},"IsoGeometry":{"type":"object","properties":{"type":{"type":"string"},"coordinates":{"type":"object"},"polygonCoordinates":{"type":"array","items":{"type":"array","items":{"type":"array","items":{"type":"number"}}}},"lineCoordinates":{"type":"array","items":{"type":"array","items":{"type":"number"}}}}},"IsoProperties":{"type":"object","properties":{"fill":{"type":"string"},"fillOpacity":{"type":"number","format":"double"},"fillColor":{"type":"string"},"color":{"type":"string"},"contour":{"type":"number","format":"double"},"opacity":{"type":"number","format":"double"},"metric":{"type":"string"}}},"FlexibleDirectionResponseModel":{"type":"object","properties":{"status":{"type":"string"},"msg":{"type":"string"},"routes":{"type":"array","items":{"$ref":"#/components/schemas/Route"}},"warning":{"type":"array","items":{"type":"string"}}}},"GeoJson":{"type":"object","properties":{"type":{"type":"string"},"geometry":{"$ref":"#/components/schemas/Geometry"},"properties":{"type":"string"}}},"Geometry":{"type":"object","properties":{"type":{"type":"string"},"coordinates":{"type":"object"}}},"Leg":{"type":"object","properties":{"distance":{"$ref":"#/components/schemas/ValueWrapper"},"duration":{"$ref":"#/components/schemas/ValueWrapper"},"start_location":{"$ref":"#/components/schemas/Location"},"end_location":{"$ref":"#/components/schemas/Location"},"steps":{"type":"array","items":{"$ref":"#/components/schemas/Step"}},"post_actions":{"type":"array","items":{"$ref":"#/components/schemas/PostAction"}},"warnings":{"type":"array","items":{"$ref":"#/components/schemas/Warning"}}}},"Location":{"type":"object","properties":{"latitude":{"type":"number","format":"double"},"longitude":{"type":"number","format":"double"}}},"MaxSpeed":{"type":"object","properties":{"offset":{"type":"number","format":"double"},"length":{"type":"number","format":"double"},"value":{"type":"number","format":"double"}}},"PostAction":{"type":"object","properties":{"action":{"type":"string"},"duration":{"type":"string"}}},"RoadInfo":{"type":"object","properties":{"max_speed":{"type":"array","items":{"$ref":"#/components/schemas/MaxSpeed"}},"toll_distance":{"type":"number","format":"double"},"toll_cost":{"$ref":"#/components/schemas/TollCost"}}},"Route":{"type":"object","properties":{"geometry":{"type":"string"},"distance":{"type":"number","format":"double"},"duration":{"type":"number","format":"double"},"start_location":{"$ref":"#/components/schemas/Location"},"end_location":{"$ref":"#/components/schemas/Location"},"geojson":{"$ref":"#/components/schemas/GeoJson"},"legs":{"type":"array","items":{"$ref":"#/components/schemas/Leg"}},"road_info":{"$ref":"#/components/schemas/RoadInfo"}}},"Step":{"type":"object","properties":{"geometry":{"type":"string"},"geojson":{"$ref":"#/components/schemas/GeoJson"},"start_location":{"$ref":"#/components/schemas/Location"},"end_location":{"$ref":"#/components/schemas/Location"},"distance":{"$ref":"#/components/schemas/ValueWrapper"},"duration":{"$ref":"#/components/schemas/ValueWrapper"}}},"TollCost":{"type":"object","properties":{"minimum_toll_cost":{"type":"number","format":"double"},"maximum_toll_cost":{"type":"number","format":"double"},"currency":{"type":"string"}}},"ValueWrapper":{"type":"object","properties":{"value":{"type":"number","format":"double"}}},"Warning":{"type":"object","properties":{"title":{"type":"string"}}},"IsoChroneResponseModel":{"type":"object","properties":{"type":{"type":"string"},"features":{"type":"array","items":{"$ref":"#/components/schemas/IsoFeature"}},"status":{"type":"string"},"warning":{"type":"array","items":{"type":"string"}}}}},"securitySchemes":{"ApiKeyAuth":{"type":"apiKey","description":"Pass the value in the following format: Apikey <base64(api_key:api_secret)>.","name":"Authorization","in":"header","scheme":"ApiKeyAuth"},"bearerAuth":{"type":"http","description":"Pass the value as JWT Bearer Token.","name":"bearerAuth","in":"header","scheme":"bearer","bearerFormat":"JWT"}}}}