Create or update a ticket
POST {baseUrl}/queues/{queueId}/join
Creates or updates a ticket and returns its information. This function sends information about the ticket to the client (device) associated with the provided session ID.
Body Parameters:
Name | Type | Requirement | Description |
---|---|---|---|
session | guid | required | Device session information. Can be a random guid if not relevant. |
position | object | optional | Ticket information which may include customer info, tags, and an id if updating an existing ticket. |
Position Parameters Details:
Name | Type | Requirement | Description |
---|---|---|---|
id | guid | optional | Specify for updates. |
customerInfo | string[] | optional | Example: ["Name", "Surname", "ID Number"] |
tags | Tag[] | optional | See Tag structure below. |
Tag Structure:
Field | Type | Requirement | Description |
---|---|---|---|
id | guid | required | Unique identifier for the tag. |
iconUrl | string | optional | URL of the tag's icon. |
color | string | optional | Color of the tag. |
title | object | required | Title object with language codes as keys and corresponding strings as values. |
Authentication:
ApiKey header is required for authentication.
Request:
curl --location --request POST '{baseUrl}/queues/{queueId}/join' \
--header 'ApiKey: XYZ' \
--header 'Content-Type: application/json' \
--data-raw '{
"session": "foo",
"position": {
"id": "5387920d-dfdd-4904-8a51-3f007effcffa",
"customerInfo": [
"Jörgen",
"Svensson",
"123456"
],
"tags": [
{
"id": "3143d93f-643c-4e29-92e8-5af7b25b8c38",
"iconUrl": "https://media.omborigrid.com/media/5f55d979ce0cbb6d30c92c3e/27f54990-0f11-11ec-85ff-7bd005db4d31",
"color": "#987931",
"title": {
"en": "G"
}
}
],
}
}'
Response:
{
"positionUrl": "",
"position": {
"status": "pending",
"priority": 0,
"location": null,
"label": "A3",
"customerInfo": [
"Jörgen",
"Svensson",
"12345"
],
"tags": [
{
"id": "3143d93f-643c-4e29-92e8-5af7b25b8c38",
"iconUrl": "https://media.omborigrid.com/media/5f55d979ce0cbb6d30c92c3e/27f54990-0f11-11ec-85ff-7bd005db4d31",
"color": "#987931",
"title": {
"en": "G"
}
}
],
"id": "5387920d-dfdd-4904-8a51-3f007effcffa",
"type": "anonymous",
"queue": "c179a3a2-9fd7-4e12-96e7-19d9e957e094",
"createdAt": "2020-11-17T11:45:57.114Z",
"numberInTheQueue": 6
}
}