Courses

Returns a paginated list of the courses in an experience or an account. hidden courses are included only for callers with courses:update.

Required permissions:

  • courses:read
get/courses

Request

  • Base URL
    https://api.whop.com/api/v1
  • Auth
    HTTP bearer

Query parameters

after, string

Returns the elements in the list that come after the specified cursor.

before, string

Returns the elements in the list that come before the specified cursor.

first, integer

Returns the first n elements from the list.

Example:42
last, integer

Returns the last n elements from the list.

Example:42
experience_id, string

The unique identifier of the experience to list courses for.

Example:exp_xxxxxxxxxxxxxx
account_id, string

The unique identifier of the company to list courses for.

Example:biz_xxxxxxxxxxxxxx

Response

A successful response

object required

The connection type for Course.

data, CourseListItem[] required

A list of nodes.

page_info, PageInfo required

Information to aid in pagination.

Example response

{
  "data": [
    {
      "chapters_count": 42,
      "completed_lessons_count": 42,
      "cover_image": "https://assets.whop.com/images/course-cover.jpg",
      "created_at": "2023-12-01T05:00:00.401Z",
      "description": "Learn paint correction and ceramic coating techniques from experienced detailers.",
      "experience": {
        "id": "exp_xxxxxxxxxxxxxx"
      },
      "id": "cors_xxxxxxxxxxxxx",
      "latest_lesson_created_at": "2023-12-01T05:00:00.401Z",
      "lesson_unlock_days": [
        42
      ],
      "order": "123.45",
      "resume_lesson": {
        "id": "lesn_xxxxxxxxxxxxx"
      },
      "started_at": "2023-12-01T05:00:00.401Z",
      "tagline": "Learn to protect a showroom finish",
      "thumbnail": {
        "content_type": "image/jpeg",
        "filename": "document.pdf",
        "optimized_url": "https://media.whop.com/abc123/optimized.jpg",
        "source_url": "https://media.whop.com/abc123/original.jpg"
      },
      "title": "Introduction to Ceramic Coating",
      "total_duration_seconds": 42,
      "total_lessons_count": 42,
      "updated_at": "2023-12-01T05:00:00.401Z"
    }
  ]
}

Changes

    • info

      added the required property data/items/experience to the response with the status

    • warning

      deleted the query request parameter company_id

    • info

      added the new optional query request parameter account_id