Bookio Services Public API (1.1.0)

Download OpenAPI specification:

Introduction

This API is documented in OpenAPI format. It's still a work in progress so please let us know about any issues at dev@bookio.com.

Authentication

Token based authentication. Access to bookio API with specific channel assigned to the token.

Bearer

Provided secret API token must be sent in Authorization request header:

    Authorization: Bearer <token>
Security Scheme Type: API Key
Header parameter name: Authorization

API Key

Api keys are issued on request, there is not yet an automatic process, but will be available in the future.

Error codes

ErrorCode Description
10 Generic validation error, errors field will give more information
11 Payment error, reservation cannot be marked as paid
12 Resource not found.
20 Invalid token or missing access rights
30 There is no capacity left
40 Duplicate reservation
403 You don't have enough permissions to access this endpoint
404 Not found
409 Conflict, resource already exists
422 Validation error
666 Unspecified internal error, this will be reported to us and we will look into it shortly

Language mutations

Every request accepts parameter lang. Example: /api/v1/some-endpoint?lang=sk or /api/v1/some-endpoint?someParam=1&lang=en. Controls the language of texts. Unsupported locale will fallback to "en".

Reservations

List of reservations

Returns a list of reservations by filter.

Authorizations:
Bearer
query Parameters
email
string
Example: email=test@bookio.com

Email of the reservee.

offset
integer >= 0
Default: 0
Example: offset=50

Determines the offset within pagination.

limit
integer [ 0 .. 100 ]
Default: 100
Example: limit=50

Limits the result set.

facilityId
number <int64> (Id)
Example: facilityId=123

ID of the specified facility.

from
string <date> (Date)
Example: from=2018-06-29

Look for reservation beginning this date.

to
string <date> (Date)
Example: to=2018-06-29

Look for reservation ending this date.

Responses

Response samples

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

Course Reservations

List of reservations

Returns a list of reservations by filter.

Authorizations:
Bearer
query Parameters
email
string
Example: email=test@bookio.com

Email of the reservee.

offset
integer >= 0
Default: 0
Example: offset=50

Determines the offset within pagination.

limit
integer [ 0 .. 100 ]
Default: 100
Example: limit=50

Limits the result set.

facilityId
number <int64> (Id)
Example: facilityId=123

ID of the specified facility.

Responses

Response samples

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

Blocked Times

List of blocked times

Returns a list of reservations by filter.

Authorizations:
Bearer
query Parameters
dateFrom
string <date> (Date)
Example: dateFrom=2018-06-29

Date from.

dateTo
string <date> (Date)
Example: dateTo=2018-06-29

Date to.

offset
integer >= 0
Default: 0
Example: offset=50

Determines the offset within pagination.

limit
integer [ 0 .. 100 ]
Default: 100
Example: limit=50

Limits the result set.

facilityId
number <int64> (Id)
Example: facilityId=123

ID of the specified facility.

Responses

Response samples

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

Facility

Get active facility ids

Returns active facility ids.

Authorizations:
Bearer

Responses

Response samples

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

Get facility info

Returns information about facility.

Authorizations:
Bearer

Responses

Response samples

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

Get workers

Returns workers of specified facility.

Authorizations:
Bearer

Responses

Response samples

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

Get services

Returns services of specified facility.

Authorizations:
Bearer

Responses

Response samples

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

Loyalty System

Check customer

Checks if customer is in the loyalty system

Authorizations:
Bearer
query Parameters
email
string
Example: email=test@bookio.com

Email of the reservee.

bookioId
number <int64> (Id)
Example: bookioId=123

Unique identifier

externalId
string
Example: externalId=21312

Responses

Response samples

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

Next booking

Checks if customer has any near booking

Authorizations:
Bearer
query Parameters
email
string
Example: email=test@bookio.com

Email of the reservee.

bookioId
number <int64> (Id)
Example: bookioId=123

Unique identifier

externalId
string
Example: externalId=21312

Responses

Response samples

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

Register customer

Register customer in the loyalty system

Request Body schema: application/json
bookioId
number <int64>

Unique identifier

externalId
string

External bussiness id from external system

externalCardId
string

Loyalty Card ID from external system

name
string

Name of the customer

surname
string

Surname of the customer

phone
string

Phone of the customer

email
string

Email of the customer

Responses

Request samples

Content type
application/json
{
  • "bookioId": 123,
  • "externalId": "141512",
  • "externalCardId": "08ab382e-1162-4d35-8c5b-ab1064b1afc7",
  • "name": "Test",
  • "surname": "Testovy",
  • "phone": "+421949888777",
  • "email": "test@bookio.com"
}

Response samples

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

WebHooks

Webhook is setup to point to one API url. Operations are distinguished by type field. We are using only POST http request.

Based on the `type` field the structure of the Json will change.
All webhooks have maximum of 5 attempts (timeout, your api is down, etc ...).

Webhook functionality is issued on request, there is not yet an automatic process, but will be available in the future. Further you can find structures of the webhooks.

Create reservation Webhook

Create reservation object in webhook.

Request Body schema: application/json
type
string

Unique webhook type. This will tell you what structure to parse.

Type: create_reservation

object

Main data holder.

Request samples

Content type
application/json
{
  • "type": "create_reservation",
  • "data": {
    }
}

Edit reservation Webhook

Edit reservation object in webhook.

Request Body schema: application/json
type
string

Unique webhook type. This will tell you what structure to parse.

Type: modify_reservation

object

Main data holder.

Request samples

Content type
application/json
{
  • "type": "modify_reservation",
  • "data": {
    }
}

Cancel reservation Webhook

Cancel reservation object in webhook.

Request Body schema: application/json
type
string

Unique webhook type. This will tell you what structure to parse.

Type: cancel_reservation

object

Main data holder.

Request samples

Content type
application/json
{
  • "type": "cancel_reservation",
  • "data": {
    }
}