Snap API matches given GPS point to the nearest road in the road network. Full URL for requests is https://api.strues-maps.lt/v1/snap. Only successful requests are counted towards hard limits and are billed.
point=long,lat
Optional point data as single variable.
point.long=long
Longitude must be supplied in WGS84 projection, also known as EPSG 4326.
point.lat=lat
Latitude must be supplied in WGS84 projection, also known as EPSG 4326.
api_key=your_personal_api_key
Api key is provided after registration. Api key is used for service configuration like hard limits and billing.
200
- Successful response
Request was successfully. Response body contains distance and duration of the fastest route between all pairs of supplied coordinates.
400
- Bad request exception
Returned if parameters are not provided or provided in an invalid format.
401
- Unauthorized
Returned if api key is invalid.
429
- Too many requests
Returned if hard limits are reached.
402
- Payment required
Returned if user has insufficient funds to make a request.
500
- Internal server error
Returned if unexpected error has occurred. We are working on it to resolve it.
{
"code": "Ok",
"waypoints": [
{
"location": [
23.995378,
54.530861
],
"name": "",
"distance": 24.04809,
}
]
}
code
- "Ok"
waypoints[i]
- array of objects sorted by distance to the input coordinate.
waypoints[i].location[0]
- longitude of matching location. Longitude is in WGS84 projection, also known as EPSG 4326.
waypoints[i].location[1]
- latitude of matching location. Latitude is in WGS84 projection, also known as EPSG 4326.
waypoints[i].name
- name of street the coordinate matched to.
waypoints[i].distance
- distance to matching location in meters.
Snap API matches given GPS point to the nearest road in the road network. Full URL for requests is https://api.strues-maps.lt/v1/snap/{point}. Only successful requests are counted towards hard limits and are billed.
{point} - long,lat
Point data as single variable. Coordinates must be supplied in WGS84 projection, also known as EPSG 4326.
api_key=your_personal_api_key
Api key is provided after registration. Api key is used for service configuration like hard limits and billing.
Snap API matches given GPS point to the nearest road in the road network. Full URL for requests is https://api.strues-maps.lt/v1/snap/polyline({polyline}). Only successful requests are counted towards hard limits and are billed.
{polyline} - point encoded in polyline format
Polyline encoded longitude and latitude of single point. Coordinates must be supplied in WGS84 projection, also known as EPSG 4326.
api_key=your_personal_api_key
Api key is provided after registration. Api key is used for service configuration like hard limits and billing.