Tiquo
API and AuthenticationClient API

List Bookings

Retrieve the authenticated customer's booking history

List Bookings

Returns a paginated list of bookings for the authenticated customer.

Endpoint

GET /bookings

Authentication

Requires a valid JWT access token.

Authorization: Bearer eyJhbGciOiJSUzI1NiJ9...

Query Parameters

ParameterTypeDefaultDescription
limitinteger50Number of bookings to return (1 to 100)
cursorstring-Booking ID to paginate from
statusstring-Filter by booking status
upcomingbooleanfalseWhen true, only returns future bookings

Status Values

StatusDescription
pendingBooking has been submitted but not yet confirmed
confirmedBooking is confirmed
cancelledBooking was cancelled
completedBooking took place as scheduled
no_showCustomer did not show up

Example Request

curl -X GET "https://edge.tiquo.app/api/client/v1/bookings?upcoming=true&limit=10" \
  -H "Authorization: Bearer eyJhbGciOiJSUzI1NiJ9..."

Response

{
  "success": true,
  "data": {
    "bookings": [
      {
        "id": "booking_123",
        "bookingNumber": "BK-001234",
        "confirmationCode": "ABC123",
        "status": "confirmed",
        "date": 1706662800000,
        "startTime": "14:30",
        "endTime": "15:30",
        "duration": 60,
        "timezone": "America/New_York",
        "attendeeCount": 2,
        "serviceName": "Consultation",
        "serviceId": "svc_123",
        "sublocationId": "loc_456",
        "createdAt": 1706576400000
      }
    ],
    "hasMore": false
  }
}

Booking Object

FieldTypeDescription
idstringBooking document ID
bookingNumberstringHuman-readable booking number (e.g. BK-001234)
confirmationCodestringConfirmation code for the booking
statusstringBooking status (see values above)
dateintegerUnix timestamp in milliseconds for the booking date
startTimestringStart time in HH:mm format
endTimestring or nullEnd time in HH:mm format
durationinteger or nullDuration in minutes
timezonestringTimezone of the booking (e.g. America/New_York)
attendeeCountintegerNumber of attendees
serviceNamestring or nullName of the booked service
serviceIdstring or nullID of the booked service
sublocationIdstring or nullID of the sublocation
createdAtintegerUnix timestamp in milliseconds when the booking was created

Pagination

When hasMore is true, pass the last booking's id as the cursor parameter to get the next page.

Errors

StatusDescription
401Invalid or expired access token
500Internal server error

Code Examples

JavaScript

async function getBookings(accessToken, options = {}) {
  const params = new URLSearchParams();
  if (options.limit) params.set('limit', options.limit);
  if (options.cursor) params.set('cursor', options.cursor);
  if (options.status) params.set('status', options.status);
  if (options.upcoming) params.set('upcoming', 'true');

  const response = await fetch(
    `https://edge.tiquo.app/api/client/v1/bookings?${params}`,
    {
      headers: { 'Authorization': `Bearer ${accessToken}` },
    }
  );

  return response.json();
}

// Fetch upcoming bookings
const result = await getBookings(token, { upcoming: true, limit: 10 });
console.log(`You have ${result.data.bookings.length} upcoming bookings`);

Sur cette page