Getting Started

Intro

We enable partners to have their classes booked by our users. Usually, in order to register classes and update their schedule when a user books a class, a partner has to access our Partners’ Portal. But with Booking API it’s possible to add classes’ schedules on the Wellhub app and website, enabling users to book such classes directly from there, updating the partner’s own schedule automatically.

The regular flow is:

text

With our Booking API, you can leverage a seamless flow integrating your class system with ours, allowing an easier and integrated process for booking:

It allows an easier and more integrated process:

text

Quick Start Guide

Available at this Postman documentation.

Authentication

Wellhub Authentication Token

The Wellhub API authentication process utilizes one token for both our Access Control and Booking APIs.

This gives you the ability to have one authentication credential stored in your code that will permit access to all of our APIs.

Wellhub will provide you with the Authentication Token which will be used as the Authorization Bearer Token for authentication when calling our Booking API integration.

The below table illustrates which integration type will use which authentication method with the Wellhub Authentication Token.

Authentication methods

IntegrationAuth MethodToken
BookingAuthorization BearerWellhub Auth Token

Authentication Token

NameDescription
Wellhub Authentication TokenBearer Token provided to you to authenticate yourself when calling either the Wellhub Access Control or Booking API

Booking Integration example

Request example
1curl --location --request POST '{{booking-api-url}}/booking/v1/gyms/1/classes' \
2--header 'Content-Type: application/json' \
3--header 'Authorization: Bearer {{Wellhub Auth Token}}' \
4--data-raw '{

Booking API

Once you create classes on your system, Wellhub receives the information via Booking API, doing all the work only once and maintaining the information synchronized between applications.

Webhooks

The Wellhub webhooks will notify you when specific events are triggered. These notifications are HTTP POST requests to your registered URL. When a Wellhub user books a class or cancels the booking, we emit an event to the registered webhook. If it is a booking request, you should have 15 minutes to send a PATCH with the desired booking status, otherwise, the request will be automatically rejected.

Environments

Production: https://api.partners.gympass.com