v1

latestOpenAPI 3.1.02026-07-2422707.0 MB

Retrieve the schedules of classes in multiple centers

This API helps you to retrieve the list of active schedules of classes sessions in multiple centers.

You must provide the appropriate details in the API request for the center_id parameters. Optionally, you can also specify the required details in the API request for several other parameters to filter the search results in the API response. Refer to the Request Parameters table for more information.

get/v1/classes/sessions?center_id={center_id}&page={page}&class_name={class_name}&start_date={start_date}&end_date={end_date}&show_in_catalog={show_in_catalog}&status={status}&registration_id={registration_id}&session_id={session_id}&filters[0].property={filters[0].property}&filters[0].value={filters[0].value}&filters[1].property={filters[1].property}&filters[1].value={filters[1].value}}&filters[2].property={filters[2].property}&filters[2].value={filters[2].value}&filters[3].property={filters[3].property}&filters[3].value={filters[3].value}&filters[4].property={filters[4].property}&filters[4].value={filters[4].value}&class_id={class_id}&recurrence_id={recurrence_id}&session_name={session_name}&guest_id={guest_id}&size={size}

Query parameters

center_idstring required

Mandatory Unique identifier of the specified multiple centers (separated by commas) for which you want to retrieve active class sessions.

pageinteger

Optional Number of pages of search results to be displayed.

class_namestring

Optional Name of a particular type of classes for which the search results are to be displayed. For example, "cardio."

start_datestring date

Optional Sessions will be returned from the specified start date. You must specify this date in YYYY-MM-DD format. If you do not provide any time details for this parameter, the API considers its default value: 00:00:00

end_datestring date

Optional Sessions will be returned until the specified end date. You must specify this date in YYYY-MM-DD format. If you do not provide any time details for this parameter, the API considers its default value: 00:00:00.

show_in_cataloginteger

Optional You must specify 1 if you want only catalog sessions to be returned in the API response.

status''

Optional Indicates the class session status: Active = 0, Cancelled = 1, Upcoming = 2, Inprogress = 3, and Completed = 4.

session_idinteger

Optional Unique identifier of the required class session to be booked.

registration_idinteger

Optional Unique identifier of the class session for which the guest was registered.

filters[0].propertystring

Optional Name of the Level ID property column to filter the API response as required.

filters[0].valueinteger

Optional Value of the Level ID property column to filter the API response as required.

filters[1].propertystring

Optional Name of the Class ID property column to filter the API response as required.

filters[1].valueinteger

Optional Value of the Class ID property column to filter the API response as required.

filters[2].propertystring

Optional Name of the Instructor ID property column to filter the API response as required.

filters[2].valueinteger

Optional Value of the Instructor ID property column to filter the API response as required.

filters[3].propertystring

Optional Name of the Tag Name property column to filter the API response as required.

filters[3].valueinteger

Optional Value of the Tag Name property column to filter the API response as required.

filters[4].propertystring

Optional Name of the Category Parent ID property column to filter the API response as required.

filters[4].valueinteger

Optional Value of the Category Parent ID property column to filter the API response as required.

class_idstring

Optional Unique identifier of the required class.

recurrence_idstring

Optional Unique identifier of the recurrence of the required class.

session_namestring

Optional Name of the class session.

guest_idstring

Optional Unique identifier of the required guest.

sizeinteger

Optional Total records to be displayed in a page.

Response

200

opening_timestring
{"stackTrail":"paths:/v1/classes/sessions?center_id={center_id}&page={page}&class_name={class_name}&start_date={start_date}&end_date={end_date}&show_in_catalog={show_in_catalog}&status={status}&registration_id={registration_id}&session_id={session_id}&filters[0].property={filters[0].property}&filters[0].value={filters[0].value}&filters[1].property={filters[1].property}&filters[1].value={filters[1].value}}&filters[2].property={filters[2].property}&filters[2].value={filters[2].value}&filters[3].property={filters[3].property}&filters[3].value={filters[3].value}&filters[4].property={filters[4].property}&filters[4].value={filters[4].value}&class_id={class_id}&recurrence_id={recurrence_id}&session_name={session_name}&guest_id={guest_id}&size={size}:get:responses:200:content:application/json:schema:properties:error","oasType":"schema","type":"unknown"}

Example response

{
  "sessions": [
    {
      "id": 87498,
      "name": "kt ap 2",
      "class_id": 10992,
      "start_time": "2021-04-14T00:30:38",
      "end_time": "2021-04-14T01:30:38",
      "start_time_utc": "2021-04-13T19:00:38",
      "end_time_utc": "2021-04-13T20:00:38",
      "price": 289,
      "instructor_id": "35e4d821-0942-468b-9c58-b946c4d5756d",
      "status": 1,
      "recurrence_id": 31629,
      "center_id": "d51712b1-6040-4dd4-abff-cffc9d36f89e",
      "center_name": "Pras KDEV",
      "capacity": 10,
      "web_capacity": 5,
      "available_slots": 5,
      "can_book_status_id": 9,
      "can_book_status": "SessionStarted",
      "cancellation_fee_window": 30,
      "cancellation_fee": 34.68
    }
  ],
  "classes": [
    {
      "id": 10970,
      "name": "kt mar 29",
      "category_id": 258,
      "description": "test",
      "html_description": "hudiahjadhjzhioashfnaskxhhvcokjheauidsvhjkxhvjsxhjvujzxhvjkkzxvjkxhjvb%20jhzxvjuiefaufoabvkzdjovcnazxhficknzxjkvjkodaxhhviokzxjiaesifpanjvjcophfs",
      "allow_web_booking": true,
      "allow_cancellation_fee": true,
      "allow_no_show_fee": true,
      "display_name": "kt march 29",
      "show_in_catalog": 1,
      "enable_enrol": true,
      "type": 1
    }
  ],
  "instructors": [
    {
      "id": "45bb6d28-5ccd-41a0-a521-121a58455d21",
      "name": "Franchise Owner",
      "image_paths": {
        "px64": "https://managemyspainternal.s3-us-west-2.amazonaws.com/assetshare/0ebfcafe-a3d0-4f23-b3dd-cbab4e493cae/employees/px64/a4a89f7f-bd5d-4bda-8edd-2fa278c0ecc8.png?X-Amz-Expires=1800&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIK5OKVLX5EIUEZSQ/20210414/us-west-2/s3/aws4_request&X-Amz-Date=20210414T092918Z&X-Amz-SignedHeaders=host&X-Amz-Signature=0d425f885ccdce11ee79463da313c2d00a4fbd64666ac56d187bc0b8dc3fec85",
        "px100": "https://managemyspainternal.s3-us-west-2.amazonaws.com/assetshare/0ebfcafe-a3d0-4f23-b3dd-cbab4e493cae/employees/px100/a4a89f7f-bd5d-4bda-8edd-2fa278c0ecc8.png?X-Amz-Expires=1800&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIK5OKVLX5EIUEZSQ/20210414/us-west-2/s3/aws4_request&X-Amz-Date=20210414T092918Z&X-Amz-SignedHeaders=host&X-Amz-Signature=1082fb4b7bd1c6f732261abb926c47c7731a132526bb12f07c0524740dd68793",
        "px200": "https://managemyspainternal.s3-us-west-2.amazonaws.com/assetshare/0ebfcafe-a3d0-4f23-b3dd-cbab4e493cae/employees/px200/a4a89f7f-bd5d-4bda-8edd-2fa278c0ecc8.png?X-Amz-Expires=1800&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIK5OKVLX5EIUEZSQ/20210414/us-west-2/s3/aws4_request&X-Amz-Date=20210414T092918Z&X-Amz-SignedHeaders=host&X-Amz-Signature=c51c432eda68160c78b34911c1c1e86dc6ac4193c19182d9b06a408659f17e51",
        "px400": "https://managemyspainternal.s3-us-west-2.amazonaws.com/assetshare/0ebfcafe-a3d0-4f23-b3dd-cbab4e493cae/employees/px400/a4a89f7f-bd5d-4bda-8edd-2fa278c0ecc8.png?X-Amz-Expires=1800&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIK5OKVLX5EIUEZSQ/20210414/us-west-2/s3/aws4_request&X-Amz-Date=20210414T092918Z&X-Amz-SignedHeaders=host&X-Amz-Signature=e12cc803f81967079863e0d51a23d2af72c48a0464d0970d479d415cc32023ee",
        "px800": "https://managemyspainternal.s3-us-west-2.amazonaws.com/assetshare/0ebfcafe-a3d0-4f23-b3dd-cbab4e493cae/employees/px800/a4a89f7f-bd5d-4bda-8edd-2fa278c0ecc8.png?X-Amz-Expires=1800&X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIK5OKVLX5EIUEZSQ/20210414/us-west-2/s3/aws4_request&X-Amz-Date=20210414T092918Z&X-Amz-SignedHeaders=host&X-Amz-Signature=2734a2b7a6e824ac5d3b0d053e3bde455ed383ab1bf1889916a2364003dd7c14"
      }
    }
  ],
  "categories": [
    {
      "id": 258,
      "name": "Indoor",
      "parent_id": 257
    }
  ],
  "rooms": [
    {
      "id": "2310a3f6-3769-401c-8162-71f76baa2e26",
      "name": "PRAS_ROOM"
    }
  ],
  "levels": [
    {
      "id": 1355,
      "code": "apr20.w3",
      "name": "apr20.w3 level",
      "description": "desc qqq",
      "html_description": "<h1> desc </h>"
    }
  ],
  "opening_time": "17:30",
  "page_details": {
    "total": 66,
    "page": 1,
    "size": 10
  }
}