This documentation provides an overview of twinzo's Public REST API endpoint, including API endpoint details, API key information, timestamping data, timezone considerations, and versioning information. With this information, developers can effectively integrate third-party data sources with Twinzo's API endpoint.
API Endpoint Details:
Swagger definition: https://api.platform.twinzo.eu/swagger/ui/index
LTS API Version: 3.0
🔗 Domains
Enterprise - for business customers (logged before self-onboarding)
Platform - self-onboarded customers
APP | Enterprise | Platform | ||
---|---|---|---|---|
Portal | ||||
API | Signup |
🔑 API Key
API keys are required for third-party software systems to authorize the twinzo API. Registered clients can request an API key from Twinzo to enable access to the API endpoint.
⏲️ Timestamping Data
Twinzo's system uses Unix timestamps in milliseconds to identify the timestamps of records. Developers can refer to the following resources for more information on Unix timestamps:
Info |
---|
Timezone:Each branch has its own timezone, and records should be sent to the server in the GMT adjusted according to the specific timezone of the client device. Developers should take note of the timezone of the client device and adjust records accordingly. |
🔢 Versioning
Please select version 3 in the header, as it has long-term support. The Swagger UI of version 3 is available at the following URL: https://api.platform.twinzo.eu/swagger/ui/index
📖 Open Data Options
For some requests, twinzo's Public REST API offers to get much more information about the subject using Open data options.
More information about Open Data Options is here https://learn.microsoft.com/en-us/odata/concepts/queryoptions-overview.
How to use Open Data Options
At the end of your Request URL add $expand=RequiredData
Code Block |
---|
https://api.twinzo.eu/v3.0/sectors/14?$expand=RequiredData |
Example
Below is an example where you get beacons data within sector requests.
Code Block |
---|
https://api.twinzo.eu/v3.0/sectors/14?$expand=Beacons |
Without $expand=Beacons
Code Block |
---|
{ "Id": 14, "Guid": "9aa01f37-5261-4ad2-b0d7-e24ee7c00495", "BranchId": 7, "Title": "1. floor", "BarrierHeight": 1046.15381, "BarrierWidth": 1089.65515, "SectorWidth": 31600.0, "SectorHeight": 13600.0, "Modified": 1676545627755, "GpsItems": [ ], "Areas": [ ], "Barriers": [ ], "Beacons": [ ], "Sensors": [ ], "Paths": [ ] } |
With $expand=Beacons
Code Block | ||
---|---|---|
| ||
{ "Id": 14, "Guid": "9aa01f37-5261-4ad2-b0d7-e24ee7c00495", "BranchId": 7, "Title": "1. floor", "BarrierHeight": 1046.15381, "BarrierWidth": 1089.65515, "SectorWidth": 31600.0, "SectorHeight": 13600.0, "Modified": 1676545627755, "GpsItems": [ ], "Areas": [ ], "Barriers": [ ], "Beacons": [ { "Id": 33, "SectorId": 14, "BranchId": 7, "Mac": "C2:92:1B:23:75:DB", "X": 5268.888, "Y": 8728.265, "Title": "1456", "Active": true, "TypeId": 23, "Position": true, "Geofence": false, "Cluster": "", "LastTimeOnline": 1684749465550, "UseGps": false }, { "Id": 78, "SectorId": 14, "BranchId": 7, "Mac": "EE:0F:A1:CE:EA:78", "X": 12557.7129, "Y": 1698.99536, "Z": 0.0, "Title": "1743", "Active": true, "TypeId": 23, "Position": true, "Geofence": false, "LastTimeOnline": 1684749387727, "UseGps": false } ], "Sensors": [ ], "Paths": [ ] } |