GET waterbodies/closest?lat={lat}&lng={lng}&accuracy={accuracy}&len={len}&s={s}
Returns the list of 20 waterbodies closest to the queried location.
Request Information
URI Parameters
| Name | Description | Type | Additional information |
|---|---|---|---|
| lat | decimal number |
None. |
|
| lng | decimal number |
None. |
|
| accuracy | integer |
None. |
|
| len | integer |
Default value is 20 |
|
| s | integer |
None. |
Body Parameters
None.
Response Information
Resource Description
GetClosestViewModel| Name | Description | Type | Additional information |
|---|---|---|---|
| waterbodies |
List of all water bodies |
Collection of ClosestWaterBodyModel |
None. |
| location |
The point from which the calculations are made |
PointLocation |
None. |
Response Formats
application/json, text/json
Sample:
{
"waterbodies": [
{
"Waterbody": {
"Location": {
"latitude": 1.0,
"longitude": 1.0
},
"Name": "sample string 1",
"Id": 2,
"Type": "sample string 3"
},
"Distance": "0.00",
"IsExternal": true
},
{
"Waterbody": {
"Location": {
"latitude": 1.0,
"longitude": 1.0
},
"Name": "sample string 1",
"Id": 2,
"Type": "sample string 3"
},
"Distance": "0.00",
"IsExternal": true
}
],
"location": {
"latitude": 1.0,
"longitude": 1.0
}
}
text/javascript, application/javascript, application/json-p
Sample:
/**/ typeof === 'function' && ({"waterbodies":[{"Waterbody":{"Location":{"latitude":1.0,"longitude":1.0},"Name":"sample string 1","Id":2,"Type":"sample string 3"},"Distance":"0.00","IsExternal":true},{"Waterbody":{"Location":{"latitude":1.0,"longitude":1.0},"Name":"sample string 1","Id":2,"Type":"sample string 3"},"Distance":"0.00","IsExternal":true}],"location":{"latitude":1.0,"longitude":1.0}});