POST
/api/v1/customer/stores/{id}/locations
This API method will allow you to get all locations for a given store / chain within a given radius.
Radius is optional, but defaulted to 100. Latitude and longitude if not passed together, will cause the entire list of locations to load.
Request Parameters
Parameter | Value / Type | Required |
|---|---|---|
radius | INTEGER (DEFAULT 100) | false |
latitude | DECIMAL(10, 8) | false |
longitude | DECIMAL(11, 8) | false |
search | STRING | false |
location_id | STRING|INT | false |
Sample Response
{
"status": true,
"count": 5,
"items": [
{
"id": "ORwdvb48EQZeJXLBq7nQ",
"name": "Steve Phillips",
"store_number": 14,
"longitude": "-74.58720000",
"latitude": "41.61340000",
"address": "123 Address Lane",
"city": "Rock Drive",
"state": "MA",
"zip": "12225",
"phone": "(111) 111-1111",
"location_hours": {
"mon": {
"isActive": true,
"timeFrom": "9:00 AM",
"timeTill": "5:00 PM"
},
"tue": {
"isActive": true,
"timeFrom": "9:00 AM",
"timeTill": "5:00 PM"
},
"wed": {
"isActive": true,
"timeFrom": "9:00 AM",
"timeTill": "5:00 PM"
},
"thu": {
"isActive": true,
"timeFrom": "9:00 AM",
"timeTill": "5:00 PM"
},
"fri": {
"isActive": true,
"timeFrom": "3:35 PM",
"timeTill": "5:00 PM"
},
"sat": {
"isActive": false,
"timeFrom": null,
"timeTill": null
},
"sun": {
"isActive": false,
"timeFrom": null,
"timeTill": null
}
},
"store_name": "14 - Test Store"
},
{
"id": "34aQnOG0m9AnmMVB7Yqy",
"name": "John Doe",
"store_number": 12,
"longitude": "-74.58720000",
"latitude": "41.61340000",
"address": "123 Test Drive",
"city": "Rock Hill",
"state": "MA",
"zip": "13175",
"phone": "(111) 111-1111",
"location_hours": {
"mon": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"tue": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"wed": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"thu": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"fri": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"sat": {
"isActive": true,
"timeFrom": "6:00 AM",
"timeTill": "7:00 PM"
},
"sun": {
"isActive": true,
"timeFrom": "6:00 PM",
"timeTill": "7:00 PM"
}
},
"store_name": "12 - Snowfalls Town",
"is_open": false,
"store_time_status": "Opens Thu 4:00 AM",
"location_services": [],
}
]
}{
"status": false,
"errorCode": "VALIDATION_EXCEPTION",
"messages": {
"longitude": [
"Longitude must be formatted properly"
]
}
}{
"status": false,
"errorCode": "NO_ITEMS",
"message": "No Locations Exist"
}