Public & Admin API

Chobble Tickets has two APIs, ways for other software to talk to your site. The public API lets any website read your listings and availability and make bookings without a key, and the admin API lets a program holding a key manage the site.

Build what you need

The public API is switched off until the owner turns it on in the advanced settings. Once on, it answers five kinds of request without a key: the list of listings, one listing, the dates with places left on a listing, a package, and a booking for a listing or package. Requests and answers are in JSON, a plain-text data format most programming languages read.

This means you can build your own event listing page on your existing website, create a custom booking flow, or pull event data into any system that can make HTTP requests.

Keys for the admin API

A key stands in for you, so another system can read and change what you sell without anybody signing in. The site shows the key once, when it is made, and from then on you see only the name you gave it.

Anyone holding the key can do what you can do, so keep it on a server you control rather than in the code a browser downloads. A page on your own website should read the public endpoints, which need no key.

Chobble Tickets does not store the key. It stores a scrambled version it can check a key against, the same way it stores passwords, so a copy of the database does not hand anybody your key. You can take one back at any moment.

A screenshot of the API keys page, listing a key named Shopfront that has never been used, above the form for making another
The list names each key the owner has handed out, and never shows the key itself. (src)

What the admin API can do

The admin API lists, creates, changes and removes listings, groups, holidays and listing options, takes listings off sale and back on, and reads a listing's attendees.

Example

A web designer builds a custom calendar for a dance school's own website. The page calls GET /api/listings to show the term's classes and /api/listings/:slug/availability to grey out full dates, then sends a booking to /api/listings/:slug/book. A booking made this way follows the same capacity rules as one made on the booking site, and the published API booking tests check that a stay booked through the API holds every day it covers.

Limits

The public API cannot read attendees, income or settings, which need the admin API and a key. Building on either API takes a developer, so organisers without one can use the embed codes below instead.

Embeddable widget

If you don't want to build a custom integration, Chobble Tickets also includes an embeddable iframe widget. Drop a snippet of HTML into your website and your events appear inline.

Check the embed documentation for widget setup, and the full API documentation for endpoint details.