In the following section, you will learn about the different appointment types and how to manage a returned list via the API.

  • Appointment Status

  • Initial

    status is an appointment that is currently being entered. Holding the initial status restricts the potential for double booking.

  • Reserved

    status allows you to hold a timeslot and add the appointment details at a later date.

  • Booked

    status is once an appointment has been confirmed.

  • Cancelled

    status removes the appointment from the calendar once it has been cancelled, but will still appear in the records to be searched and edited later.

  • Rescheduled

    status indicates an appointment that has previously been rescheduled.

Initial Status

Meeting - 30 mins

Reserved Status

Meeting - 30 mins

Booked Appt

Meeting - 30 mins

Cancelled

Meeting - 30 mins

Rescheduled

Meeting - 30 mins

  • curl --request GET \
  • --url http://example.com//consumer/v1/appointments
  • |
  • [
  • {
  • "object": "list",
  • "url": "/consumer/v1/appointments",
  • "hasMore": true,
  • "count": 20,
  • "total": 148,
  • "data": [
  • {
  • "onlineBooking": "true",
  • "object": "appointment",
  • "id": "281280",
  • "locationId": "5E737C4B-379F-481D-B075-
  • 1C7CAB1AC822",
  • "calendarId": "1806",
  • "serviceId": "1695",
  • "resourceId": "4937",
  • "status": "BK",

Appointment Data

Appointment data can be pulled from specific appointments, or a list of multiple appointments filtered by properties such as a range of dates, the Customer, the Location where the appointment was booked, the Service booked or the Resource the appointment was booked with.

Pulling raw appointment data can be done in Dashboard, OnSchedJs, or via the API.

Appointments in the Dashboard

  1. Navigate to Data Logs from the main menu
  2. Search for appointments by last name or email in the search bar
  3. Filter your search by selecting the Filters option beside the search bar

Appointments via the API
Appointments can be pulled in bulk by making a GET request to /Appointments in the API. The following filters can be set in the body of the request:

{
    "locationId": "", // ID of the Location, defaults to Primary Location
  "email": "[email protected]", // Email of the Customer
  "lastname": "Mcfly", // Last name of the Customer
  "customerId": "23", // ID of the Customer
  "serviceId": "6", // ID of the Service
  "calendarId": "", // ID of of the Calendar, defaults to main
  "resourceId": "5", // ID of the Resource
  "serviceAllocationId": "234", // ID of the Service Allocation (if applicable)
    "startDate": "2021-12-25", // Beginning of the date range, defaults to first appiointment
    "endDate": "2021-12-31", // End of the date range, defaults to the end of time
    "status": "BK", // The Status of the appointment (https://docs.onsched.com/docs/appointments-overview#appointment-status)
    "bookedBy": "[email protected]", // Email of the user who booked (if booked internally) 
}

Appointments in OnSchedJs
Appointments in OnSchedJs can be pulled using a combination of three elements:

📘

Search Appointments in the OnSched Portal

Appointments can be created, searched and managed within the OnSched Portal, or use our API to return a list of appointments within your custom booking application.

Audit Trails

Every Appointment is timestamped with an audit trail of actions taken against it, and who performed each action. Upon returning a list of appointments take note of 4 audit details: createDate, bookedBy, lastModifiedOn. You can also access a full audit trail within the OnSched Portal.

{
  "object": "list",
  "url": "/consumer/v1/appointments",
  "hasMore": true,
  "count": 20,
  "total": 160,
  "data": [
    {
      "createDate": "2018-05-09T19:09:21Z",
      "bookedBy": "[email protected]",
      "lastModifiedOn": "2018-05-09T19:09:38Z",
      "lastModifiedBy": "[email protected]",
      }
    }

Booking Timer & Expiration

When an appointment is being created within online booking, the appointment is created and set to Initial Status as soon as the customer selects a time slot. Initial Status will hold the appointment for the customer while they are completing the booking form, once in Initial Status the appointment will either be completed should the customer fill out the required information or cancelled once the booking timer expires. By default the booking timer is 2-minutes, this can be customized in online booking settings within the OnSched Portal.

Already know who's booking when the time slot is selected? No problem, there is a completeBooking parameter when the appointment is first created which will skip the initial (IN) status and move directly to a status of booked (BK).


Did this page help you?