Skip to content
English
  • There are no suggestions because the search field is empty.

๐Ÿ“˜ How to Use the Public Classes API

This guide explains how to access and use the public Franscape Classes API endpoint:

https://api.uk.prod.franscape.services/v1/public/classes


๐Ÿ“˜ API Overview

This GET endpoint returns a paginated list of public classes, including schedule, venue, and instructor information.

  • ๐ŸŒ Base URL: https://api.uk.prod.franscape.services/v1/public/classes
  • ๐Ÿ”’ Authentication: Not required
  • ๐Ÿงพ Required Header: tenant: brandname
  • ๐Ÿ“„ Response Format: application/json
๐Ÿงฉ Required Headers

Set the following header when making your request:

GET /v1/public/classes HTTP/1.1
Host: api.uk.prod.franscape.services
tenant: brandname
Accept: application/json
๐Ÿ› ๏ธ Query Parameters

The following optional query parameters are supported:

Parameter Description Example
page Page number for paginated results ?page=1
count Number of items per page ?count=25
filter URL-encoded JSON object ?filter=%7B%22franchisee_ids%22%3A%5B6%5D%7D

๐ŸŽฏ Filters

The filter parameter must contain a URL-encoded JSON object. You can use it to filter results by franchisee, course types, day of week, or venue IDs.

Supported filter keys

  • franchisee_ids โ†’ array of integer IDs
  • course_type_ids โ†’ array of integer IDs
  • day_of_week โ†’ array of numbers (0 = Sunday, 6 = Saturday)
  • venue_ids โ†’ array of venue ID integers

Example JSON

{
  "franchisee_ids": [6],
  "course_type_ids": [1, 2, 3],
  "day_of_week": [1, 3, 5],
  "venue_ids": [1001, 1002]
}

Encoded for use in URL

filter=%7B%22franchisee_ids%22%3A%5B6%5D%2C%22course_type_ids%22%3A%5B1%2C2%2C3%5D%2C%22day_of_week%22%3A%5B1%2C3%2C5%5D%2C%22venue_ids%22%3A%5B1001%2C1002%5D%7D
๐Ÿ’ก Tip: Use urlencoder.org to encode your raw JSON object for the filter parameter.
๐Ÿ”— Need help finding ID values?
Read this article to learn how to find franchisee, course type, or venue IDs:
https://kb.franscape.io/knowledge/object-id
๐Ÿงช Example Request

Example curl request with page, count, and a full filter set:

curl -X GET "https://api.uk.prod.franscape.services/v1/public/classes?page=1&count=25&filter=%7B%22franchisee_ids%22%3A%5B6%5D%2C%22course_type_ids%22%3A%5B1%2C2%2C3%5D%2C%22day_of_week%22%3A%5B1%2C3%2C5%5D%2C%22venue_ids%22%3A%5B1001%2C1002%5D%7D" \
  -H "tenant: brandname" \
  -H "Accept: application/json"

๐Ÿ“ฆ Sample JSON Response

{
  "meta": {
    "paginated": true,
    "current_page": 1,
    "has_more_pages": true,
    "last_page": 10,
    "per_page": 25,
    "total": 250,
    "next_page_url": "https://api.uk.prod.franscape.services/v1/public/classes?page=2",
    "custom": {
      "tenant": "brandname"
    }
  },
  "items": [
    {
      "id": 202001,
      "name": "Beginners Swim",
      "instructor": { "name": "Dewi Jones" },
      "venue": { "name": "Manchester Aquatics Centre", "postcode": "M13 9SS" },
      "lessons": {
        "schedule": {
          "day_name": "Thursday",
          "time_12": "9:00 AM"
        },
        "space_available": true
      },
      "paths": {
        "class_overview_url": "https://portal.swimtime.org/class-overview/202001",
        "booking_url": "https://portal.swimtime.org/book-class/202001"
      }
    }
  ]
}
๐Ÿš€ Common Use Cases
  • โœ… Embed a live class schedule on a your website
  • โœ… Provide real-time availability and booking links
  • โœ… Display class times, venues, and instructors details
โ— Troubleshooting & Notes
  • โš ๏ธ The tenant header is required for all requests.
  • ๐Ÿ› ๏ธ The filter must be a single URL-encoded JSON object string.
  • ๐ŸŒ€ Use meta.next_page_url to paginate results.

Last updated: May 29, 2025