Document toolboxDocument toolbox

Basics

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:

Domains

Enterprise - for business customers (logged before self-onboarding)

Platform - self-onboarded customers

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.

https://twinzo.atlassian.net/wiki/spaces/PUBD/pages/53805121

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:

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:

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 .

How to use Open Data Options

At the end of your Request URL add $expand=RequiredData

https://api.twinzo.eu/v3.0/sectors/14?$expand=RequiredData

Example

Below is an example where you get beacons data within sector requests.

https://api.twinzo.eu/v3.0/sectors/14?$expand=Beacons

Without $expand=Beacons

{ "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