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.
Devices API
print icon
Devices API

There are two methods available for devices :

  1. List all devices
  2. Return full detail on a single device
List all devices

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

Verb: GET

Example Call: https://api.myposconnect.com/api/v2/devices?filt_LastEditDateUTC_dt_min=2022-jan-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 Devices. For other possible (more general) return codes please see API Build Basics

Important: This call returns a restricted flat view of the Devices table. The JSON objects in the array are not full Devices 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 device 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_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_storeid_guid GUID of Store (StoreId) can be obtained by calling the Stores API Call

filt_XXXXXXX_XXX

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

Return full detail on a single device by Device Identifier DeviceId

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

Verb: GET

Example Call: https://api.myposconnect.com/api/v2/devices/72f0ba34-e233-4165-95d0-99b0b45364c3

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

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

Example JSON Object
Single Device

{
       "deviceId": "4ead37c0-e7aa-414d-8d05-d45a515a213f",
       "deviceCode": "1001",
       "deviceName": "Till 1",
       "devicePrefix": "1001",
       "active": true,
       "storeId": "67fcefb2-fcaf-4424-98fa-7768e7025825",
       "printer1": true,
       "printer2": true,
       "printer3": true,
       "printer4": true,
       "printer5": true,
       "printer6": true,
       "printer7": true,
       "printer8": true,
       "printer9": true,
       "printer10": true,
       "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",
       "creationUser": "User Name",
       "lastEditDevice": "PC99",
       "creationDevice": "PC99",
       "lastEditDate": "2022-09-18T15:42:37.457",
       "creationDate": "2022-02-05T06:51:21.52"
}

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 Devices.

Feedback
0 out of 0 found this helpful

scroll to top icon