Nearest Branches
GET
http://82.180.154.188:4352/branches/nearest
Last modified:2025-04-12 12:53:59
maxDistance
m away for the location you provide in the request query params.Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request GET 'http://82.180.154.188:4352/branches/nearest?longitude=30.150000&latitude=30.111111&maxDistance=10000'
Response Response Example
{"status":"success","results":1,"data":{"branches":[{"_id":"67fa5e9cf0bc58483702a71c","name":"Downtown Branch for testing loation","location":{"type":"Point","coordinates":[30.111111,30.111112],"area":"Downtown"},"workingDays":[{"day":"Saturday","isActive":true,"timeRanges":[{"from":"08:00","to":"12:00"},{"from":"16:00","to":"20:00"}]},{"day":"Sunday","isActive":false,"timeRanges":[]}],"createdAt":"2025-04-12T12:37:48.414Z","updatedAt":"2025-04-12T12:37:48.414Z","__v":0}]}}
Request
Query Params
longitude
string
required
Example:
30.150000
latitude
string
required
Example:
30.111111
maxDistance
string
optional
Example:
10000