You need an APITOKEN to access api v3. Please contact our support to obtain it. In this example, API token is e165ba2c55ba47c8c3ab4a9ecabad247. Replace it with your api token
Create a store
POST https://www.storemapper.co/api/v3/stores/
Example Request
curl https://www.storemapper.co/api/v3/stores \
-u e165ba2c55ba47c8c3ab4a9ecabad247: \
-d name="The Central Store" \
-d address="New York City"
Valid Arguments
name, address, phone, email, url, description, category,
custom_field_1, custom_field_2, custom_field_3, image_url, custom_marker_url,
latitude, longitude, hidden(true/false), tier
Mandatory: name, address
Example Response
{
"id": 6386052,
"created_at": "2018-04-19T20:17:51.220-04:00",
"updated_at": "2018-04-19T20:17:51.220-04:00",
"address": "New York City",
"phone": null,
"name": "The Central Store",
"latitude": null,
"longitude": null,
"user_id": 2121,
"url": null,
"email": null,
"description": null,
"tier": null,
"category": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"image_url": null,
"custom_marker_url": null,
"last_geocoded_by": null,
"last_geocoded_on": null,
"long_google_place_id": null,
"long_formatted_address": null,
"hidden": false
}
Query Stores
GET https://www.storemapper.co/api/v3/stores/query
Stores can be queried by partial name and address
Example
curl https://www.storemapper.co/api/v3/stores/query \
-u e165ba2c55ba47c8c3ab4a9ecabad247: \
-d name="Central" \
-d address="New York" \
-X GET
Valid Arguments
name, address
Example Response
[
{
"id": 6386052,
"created_at": "2018-04-19T20:17:51.220-04:00",
"updated_at": "2018-04-19T20:17:51.220-04:00",
"address": "New York City",
"phone": null,
"name": "The Central Store",
"latitude": null,
"longitude": null,
"user_id": 2121,
"url": null,
"email": null,
"description": null,
"tier": null,
"category": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"image_url": null,
"custom_marker_url": null,
"last_geocoded_by": null,
"last_geocoded_on": null,
"long_google_place_id": null,
"long_formatted_address": null,
"hidden": false
}
]
Update A Store
PUT https://www.storemapper.co/api/v3/stores/:id
By using the store :id, you can update a store using the same set arguments as creation. Get the store id by querying the store.
Example
curl https://www.storemapper.co/api/v3/stores/6386052 \
-u e165ba2c55ba47c8c3ab4a9ecabad247: \
-d name="The Middle Store" \
-d address="New York, United States" \
-X PUT \
Valid Arguments
name, address, phone, email, url, description, category,
custom_field_1, custom_field_2, custom_field_3, image_url, custom_marker_url,
latitude, longitude, hidden(true/false), tier
Mandatory: name, address
Example Response
{
"id": 6386052,
"created_at": "2018-04-19T20:17:51.220-04:00",
"updated_at": "2018-04-19T21:39:51.994-04:00",
"address": "New York, United States",
"phone": null,
"name": "The Middle Store",
"latitude": null,
"longitude": null,
"user_id": 2121,
"url": null,
"email": null,
"description": null,
"tier": null,
"category": null,
"custom_field_1": null,
"custom_field_2": null,
"custom_field_3": null,
"image_url": null,
"custom_marker_url": null,
"last_geocoded_by": null,
"last_geocoded_on": null,
"long_google_place_id": null,
"long_formatted_address": null,
"hidden": false
}
Delete A Store
You can also delete a store by specifying it’s id
Example
curl https://www.storemapper.co/api/v3/stores/6386052 \
-u e165ba2c55ba47c8c3ab4a9ecabad247: \
-X DELETE \
Response will be empty with 204 status