Create a new restriction
Changed onRequest
- Base URLhttps://api.nextbillion.io
- AuthAPI key in query parameter key
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
Specify the type of restriction being created. Following restriction types are supported:
-
turn: Taking the given turn is restricted.
-
fixedspeed: Applies a fixed speed restriction in the given segments or geofence.
-
maxspeed: Applies a maximum speed limit in the given segments or geofence.
-
closure: The given segments or geofence is closed for specified mode of travel.
-
truck: Trucks are restricted in the given segments or geofence.
-
parking: No parking allowed in the given segments or geofence.
Query parameters
Use this parameter to decide the format for specifying the geofence coordinates. If true, then the coordinates of geofence can be specified as "latitude,longitude" format, otherwise they should be specified in "longitude,latitude" format.
A key is a unique identifier that is required to authenticate a request to the API.
Request body
Example request
{
"repeat_on": "repeatOn=\"Mo-Fr 07:00-09:00,17:00-19:00\""
}Response
The restriction has been successfully created.
Example response
{
"bbox": {
"minLat": 0,
"minLon": 0,
"maxLat": 1,
"maxLon": 1
},
"repeat_on": "Mo-Fr 07:00-09:00,17:00-19:00"
}Changes
- breaking
removed the enum value
backwardof the request property - breaking
removed the enum value
bothof the request property - breaking
removed the enum value
forwardof the request property - info
added the new
backwardenum value to the request property - info
added the new
bothenum value to the request property - info
added the new
forwardenum value to the request property
- breaking
- breaking
removed the enum value
backwardof the request property - breaking
removed the enum value
bothof the request property - breaking
removed the enum value
forwardof the request property - info
added the new
backwardenum value to the request property - info
added the new
bothenum value to the request property - info
added the new
forwardenum value to the request property
- breaking