Skip to Content
ThrilKnowledge Base

Public API and webhooks

Your own systems read reservations, service bookings, customers, payments and events from Thril into a CRM, a reporting tool or your website, and webhooks tell them when something changes.

Thril adds the Public API to your company on request. Contact Thril support to add it. Webhooks, including the Send webhook step in workflows, need it too.

The Thril Public API lets your own developer or an integration partner work with your company's data in Thril from your own systems. Webhooks go the other way: Thril sends your systems a message when something changes.


Uses for the API

  • Your own reporting. Pull payments and refunds into a reporting tool or a spreadsheet, and report the way your board or your accountant wants it.
  • Bookings tied to your marketing. Read which campaign brought each reservation, registration and purchase: the UTM parameters on your own links, the ad click and the website the customer came from. This needs campaign tracking.
  • A CRM that stays up to date. Read your customers and their memberships. Webhooks tell the CRM when a new customer joins, when a membership is assigned and when one is about to expire.
  • Your schedule on your own website. Show your events, courses, tournaments and free times from Thril on a website you run yourself.
  • Seasons booked from another system. A club or a school system books a weekly recurring reservation for a whole season at the price you agreed.
  • Gift cards and promo codes from your own tools. Issue a free gift card as a prize or to put a complaint right, or create a promo code for a partner's campaign.
  • Prices kept in step with another system. Read and change the pricing rules of your resources.

Data and actions in the API

The API reads your venues, resources, free times and prices, reservations and recurring reservations, services and service bookings, events, courses and tournaments with their participants, customers, payments and refunds, the campaigns behind purchases and bookings, gift cards, credit products and promo codes. It can book recurring reservations, issue gift cards, create promo codes and change resource pricing rules.

Customers in the API are the people with a Thril account. Free times come as your venue sees them. A website that shows them applies your booking windows, membership rules and discounts itself. Customers make single bookings, event sign-ups and payments in Thril. Bookings, gift cards and promo codes made through the API send the customer no message, and your system delivers a gift card's code.

Your company gets one API token from Thril. It reaches every venue of your company. Treat it like a password, because whoever has it can read your customers' details. A daily request allowance applies.

Your developer finds the reference for every request and webhook at api-public.thril.fi/docs.

The same token also connects Claude, ChatGPT and other AI assistants to your data, with no developer needed. Read more on Thril in Claude, ChatGPT and other AI assistants.

Reservations and the people on them

Each reservation in the API lists its participants. The owner made the booking, a payer owes a share of a split bill, and a participant takes part without paying. For each participant you get their participation status, invited or accepted, the payment status of their share, and the price assigned to them. A participant is one of these:

  • A customer with a Thril account, with their name, email address, phone number and the marketing consent your company has recorded. The customer's user ID stays the same at every venue and every company. Your systems can use it as a stable customer ID.
  • A guest named on the booking who has no Thril account.
  • A business customer your company invoices.
  • An open place with nobody named in it.

The reservation list also holds the time that events, golf competitions, service bookings and extras take on your resources, so a door or lighting system can follow everything booked on a resource. Each reservation has a type: a customer's booking, a staff booking, a recurring series, an open game, or the time an event, a golf competition, a service booking or an extra holds. When a reservation holds a resource for an event, a competition or a service booking, the people and the price are on that event, competition or service booking.

The reservation list filters by venue, resource, type, recurring series, status, time window and customer. Filtering by a customer's user ID returns every reservation they are on, in any role. Another request fetches one reservation by its ID. The list includes cancelled reservations with the reason for the cancellation. Payments come from their own request. A payment for a reservation names that reservation. Reservations in the API carry no attendance or check-in information.

Service bookings

Each service booking in the API names the service and the duration booked, the employee who gives it, the customer or the guest who booked it, the time, the price with its discount and VAT, and whether it is paid. The list filters by venue, status, payment status, time window and customer, and it includes cancelled bookings with the reason for the cancellation. A payment for a service booking names that booking. Your services come from their own request, with the durations each one can be booked for and their prices.


Webhooks

A webhook is a message Thril sends to an address in your own system when something happens. Your developer sets up the receiving addresses with the API and chooses which changes each one gets:

  • reservations made, changed or cancelled, and recurring series made, changed or cancelled
  • a participant joining or leaving an event, and an event or a tournament cancelled
  • a new customer joining your company
  • a membership assigned to a customer, and a membership about to expire

Webhooks from workflows

The Send webhook step in a workflow tells your systems that a customer, a reservation, an invoice or a membership reached that point of the workflow. You name the event and pick the values it carries, such as the customer's email address and the membership's name. A CRM can then start its own follow-up at the same point.

On this page