You are using an unsupported browser. Please update your browser to the latest version on or before July 31, 2020.
close
You are viewing the article in preview mode. It is not live at the moment.
Stores API
print icon
Stores API

There are two methods available for stores :

  1. List all stores
  2. Return full detail on a single store
List all stores

End Point: https://api.myposconnect.com/api/v2/stores

Verb: GET

Example Call: https://api.myposconnect.com/api/v2/stores?filt_LastEditDateUTC_dt_min=2022-feb-01%2009%3a00&filt_LastEditDateUTC_dt_max=2022-dec-31%2009%3a00

Return Codes: 200 for success, with the body containing the JSON for the Stores. For other possible (more general) return codes please see API Build Basics

Important: This call returns a restricted flat view of the Stores. The JSON objects in the array are not full Stores JSON objects as shown in the appendices of this document. If some of the deeper information is required then you will need to use the method for getting a single store object. There are several query string arguments that can be used with this call as follows (you may need to URL encode your argument values).

Filters: 

filt_active_bool Optional field to show active or inactive stores only, must be "true" or "false" (or omitted which means you get both true and false in results)
filt_LastEditDate_dt_min Optional  DateTime String (yyyy-MMM-dd HH:mm) – use to filter results by the “LastEditDate” property. Example value of “2020-oct-06 11:10” would be URL encoded to “2020-oct-06%2011%3a10”.
filt_LastEditDate_dt_max  Optional UTC DateTime String (yyyy-MMM-dd HH:mm) – use to filter results by the “LastEditDate” property.

filt_LastEditDateUTC_dt_min

Optional UTC DateTime String (yyyy-MMM-dd HH:mm) – use to filter results by the “LastEditDateUTC” property. Example value of “2020-oct-06 11:10” would be URL encoded to “2020-oct-06%2011%3a10”.

filt_LastEditDateUTC_dt_max

Optional UTC DateTime String (yyyy-MMM-dd HH:mm) – use to filter results by the “LastEditDateUTC” property.

filt_XXXXXXX_XXX

Other filtering query string arguments may be available for development if requested, please let us know at [email protected].

Return full detail on a single store by Store Identifier StoreId

End Point: https://api.myposconnect.com/api/v2/stores/{identifier}

Verb: GET

Example Call: https://api.myposconnect.com/api/v2/stores/67fcefb2-fcaf-4424-98fa-7768e7025825

Return Codes: 200 for success, with the body containing the JSON for the Store. For other possible (more general) return codes please see API Build Basics

Important: This call returns a view of a single Store and related fields including related devices and custom fields tailored for individual MYPOS clients. 

Example JSON Object
Single Store

{
       "storeId": "67fcefb2-fcaf-4424-98fa-7768e7025825",
       "storeCode": "1",
       "storeName": "Rustington Office",
       "address": "1 Main Street",
       "city": "Rustington",
       "region": "West Sussex",
       "postalCode": "BN99 9AB",
       "country": "United Kingdom",
       "phoneNumber": "0845 555 1234",
       "faxNumber": "",
       "emailAddress": "[email protected]",
       "webSite": "www.website.com",
       "taxRateId": "3402d8fd-6362-e311-bb77-d4ae52b94eec",
       "vatTaxRateId": "3402d8fd-6362-e311-bb77-d4ae52b94eec",
       "active": true,
       "readOnlyDevices": [
          {
            "deviceId": "1c9f898c-ed42-408c-88b8-ed24a6fa8eb4",
            "deviceCode": "50",
            "deviceName": "PC 50"
          },
          {
            "deviceId": "1c9f898c-ed42-408c-88b8-ed14a6fa9eb4",
            "deviceCode": "99",
            "deviceName": "PC 99"
          },
       ],
"cC_001": null,
"cC_002": null,
"cC_003": null,
"cC_004": null,
"cC_005": null,
"cC_006": null,
"cC_007": null,
"cC_008": null,
"cC_009": null,
"cC_010": null,
"lastEditUser": "User name here",
"creationUser": "User name here",
"lastEditDevice": "123456",
"creationDevice": "123456",
"lastEditDate": "2022-03-08T07:05:25.44",
"creationDate": "2021-02-28T09:38:28.207"
}

Troubleshooting Ideas

As with all API connections, you will need to have acquired a bearer token and the user that acquired the token will need to be assigned access permission to this table. If you are not receiving any results send the full endpoint together with any filters and the API user to us from a valid email address and we can advise if permissions have been authorised. You might be able to see data with one table and not another if specific permissions are not applied. Check your filter dates if collecting all stores.

Feedback
0 out of 0 found this helpful

scroll to top icon