Skip to main content

Lineberty Booking API (2.0.0)

Download OpenAPI specification:Download

Lineberty Developer Support: contact@lineberty.com URL: https://www.lineberty.com

About Lineberty

Lineberty, the solution that queues up for your customers. Lineberty's Booking System increases Users' satisfaction by reducing the time spent waiting for their turn.

Users simply have to book a ticket, either on their phone using your application, or on a terminal you're providing at your place, then to select the time when they want to enjoy visiting your place or use your service. They receive a notification shortly before their appointment, informing them that it is soon their turn.

There is no longer any need to wait in a line! Users now have time to visit around or make more purchases thanks to the Lineberty Virtual Queueing Solution.

About the Lineberty Booking API

Create your own Booking (web)application with the Lineberty Booking API, whether for a mobile or a terminal. Whatever the number of places (or even subplaces) managed by your company, Lineberty allows you to manage queues, tickets, appointments and users in one secured solution.

Process of Booking a ticket

Define the time slots when users can book tickets, manage the appointments, the availabilities for booking. Allow groups of users to have the same ticket, manage authorizations and eligibility. Organize your places and subplaces into categories for a more detailed management. Or even allow the users to rate and comment their visit on their ticket and that way get some valuable information!

Authentication

Your Booking application will have to communicate with the Lineberty server to get the data needed to book a ticket. This communication requires an API Key.

We will provide you with a private key included in a JSON file. This JSON file must be stored safe on your application server.

This private key also contains an email address associated to your account to access the Lineberty Booking API, and afterwards get the API Key.

See The Lineberty User Documentation for detailed information.

API KEY

The API Key secures the communication with the Lineberty Server.

GET A VALID API KEY

This is the first step before accessing the resources of the API. Use this route to get a valid API Key to access the Lineberty Booking API resources with your private key. We recommend to use API Key caching to optimize the number of requests per day and resend the request once a day.

Authorizations:
server_key_file
header Parameters
Authorization
required
string
Example: Bearer <DEVELOPER_TOKEN>

JWT token is generated on your server from your secret file.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <DEVELOPER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/api_key 

Response samples

Content type
application/json
{
  • "apiKey": "QJ15bv43hKXTpVClbyMnofYOXHZdyb2Lxwv8yEpzrV1laO"
}

USERS

Use these routes to manage the application users (creation, login, authentication).

CREATE A USER

Use this route to create a Lineberty user, who will be able to book a ticket. It returns a JWT token.

Authorizations:
server_key_file
header Parameters
Authorization
required
string
Example: Bearer <DEVELOPER_TOKEN>

JWT token is generated on your server from your secret file.

Responses

Request samples

curl -X POST \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <DEVELOPER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/users 

Response samples

Content type
application/json
{
  • "jwtToken": "QJ15bv43hKXTpVClbyMnofYOXHZdyb2Lxwv8yEpzrV1laO"
}

LOGIN A USER

Use this route to log a user with her/his user ID.

Authorizations:
server_key_file
path Parameters
userId
required
string

The user's ID.

header Parameters
Authorization
required
string
Example: Bearer <DEVELOPER_TOKEN>

JWT token is generated on your server from your secret file.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <DEVELOPER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/users/{userId}/login 

Response samples

Content type
application/json
{
  • "jwtToken": "QJ15bv43hKXTpVClbyMnofYOXHZdyb2Lxwv8yEpzrV1laO"
}

REFRESH THE SESSION TOKEN

Use this route to refresh the user's session token, using the user ID and the session ID.

Authorizations:
server_key_file
path Parameters
userId
required
string

The user's ID.

sessionId
required
string

The ID of the session.

header Parameters
Authorization
required
string
Example: Bearer <DEVELOPER_TOKEN>

JWT token is generated on your server from your secret file.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <DEVELOPER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/users/{userId}/session/{sessionId}/refreshToken 

Response samples

Content type
application/json
{
  • "jwtToken": "QJ15bv43hKXTpVClbyMnofYOXHZdyb2Lxwv8yEpzrV1laO"
}

COMPANIES

Use these routes to get the list of the companies, and for each company the places relating to it.

GET THE LIST OF COMPANIES

Use this route to get the list of all the companies that are associated with the API key, and their languages.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

companiesId
Array of strings

An array of company IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/companies?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "companyId1": {
    }
}

GET DETAILED INFORMATION ON PLACES

Use this route to get detailed information on the places of a company, using the company ID.

Authorizations:
api_key
path Parameters
companyId
required
string

The ID of the company.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

placesId
Array of strings

An array of place IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/companies/{companyId}/places?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "placeId1": {
    },
  • "placeId2": {
    }
}

PLACES

Use these routes to get the list of the places, and for each place the subplaces, categories and queues relating to it.

GET THE LIST OF PLACES

Use this route to get all the places relating to a company, including information on the language and the GPS position.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

placesId
Array of strings

An array of place IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "placeId1": {
    },
  • "placeId2": {
    }
}

GET DETAILED INFORMATION ON A PLACE

Use this route to get detailed information on a place in particular, using its ID. It includes the language and the GPS position.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "placeId": "placeId1",
  • "companyId": "companyId1",
  • "name": {
    },
  • "address": "5 Avenue Anatole France",
  • "city": "Paris",
  • "country": "France",
  • "zip": "75007",
  • "language": "fr_FR",
  • "timezone": "Europe/Paris",
  • "position": {
    },
  • "distance": 2133,
  • "subplaces": { },
  • "categories": { }
}

GET THE SUBPLACES OF A PLACE

Use this route to get the list of the subplaces relating to a place, including their languages.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

subplacesId
Array of strings

An array of subplace IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}/subplaces?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "subPlaceId1": {
    },
  • "subPlaceId2": {
    }
}

GET THE CATEGORIES OF THE PLACE

Places can be organized into categories. Use this route to get the categories of a place.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

categoriesId
Array of strings

An array of category IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}/categories?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "categoryId1": {
    },
  • "categoryId2": {
    }
}

GET THE QUEUES OF THE PLACE

Use this route to get the list of the queues relating to a place in particular, including detailed information.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

queuesId
Array of strings

An array of queue IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}/queues?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

GET THE COUNTER(S) OF A PLACE

Use this route to get the counter(s) of a place.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

countersId
Array of strings

An array of counter IDs (actually, queue IDs) that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}/counters?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "counterId1": {
    },
  • "counterId2": {
    }
}

SUB-PLACES

Use these routes to get a subplace, and the queues and categories relating to it.

GET THE SUBPLACE

Use this route to get a subplace using its ID.

Authorizations:
api_key
path Parameters
subplaceId
required
string

The ID of the subplace.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/subplaces/{subplaceId}?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "subPlaceId": "subPlaceId1",
  • "placeId": "placeId1",
  • "name": {
    },
  • "categories": {
    }
}

GET THE QUEUES OF A SUBPLACE

Use this route to get the queues of a subplace, and information on the language and the GPS position.

Authorizations:
api_key
path Parameters
subplaceId
required
string

The ID of the subplace.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

queuesId
Array of strings

An array of queue IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/subplaces/{subplaceId}/queues?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

GET THE CATEGORIES OF A SUBPLACE

Some subplaces are organized into categories. Use this route to get the categories of a place in particular.

Authorizations:
api_key
path Parameters
subplaceId
required
string

The ID of the subplace.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

categoriesId
Array of strings

An array of category IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/subplaces/{subplaceId}/categories?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "categoryId1": {
    },
  • "categoryId2": {
    }
}

QUEUES

Use these routes to get the list of the queues, or a queue in particular and its configuration.

GET ALL QUEUES

Use this route to get the list of the queues that are associated with the API Key, including language and position.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

queuesId
Array of strings

An array of queue IDs that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

GET THE QUEUE

Use this route to get a queue in particular, using its ID. It includes the language and the GPS position.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

lat
number
Example: lat=48.1234

A latitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

lng
number
Example: lng=2.1234

A longitude, at least 4 decimal digits. If both lat & lng are passed, the places will contain the distance field.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

detailsLevel
number
Example: detailsLevel=10

Field to activate more details in response, like availabilityType example.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}?key=YOUR_API_KEY&lat=48.1234&lng=2.1234&langs=fr_FR,en_US&detailsLevel=10 

Response samples

Content type
application/json
{
  • "queueId": "queueId1",
  • "placeId": "placeId1",
  • "companyId": "companyId1",
  • "categoryId": "",
  • "subPlaceId": "",
  • "name": {
    },
  • "language": "fr_FR",
  • "timezone": "Europe/Paris",
  • "position": {
    },
  • "distance": 2133,
  • "config": {
    },
  • "appointmentTypes": {
    }
}

GET THE CONFIGURATION OF THE QUEUE

Use this route to get the configuration of a queue in particular, using its ID. It includes the booking type as well as the lower and upper limits of the group size.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/config?key=YOUR_API_KEY 

Response samples

Content type
application/json
{
  • "bookingType": "FIRST_AVAILABLE_TIMESLOT",
  • "distanceEligibility": 1500,
  • "postponeEnabled": false,
  • "cancelEnabled": true,
  • "groupSizeLimit": {
    },
  • "mustAskToSendSms": false,
  • "mustAskToSendMail": false,
  • "mustAskToSendPush": false,
  • "phoneRequired": true,
  • "mailRequired": true,
  • "gpsRequired": true,
  • "availabilityType": {
    },
  • "extendedAttributes": {
    }
}

QUEUE INFORMATION

Use these routes to manage queues (eligiblity, state and availabilities).

CHECK THE ELIGIBILITY OF A LIST OF QUEUES

Use this route to check the eligibility of a list of queues concerning the GPS, limitations on ticket, and the state of the queue.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
string
Example: Bearer <USER_TOKEN>

Adding the user's JWT token allows you to get a more specific response. You get the user's JWT token from /createUser.

Request Body schema: application/json
required

All the data to get information on the eligibility.

queuesId
required
Array of strings

An array of queue IDs.

object (GpsPosition)

Position

Responses

Request samples

Content type
application/json
{
  • "queuesId": [
    ],
  • "position": {
    }
}

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

CHECK THE STATE OF THE QUEUES

Use this route to get information on the current state of the queues (whether open or closed, full, etc.).

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

Request Body schema:
required

All the data to get state information.

queuesId
required
Array of strings

An array of queue IDs (required).

Responses

Request samples

Content type
{
  • "queuesId": [
    ]
}

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

GET THE STATE OF THE QUEUES BY SSE

Use this route to get real-time information on the current state of the queues (whether opened or closed, full, etc.) each time an event occurs.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

queuesId
required
Array of strings

An array of queue IDs.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/state/sse?key=YOUR_API_KEY 

CHECK THE STATE AND THE ELIGIBILITY OF THE QUEUES

Use this route to get the current state of the queues and their eligibility in one request.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
string
Example: Bearer <USER_TOKEN>

Adding the user's JWT token allows you to get a more specific response. You get the user's JWT token from /createUser.

Request Body schema:
required

All the data needed to get information on the eligibility.

queuesId
required
Array of strings

An array of queue IDs.

object (GpsPosition)

Position

Responses

Request samples

Content type
{
  • "queuesId": [
    ],
  • "position": {
    }
}

Response samples

Content type
application/json
{
  • "queueId1": {
    },
  • "queueId2": {
    }
}

GET THE STATE OF THE QUEUES OF A PLACE BY SSE

Use this route to get real-time information on the current state of the queues (whether opened or closed, full, etc.) each time an event occurs.

Authorizations:
api_key
path Parameters
placeId
required
string

The ID of the place.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/places/{placeId}/queuesStates/sse?key=YOUR_API_KEY 

GET THE DAYS THAT CONTAIN THE AVAILABILITIES OF A QUEUE

Use this route to book a ticket for a distant day by getting the list of days having availabilities. It lists all the days inside a time range that have at least one availability, for a given queue.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

start
string
Example: start=2022-01-01T12:00:00.000Z

The start date of the period (ISO-8601) to filter. Leave empty to not restrict the period.

end
string
Example: end=2022-01-02T12:00:00.000Z

The end date of the period (ISO-8601) to filter. Leave empty to restrict the period or to use the latest available date.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/daysWithAvailabilities?key=YOUR_API_KEY 

Response samples

Content type
application/json
{
  • "2022/01/22": {
    },
  • "2022/01/23": {
    }
}

GET THE AVAILABILITIES OF A QUEUE

Use this route to get the availabilities for a queue.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

start
string
Example: start=2022-01-01T12:00:00.000Z

The start date of the period (ISO-8601) to filter. Leave empty to not restrict the period.

end
string
Example: end=2022-01-02T12:00:00.000Z

The end date of the period (ISO-8601) to filter. Leave empty to restrict the period or to use the latest available date.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/availabilities?key=YOUR_API_KEY 

Response samples

Content type
application/json
{
  • "fifo": [
    ],
  • "appointment": [
    ]
}

GET THE AVAILABILITIES OF A QUEUE BY SSE

Use this route to get real-time information on the availabilities of a queue, each time an event occurs.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

start
string
Example: start=2022-01-01T12:00:00.000Z

The start date of the period (ISO-8601) to filter. Leave empty to not restrict the period.

end
string
Example: end=2022-01-02T12:00:00.000Z

The end date of the period (ISO-8601) to filter. Leave empty to restrict the period or to use the latest available date.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/availabilities/sse?key=YOUR_API_KEY 

COUNTERS

Use these routes to get the list of the counters, and to increment or decrement the value of the counter.

GET ALL THE COUNTERS

Use this route to get all the counters that are associated with the API key.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

countersId
Array of strings

An array of counter IDs (actually, queue IDs) that will be used to filter the result.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/counters?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "counterId1": {
    },
  • "counterId2": {
    }
}

GET ALL THE COUNTERS BY SSE

Use this route to get all the counters that are incremented/decremented each time a new ticket is booked, done or canceled.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

countersId
required
Array of strings

An array of counter IDs (which are queue IDs) is required.

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/counters/sse?key=YOUR_API_KEY&langs=fr_FR,en_US 

GET THE COUNTER

Use this route to get a counter in particular, using its counter ID.

Authorizations:
api_key
path Parameters
counterId
required
string

The ID of the counter.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

langs
Array of strings
Items Enum: "fr_FR" "en_US" "es_ES" "de_DE" "zh_CN" "zh_TW" "ja_JP" "ko_KR" "th_TH"
Example: langs=fr_FR,en_US

An array of locales, used to get the translated names of the data.

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/counters/{counterId}?key=YOUR_API_KEY&langs=fr_FR,en_US 

Response samples

Content type
application/json
{
  • "counterId": "counterId1",
  • "placeId": "placeId1",
  • "companyId": "companyId1",
  • "name": {
    },
  • "language": "en_US",
  • "timezone": "Europe/Paris",
  • "infos": {
    }
}

INCREMENT THE COUNTER VALUE

Use this route to increment the counter value, using its counter ID.

Authorizations:
api_key
path Parameters
counterId
required
string

The ID of the counter.

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Request Body schema: application/json
required

The incremental value.

incrementValue
required
number

The value to add to the counter. Must be a positive number.

Responses

Request samples

Content type
application/json
{
  • "incrementValue": 2
}

Response samples

Content type
application/json
{
  • "counterId": "counterId1",
  • "placeId": "placeId1",
  • "companyId": "companyId1",
  • "name": {
    },
  • "language": "en_US",
  • "timezone": "Europe/Paris",
  • "infos": {
    }
}

TICKETS

Use these routes to manage tickets (booking, editing, rating, canceling).

BOOK A TICKET

Use this route to book a ticket for a user with her/his JWT token. See The User Documentation for detailed information on the booking process.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Request Body schema:

All the data needed to book a ticket.

appointmentTypeId
string

The ID of the appointmentType. This is optional if there is only one possible appointment type.

groupSize
number

The number of people using the same ticket. This is optional if there is only one possible group size.

bookedFor
string (IsoDate)

A date (ISO-8601).

lang
string

The user's language in i18N code.

object

Additional user information such as email, phone, and notification options.

object (GpsPosition)

Position

source
string

The type of device used to make the request, e.g. Android or IOS. Put any value you want to do statistical analyzes.

Responses

Request samples

Content type
{
  • "appointmentTypeId": "appointmentTypeId1",
  • "groupSize": 1,
  • "bookedFor": "2022-01-01T12:00:00.000Z",
  • "lang": "en_US",
  • "userData": {
    },
  • "position": {
    },
  • "source": "MOBILE_ANDROID"
}

Response samples

Content type
application/json
{
  • "ticketId": "tiketId1",
  • "label": "137",
  • "queue": {
    },
  • "place": {
    },
  • "userId": "userId1",
  • "appointmentType": {
    },
  • "state": 0,
  • "isAnAppointment": false,
  • "groupSize": 1,
  • "duration": 600000,
  • "ticketPosition": {
    },
  • "recalledCount": 0,
  • "lang": "en_US",
  • "timeline": {
    },
  • "extraInfos": {
    },
  • "endpoint": {
    },
  • "extendedAttributes": {
    }
}

BOOK A TICKET BY SSE

Use this route to book a ticket using the user's JWT token and get real-time information on her/his progress in the booking process. See The User Documentation for detailed information on the booking process.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

appointmentTypeId
string

The ID of appointmentType.

groupSize
number

The number of people using the same ticket.

bookedFor
string

The date of the appointment (ISO-8601). Leave empty to use the next time. slot.

lang
string

The user's language (code I18N).

userData_phone
string

The user's phone number.

userData_mail
string

The user's email address.

userData_pushId
string

A push ID that is required to send push notifications to the user.

userData_sendClientPush
string

If 'true', then indicates that Lineberty must notify the user by push, using the pushID.

userData_sendClientMail
string

If 'true', then indicates that Lineberty must send an email to the user.

userData_sendClientSms
string

If 'true', then indicates that Lineberty must send an SMS to the user.

position_lat
string

The latitude of the GPS position of the user.

position_lng
string

The longitude of the GPS position of the user.

source
string

The type of device used to make the request, e.g. Android or IOS. Put any value you want to do statistical analyzes.

ticketType
string

The type of ticket booked in the request, e.g. SMS, email, or other. Put any value you want to do statistical analyzes.

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/ticket/sse?key=YOUR_API_KEY 

GET A USER'S TICKET

Use this route to get all the tickets of the current user, since the user's creation date. Thus, this includes both the current and the old tickets.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

page
number >= 1
Default: 1
Example: page=1

The page number needed. 1 by default because there is at least one page.

pageSize
number [ 1 .. 50 ]
Default: 20
Example: pageSize=20

The number of items to return for each page. By default, a page contains 20 items, at least 1 and up to 50.

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/user/tickets?key=YOUR_API_KEY&page=1&pageSize=20 

Response samples

Content type
application/json
{
  • "totalCount": 2,
  • "page": 1,
  • "pageSize": 20,
  • "tickets": [
    ]
}

GET A USER'S TICKET BY SSE

Use this route to get real-time information on all the tickets of the current user each time an event occurs. All the tickets since the user's creation date are taken into account, including the current and the old tickets.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

page
number >= 1
Default: 1
Example: page=1

The page number needed. 1 by default because there is at least one page.

pageSize
number [ 1 .. 50 ]
Default: 20
Example: pageSize=20

The number of items to return for each page. By default, a page contains 20 items, at least 1 and up to 50.

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/user/tickets/sse?key=YOUR_API_KEY&page=1&pageSize=20 

SORT THE CURRENT TICKETS OF THE USER

Use this route to get all the current tickets of the user, that are not done or canceled.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/user/tickets/currents?key=YOUR_API_KEY 

Response samples

Content type
application/json
[
  • {
    },
  • {
    }
]

SORT THE OLD TICKETS OF THE USER

Use this route to get all the old tickets of the user, i.e. those that are done or canceled.

Authorizations:
api_key
query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

page
number >= 1
Default: 1
Example: page=1

The page number needed. 1 by default because there is at least one page.

pageSize
number [ 1 .. 50 ]
Default: 20
Example: pageSize=20

The number of items to return for each page. By default, a page contains 20 items, at least 1 and up to 50.

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/user/tickets/history?key=YOUR_API_KEY&page=1&pageSize=20 

Response samples

Content type
application/json
{
  • "totalCount": 2,
  • "page": 1,
  • "pageSize": 20,
  • "tickets": [
    ]
}

ACTIONS ON TICKET - CANCEL

Use this route to cancel the ticket of the current user, using the ticket ID.

Authorizations:
api_key
path Parameters
ticketId
required
string

The ID of the ticket that you want to postpone.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Responses

Request samples

curl -X PUT \ 
 -H "Content-Type: application/json" \ 
 -H "Authorization: Bearer <USER_TOKEN>" \ 
 https://api-booking.lineberty.net/v2/user/tickets/{ticketId}/cancel?key=YOUR_API_KEY 

Response samples

Content type
application/json
{
  • "ticketId": "tiketId1",
  • "label": "137",
  • "queue": {
    },
  • "place": {
    },
  • "userId": "userId1",
  • "appointmentType": {
    },
  • "state": 0,
  • "isAnAppointment": false,
  • "groupSize": 1,
  • "duration": 600000,
  • "ticketPosition": {
    },
  • "recalledCount": 0,
  • "lang": "en_US",
  • "timeline": {
    },
  • "extraInfos": {
    },
  • "endpoint": {
    },
  • "extendedAttributes": {
    }
}

ACTIONS ON TICKETS- POSTPONE

Use this route to postpone the ticket of the current user, using the ticket ID.

Authorizations:
api_key
path Parameters
ticketId
required
string

The ID of the ticket that you want to postpone.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Request Body schema:

The timestamp expressed in milliseconds. If you do not want to set a timestamp, enter -1 to take the next available time slot. For FIFO queue the only available value is -1.

postponeTo
string (IsoDate)

A date (ISO-8601).

Responses

Request samples

Content type
{
  • "postponeTo": "2022-01-01T12:00:00.000Z"
}

Response samples

Content type
application/json
{
  • "ticketId": "tiketId1",
  • "label": "137",
  • "queue": {
    },
  • "place": {
    },
  • "userId": "userId1",
  • "appointmentType": {
    },
  • "state": 0,
  • "isAnAppointment": false,
  • "groupSize": 1,
  • "duration": 600000,
  • "ticketPosition": {
    },
  • "recalledCount": 0,
  • "lang": "en_US",
  • "timeline": {
    },
  • "extraInfos": {
    },
  • "endpoint": {
    },
  • "extendedAttributes": {
    }
}

ACTIONS ON TICKET - POSTPONE BY SSE

Use this route to postpone the ticket of the current user in real-time, using the ticket ID.

Authorizations:
api_key
path Parameters
ticketId
required
string

The ID of the ticket that you want to postpone.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Request Body schema:

The timestamp expressed in milliseconds. If you do not want to set a timestamp, enter -1 to take the next available time slot. For FIFO queue the only available value is -1.

postponeTo
string (IsoDate)

A date (ISO-8601).

Responses

Request samples

Content type
{
  • "postponeTo": "2022-01-01T12:00:00.000Z"
}

ACTIONS ON TICKET - RATING

Use this route to allow the current user to rate her/his visit by putting a comment (up to 1000 characters) and a score up to 5 on her/his ticket.

Authorizations:
api_key
path Parameters
ticketId
required
string

The ID of the ticket that you want to postpone.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

header Parameters
Authorization
required
string
Example: Bearer <USER_TOKEN>

You get the user's JWT token from /createUser

Request Body schema:

All the data required to rate the visit.

comment
string

The text of the comment left by the user up to 1000 caracters. Can be empty.

score
number [ 0 .. 5 ]

The rate between 0 (included) and 5 (included). 0 is the value if the user does not want to give a score. In this case, the value will not be used to calculate the average.

Responses

Request samples

Content type
{
  • "comment": "It was a great moment!",
  • "score": 5
}

Response samples

Content type
application/json
{
  • "ticketId": "tiketId1",
  • "label": "137",
  • "queue": {
    },
  • "place": {
    },
  • "userId": "userId1",
  • "appointmentType": {
    },
  • "state": 0,
  • "isAnAppointment": false,
  • "groupSize": 1,
  • "duration": 600000,
  • "ticketPosition": {
    },
  • "recalledCount": 0,
  • "lang": "en_US",
  • "timeline": {
    },
  • "extraInfos": {
    },
  • "endpoint": {
    },
  • "extendedAttributes": {
    }
}

ENDPOINTS

Use these routes to get a list of endpoints.

GET ALL THE ENDPOINTS OF A QUEUE

Use this route to get the list of all the endpoints of the queue.

Authorizations:
api_key
path Parameters
queueId
required
string

The ID of the queue.

query Parameters
key
required
string
Example: key=YOUR_API_KEY

The API key. You get it from /api_key

Responses

Request samples

curl -X GET \ 
 -H "Content-Type: application/json" \ 
 https://api-booking.lineberty.net/v2/queues/{queueId}/endpoints?key=YOUR_API_KEY 

Response samples

Content type
application/json
{
  • "endpointId1": {
    },
  • "endpointId2": {
    },
  • "endpointId3": {
    }
}