Create Booking

This endpoint is used to create a booking within Tyro Connect. This call will create a booking in the POS system.

The id that is returned as a part of the response should be used to identify the booking for subsequent events or retrieving the details via the GET endpoint.

Request
Security:
header Parameters
Authorization
required
string
Default: Bearer {$$.env.access_token}
Accept
required
string (acceptHeaderBooking1_0)
Default: application/vnd.tyro.connect+json;version=0.1

Specifies which version of the API to use. If no value is provided then 0.1 version will be used

Enum: "application/vnd.tyro.connect+json;version=1.0" "application/vnd.tyro.connect+json;version=0.1"
Content-Type
required
string
Value: "application/json"
Request Body schema: application/vnd.tyro.connect+json;version=1.0
locationId
required
string

The id of the location as specified by the Tyro Connect system.

object

Information relevant to the booking partner that this booking was created with

bookingStatus
string (bookingStatus)

The current status of the booking

Enum: "CREATED" "ACCEPTED" "CANCELLED_BY_CUSTOMER" "CANCELLED_BY_MERCHANT" "REJECTED"
numberOfPeople
required
number (numberOfPeople) >= 1

The number of expected guests

Array of objects (payments)

A list of payments applied to the booking.

startTime
required
string <date-time>

The date and time the booking starts at the venue. The format of the date time is the notation as defined by RFC 3339, section 5.6

endTime
string <date-time>

The date and time the booking ends at the venue. The format of the date time is the notation as defined by RFC 3339, section 5.6

object (customer)

The customer making the booking

notes
string [ 1 .. 500 ] characters

Notes specific to the booking. Example: 'Window seat please'

required
roomAsset (object) or tableAsset (object)

Contains asset information of the booking

Responses
201

Created

400

When the provided payload is not valid.

403

When you don't have the right permissions to seat a booking for the provided location.

post/bookings
Request samples
application/vnd.tyro.connect+json;version=1.0
{
  • "locationId": "merchant:abc123",
  • "origin": {
    },
  • "asset": {
    },
  • "numberOfPeople": 2,
  • "startTime": "2020-03-01T18:00:00Z",
  • "bookingStatus": "CREATED"
}
Response samples
application/vnd.tyro.connect+json;version=1.0
{
  • "id": "2688fcf2-44dd-4c72-88ac-79d0910f2983",
  • "locationId": "merchant:abc123",
  • "bookingStatus": "CREATED",
  • "origin": {
    },
  • "asset": {
    },
  • "numberOfPeople": 2,
  • "payments": [
    ],
  • "startTime": "2020-03-01T18:00:00Z"
}
Copyright © Tyro Payments 2019-2024. All right reserved.