Document toolboxDocument toolbox

Shifts Data

This guide describes how to integrate and send shifts data to twinzo's REST API.

Configuration

To connect sensor values with 3D spaces, visit this course page:

The main information about how to use twinzo´s REST API and how to authorize your access:

Swagger Shift Section

image-20240820-054726.png

The Swagger Shift section provides a detailed description of the API for shift data. There are two main endpoints in the Shift section for send or update data:

POST /shifts/

  • Used to create a new shift

PATCH /shifts/{id}

  • Used to update shift

Example

  • POST Shifts create a new shift

  • PATCH Shifts update already exists shift

POST Shifts

[ { "Id": 1, "Title": "Morning Shift", "BranchId": 1, "StartTime": 21600000, "StopTime": 50400000 } ]
image-20240820-061827.png

PATCH Shifts

[ { "StopTime": 60400000 } ]

Data Properties

Data payload JSON object has five properties:

Id

Shift ID

Title

Shift´s title

BranchId

Branch ID where the shift will be used

StartTime

Start time of the shift [in miliseconds]

StopTime

End time of the shift [in miliseconds]

StartTime / StopTime explanation:

60000 - 00:01 (12:01 AM)
21600000 - 06:00 (6:00 AM)
79200000 - 22:00 (10:00 PM)
108000000 - 06:00 (6:00 AM) - NEXT DAY! - Used for night shifts that last from the evening until the next morning

If you encounter any issues or need assistance with using this product, please do not hesitate to reach out for support. Our team is here to help you resolve any problems and answer any questions you may have.
To create a support ticket, visit our support portal at https://partner.twinzo.eu/helpdesk/customer-care-1