ResourcesCourses

Manage course lessons

Create, update, and delete lessons, quizzes, and assignments.

Lesson types are lecture, video, text, quiz, and assignment. A lecture placeholder may become video or text; established item types are otherwise immutable. Rich-text content is sanitized before storage.

Quiz and assignment arrays replace the corresponding structured question set when present. is_preview applies only to video lessons. is_published controls enrolled-customer visibility independently from the course listing visibility.

Video fields in responses are references to existing Mux or external video records. Upload lifecycle and signed playback tokens remain in the existing dashboard and preview flows.

POST
/v2/courses/{course}/sections/{section}/lessons

Authorization

bearerAuth storeAuth
AuthorizationBearer <token>

Provide your SellApp API key as a bearer token.

In: header

X-STORE<token>

Select the SellApp store for this API request.

In: header

Path Parameters

course*string

The course path parameter.

section*integer

The section path parameter.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://sell.app/api/v2/courses/string/sections/0/lessons" \  -H "Content-Type: application/json" \  -d '{    "title": "string",    "type": "lecture"  }'
{
  "data": {
    "id": 0,
    "section_id": 0,
    "title": "string",
    "content": "string",
    "type": "lecture",
    "is_preview": true,
    "is_published": true,
    "sort_order": 1,
    "video": {
      "source": "mux",
      "external_url": "http://example.com",
      "mux_playback_id": "string",
      "mux_status": "string",
      "duration_seconds": 0
    },
    "attachments": [
      {
        "id": 0,
        "title": "string",
        "mime_type": "string",
        "size_bytes": 0,
        "sort_order": 1
      }
    ],
    "assignment": {
      "estimated_duration_minutes": 1,
      "instructions": "string",
      "questions": [
        {
          "id": 0,
          "prompt": "string",
          "question_type": "text",
          "solution": "string",
          "sort_order": 1,
          "answers": [
            {
              "id": 0,
              "answer": "string",
              "is_correct": true,
              "sort_order": 1
            }
          ],
          "created_at": "2019-08-24T14:15:22Z",
          "updated_at": "2019-08-24T14:15:22Z"
        }
      ]
    },
    "questions": [
      {
        "id": 0,
        "prompt": "string",
        "question_type": "text",
        "solution": "string",
        "sort_order": 1,
        "answers": [
          {
            "id": 0,
            "answer": "string",
            "is_correct": true,
            "sort_order": 1
          }
        ],
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z"
      }
    ],
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z"
  }
}
{
  "message": "Unauthenticated."
}
{
  "message": "This action is unauthorized."
}
{
  "message": "Rule not found."
}
{
  "message": "The given data was invalid.",
  "errors": {
    "data": [
      "The data field is required."
    ]
  }
}
PATCH
/v2/courses/{course}/lessons/{lesson}

Authorization

bearerAuth storeAuth
AuthorizationBearer <token>

Provide your SellApp API key as a bearer token.

In: header

X-STORE<token>

Select the SellApp store for this API request.

In: header

Path Parameters

course*string

The course path parameter.

lesson*integer

The lesson path parameter.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X PATCH "https://sell.app/api/v2/courses/string/lessons/0" \  -H "Content-Type: application/json" \  -d '{}'
{
  "data": {
    "id": 0,
    "section_id": 0,
    "title": "string",
    "content": "string",
    "type": "lecture",
    "is_preview": true,
    "is_published": true,
    "sort_order": 1,
    "video": {
      "source": "mux",
      "external_url": "http://example.com",
      "mux_playback_id": "string",
      "mux_status": "string",
      "duration_seconds": 0
    },
    "attachments": [
      {
        "id": 0,
        "title": "string",
        "mime_type": "string",
        "size_bytes": 0,
        "sort_order": 1
      }
    ],
    "assignment": {
      "estimated_duration_minutes": 1,
      "instructions": "string",
      "questions": [
        {
          "id": 0,
          "prompt": "string",
          "question_type": "text",
          "solution": "string",
          "sort_order": 1,
          "answers": [
            {
              "id": 0,
              "answer": "string",
              "is_correct": true,
              "sort_order": 1
            }
          ],
          "created_at": "2019-08-24T14:15:22Z",
          "updated_at": "2019-08-24T14:15:22Z"
        }
      ]
    },
    "questions": [
      {
        "id": 0,
        "prompt": "string",
        "question_type": "text",
        "solution": "string",
        "sort_order": 1,
        "answers": [
          {
            "id": 0,
            "answer": "string",
            "is_correct": true,
            "sort_order": 1
          }
        ],
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z"
      }
    ],
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z"
  }
}
{
  "message": "Unauthenticated."
}
{
  "message": "This action is unauthorized."
}
{
  "message": "Rule not found."
}
{
  "message": "The given data was invalid.",
  "errors": {
    "data": [
      "The data field is required."
    ]
  }
}
PUT
/v2/courses/{course}/lessons/{lesson}

Authorization

bearerAuth storeAuth
AuthorizationBearer <token>

Provide your SellApp API key as a bearer token.

In: header

X-STORE<token>

Select the SellApp store for this API request.

In: header

Path Parameters

course*string

The course path parameter.

lesson*integer

The lesson path parameter.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X PUT "https://sell.app/api/v2/courses/string/lessons/0" \  -H "Content-Type: application/json" \  -d '{}'
{
  "data": {
    "id": 0,
    "section_id": 0,
    "title": "string",
    "content": "string",
    "type": "lecture",
    "is_preview": true,
    "is_published": true,
    "sort_order": 1,
    "video": {
      "source": "mux",
      "external_url": "http://example.com",
      "mux_playback_id": "string",
      "mux_status": "string",
      "duration_seconds": 0
    },
    "attachments": [
      {
        "id": 0,
        "title": "string",
        "mime_type": "string",
        "size_bytes": 0,
        "sort_order": 1
      }
    ],
    "assignment": {
      "estimated_duration_minutes": 1,
      "instructions": "string",
      "questions": [
        {
          "id": 0,
          "prompt": "string",
          "question_type": "text",
          "solution": "string",
          "sort_order": 1,
          "answers": [
            {
              "id": 0,
              "answer": "string",
              "is_correct": true,
              "sort_order": 1
            }
          ],
          "created_at": "2019-08-24T14:15:22Z",
          "updated_at": "2019-08-24T14:15:22Z"
        }
      ]
    },
    "questions": [
      {
        "id": 0,
        "prompt": "string",
        "question_type": "text",
        "solution": "string",
        "sort_order": 1,
        "answers": [
          {
            "id": 0,
            "answer": "string",
            "is_correct": true,
            "sort_order": 1
          }
        ],
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z"
      }
    ],
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z"
  }
}
{
  "message": "Unauthenticated."
}
{
  "message": "This action is unauthorized."
}
{
  "message": "Rule not found."
}
{
  "message": "The given data was invalid.",
  "errors": {
    "data": [
      "The data field is required."
    ]
  }
}
DELETE
/v2/courses/{course}/lessons/{lesson}

Authorization

bearerAuth storeAuth
AuthorizationBearer <token>

Provide your SellApp API key as a bearer token.

In: header

X-STORE<token>

Select the SellApp store for this API request.

In: header

Path Parameters

course*string

The course path parameter.

lesson*integer

The lesson path parameter.

Response Body

application/json

application/json

application/json

application/json

application/json

curl -X DELETE "https://sell.app/api/v2/courses/string/lessons/0"
{
  "data": {
    "id": 0,
    "section_id": 0,
    "title": "string",
    "content": "string",
    "type": "lecture",
    "is_preview": true,
    "is_published": true,
    "sort_order": 1,
    "video": {
      "source": "mux",
      "external_url": "http://example.com",
      "mux_playback_id": "string",
      "mux_status": "string",
      "duration_seconds": 0
    },
    "attachments": [
      {
        "id": 0,
        "title": "string",
        "mime_type": "string",
        "size_bytes": 0,
        "sort_order": 1
      }
    ],
    "assignment": {
      "estimated_duration_minutes": 1,
      "instructions": "string",
      "questions": [
        {
          "id": 0,
          "prompt": "string",
          "question_type": "text",
          "solution": "string",
          "sort_order": 1,
          "answers": [
            {
              "id": 0,
              "answer": "string",
              "is_correct": true,
              "sort_order": 1
            }
          ],
          "created_at": "2019-08-24T14:15:22Z",
          "updated_at": "2019-08-24T14:15:22Z"
        }
      ]
    },
    "questions": [
      {
        "id": 0,
        "prompt": "string",
        "question_type": "text",
        "solution": "string",
        "sort_order": 1,
        "answers": [
          {
            "id": 0,
            "answer": "string",
            "is_correct": true,
            "sort_order": 1
          }
        ],
        "created_at": "2019-08-24T14:15:22Z",
        "updated_at": "2019-08-24T14:15:22Z"
      }
    ],
    "created_at": "2019-08-24T14:15:22Z",
    "updated_at": "2019-08-24T14:15:22Z"
  }
}
{
  "message": "Unauthenticated."
}
{
  "message": "This action is unauthorized."
}
{
  "message": "Rule not found."
}
{
  "message": "The given data was invalid.",
  "errors": {
    "data": [
      "The data field is required."
    ]
  }
}