Partner API
Classes

List partner classes

Retrieve a paginated list of partner classes with optional filtering

get/{partnerId}/classes

Request

  • Base URL: https://us-central1-sutra-prod.cloudfunctions.net/partnerApi/v0
  • URL: https://us-central1-sutra-prod.cloudfunctions.net/partnerApi/v0/{partnerId}/classes
  • Auth: one of:
    • API key in header X-API-Key
    • HTTP bearer

Path parameters

partnerIdstring required
Example:partner123

Partner identifier

locationIdstring required
Example:loc123

Location identifier

Query parameters

limitinteger
Example:10

Number of items to return (default 10, max 100)

start_afterstring
Example:item123

ID to start after for pagination

start_datestring date-time

Filter classes starting from this date (ISO 8601)

end_datestring date-time

Filter classes ending before this date (ISO 8601)

idsstring
Example:id1,id2,id3

Comma-separated list of IDs to fetch

Response

Successful response

Example response

{
  "items": [
    {
      "id": "class123",
      "name": "Morning Yoga",
      "description": "Start your day right",
      "start_time": "2024-03-20T08:00:00Z",
      "duration": 60,
      "location_id": "loc123",
      "room_id": "room123",
      "max_capacity": 20,
      "total_booked": 15,
      "updated_at": "2024-03-20T12:00:00Z",
      "instructor_name": "John Smith"
    }
  ],
  "pagination": {
    "limit": 10,
    "nextStartAfterId": "item123"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.