Courses
Courses are learning objects within Coassemble. Using the API, you can fetch and delete courses as well as get a signed URL for courses for embedding.
Get courses
Use this endpoint to get all your courses. By default only non-deleted courses are returned; set the deleted query parameter to true to include soft-deleted courses.
Each course in the response includes timeEstimateMinutes, the minutes shown on the start screen timeEstimate block. The field is null when that block is absent. calculatedTimeEstimateMinutes is the content-derived estimate, with omitted content in timeEstimateExcluded. See completion time calculation.
/v1/headless/coursesQuery parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
identifier | string | No | — | — | |
clientIdentifier | string | No | — | — | |
length | string | integer | No | 100 | — | |
page | string | integer | No | 0 | — | |
title | string | No | — | — | |
deleted | boolean | No | false | — |
Get course
Use this endpoint to get a course by ID.
Pass language to return a matching translation's outline. If no translation matches, the response uses the original course.
The response includes timeEstimateMinutes, the minutes shown on the start screen timeEstimate block. The field is null when that block is absent.
/v1/headless/courses/{id}Path parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Query parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
identifier | string | No | — | — | |
clientIdentifier | string | No | — | — | |
language | string | No | — | — |
Completion time calculation
Both course reads return the time block’s timeEstimateMinutes and the current content’s calculatedTimeEstimateMinutes. With Automatic time on, the default for new courses, timeEstimateMinutes is the calculated time with a minimum of 1 and follows the content shortly after each saved change, including API and AI edits. With it off, it is the number the author set. The calculated field is null for Classic (Builder 1) and hosted SCORM courses. Builder 2 standard courses round total seconds to the nearest millisecond and then up to whole minutes, with a minimum of 1 for nonempty content and 0 for an empty course.
Reading uses 238 words per minute from Brysbaert (2019), How many words do we read per minute? A review and meta-analysis of reading rate, Journal of Memory and Language 109, 104047. Chinese uses 255 characters per minute and Japanese uses 357, citing Trauzettel-Klosinski & Dietz (2012), IReST, Investigative Ophthalmology & Visual Science 53(9), 5452–5461. Character counts exclude whitespace and punctuation. Korean assumes 255 syllable blocks per minute using the Chinese rate as a conservative proxy. This is an assumption because IReST does not establish a Korean silent-reading character rate.
Fixed assumptions add 30 seconds per question, including video questions, and 5 seconds per accordion item, hotspot, flashcard, process step, checklist item or slide. Every item is visited once. Each question is answered once, with the passed quiz result counted and no retries. Reading and enabled narration take the longer duration for each screen or item. Video and audio play at normal speed and count their full stored length.
timeEstimateExcluded groups unknown-length content by type and count, sorted alphabetically by type. For example, [{ "type": "youtube", "count": 2 }]. YouTube is always excluded. Other embeds and documents are excluded, together with Vimeo, uploaded video, audio or narration whose duration has not been stored. Available text still contributes reading time. Classic and hosted SCORM return an empty list.
Calculations use saved content and duration metadata without outbound calls. A list request loads content only for its page of at most 100 courses, then makes one indexed Job lookup for the referenced media. Query count stays independent of the number of courses. Work and memory scale with the page’s screen, block and question content.
Authors can request GET /course/{id}/time-estimate using their builder session or a permitted course edit embed, including the translation course’s own ID. Translated screens and question tracks use that course’s language and audio lengths. Learner, player, embed and SCORM payloads show the time block’s saved value in the content they are served, for a course its last publish.
The reading-rate sources are available in the Brysbaert paper and the IReST paper.
Get course content
Returns normalized course text content, including all translation variants, plus a catalog of media assets with fetchable URLs and metadata. Screens are returned in a standard shape with title, description, asset, assetAltText, and elements (each with question, title, description, cardBack, and answers). Asset processing such as transcription or document parsing is the consumer's responsibility.
/v1/headless/course/content/{id}Path parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Query parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
identifier | string | No | — | — | |
clientIdentifier | string | No | — | — |
Regenerate course card thumbnail
Fails any stuck thumbnail job and enqueues a fresh capture for Classic, Builder 2, or hosted SCORM. Poll GET /v1/headless/courses/{id} for the JPEG. The response includes id, thumbnail, thumbnailRevision, and queued.
/v1/headless/course/{id}/thumbnailPath parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Get a signed URL for a course [GET] (Deprecated)
POST /v1/headless/embed/course endpoint instead. See recommended alternative →/v1/headless/course/{action}Path parameters
| Field | Description | Options |
|---|---|---|
action | view (learner) or edit (authoring) | viewedit |
Query parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
id | string | No | — | — | |
identifier | string | Yes | — | — | |
clientIdentifier | string | No | — | — | |
flow | string | No | — | aidocumentpresentationpreviewgeneratetransformconvert | |
back | string | No | — | eventhiddennative | |
colorPrimary | string | No | — | — | |
translations | boolean | No | — | — | |
language | string | No | — | — | |
brandVoice | boolean | No | — | — | |
legacy | boolean | No | — | — | |
lockSteps | boolean | No | — | — | |
hideOutline | boolean | No | — | — | |
autoResume | boolean | No | — | — |
Get a signed URL for a course [POST] (Deprecated)
POST /v1/headless/embed/course endpoint instead. See recommended alternative →Use this endpoint to get a signed URL for a course. This URL can be used to embed the Coassemble interface into your application within an iframe.
/v1/headless/course/urlBody parameters
| Field | Type | Required | Desc | Options |
|---|---|---|---|---|
action | string | Yes | view (learner) or edit (authoring) | viewedit |
id | string | No | Course ID (required when action is view) | — |
identifier | string | Yes | Your stable user identifier | — |
clientIdentifier | string | No | The client this user belongs to | — |
themeId | number | No | Theme ID to render the embed with | — |
name | string | No | Display name for the learner or editor. Used for presence avatars and comment authors. An empty or blank name is treated as not given. When not given, a colour-and-animal name is generated from identifier. Max 512 characters; over-limit values return HTTP 400 naming the field, limit and length sent. | — |
avatar | string | No | Avatar image URL for the learner or editor. Used for presence avatars and comment authors. An empty or blank avatar is treated as not given. When not given, no avatar is shown; it does not generate a name. Non-blank values must be an http(s) URL. Max 2048 characters; non-blank values that exceed the limit or are not an http(s) URL return HTTP 400 naming the field, limit and length sent. | — |
options | object | No | — |
Duplicate a course
Use this endpoint to duplicate an existing course. You can optionally provide an identifier and clientIdentifier to assign the duplicated course to a new client or user within your environment.
/v1/headless/course/{id}/duplicatePath parameters
| Field | Description | Options |
|---|---|---|
id | Source course ID | — |
Body parameters
| Field | Type | Required | Desc | Options |
|---|---|---|---|---|
identifier | string | No | Override identifier on the duplicate | — |
clientIdentifier | string | No | Override client identifier on the duplicate | — |
Migrate a Classic course
This route is an alias of POST /v1/headless/course-migrations for one course id. It returns the same 200 result and does not create a batch. Migration does not publish the course. These endpoints require API authoring access and only operate on courses in your API key's workspace.
/v1/headless/course/{id}/migratePath parameters
| Field | Description | Options |
|---|---|---|
id | — |
{
"courseId": 123,
"status": "migrated",
"total": 3,
"changed": 3,
"blocked": []
} Check status: migrated means conversion succeeded, already_modern means no conversion was needed, and blocked means the course was left unchanged. For blocked courses, inspect blocked for screen IDs and reasons. An active migration preview is committed rather than rejected: the course leaves preview and stays on Builder 2.
To let authors preview and confirm migration themselves, enable the Course Builder migration option.
Migrate courses in a batch
Submit course IDs to POST /v1/headless/course-migrations. At most 50 IDs per request. One unique course returns 200 with the final result. Two or more unique courses return 202 with a durable batch id. Duplicate ids in one request count once.
/v1/headless/course-migrationsBody parameters
| Field | Type | Required | Desc | Options |
|---|---|---|---|---|
courseIds | string | integer[] | Yes | — | |
notifyEmail | string | No | Ignored. Completion email is not sent. | — |
{
"courseIds": [
123,
456
]
} The dashboard calls the same operation. A 202 batch keeps running after the request closes. Each course uses the same atomic conversion. One failed course does not undo a successful course. Subscribe to migration.progress and migration.completed instead of polling GET /v1/headless/course-migrations/{id} if you already receive workspace webhooks. Those events fire only for 202 batches, not for the one-course 200 path. notifyEmail is accepted and ignored. Completion email is not sent.
Get migration batch status
/v1/headless/course-migrations/{id}Path parameters
| Field | Description | Options |
|---|---|---|
id | — |
Use this route only for a 202 batch id, with an API key for the same workspace. Poll while status is pending or processing. Stop when it reaches completed or completed_with_errors. migration.progress and migration.completed carry the same snapshot as this response, so you can skip polling if those webhooks are subscribed.
counts contains total, pending, processing, succeeded, and failed. Inspect items for each course's status, conversion result, blocked screens, or error. Item statuses are pending, processing, migrated, already_modern, blocked, or failed. The batch has no notification field. Completion email is not sent.
Resolve any blocked content or errors, then submit only those course IDs as a new batch to retry. Re-submitting an already migrated course returns already_modern without converting it again.
Delete course
Use this endpoint to delete an existing course. The course is soft-deleted and can be restored within its workspace or customer retention period, 30 days by default. After that period, the nightly cleanup permanently removes it and it can no longer be restored. Workspace or customer closure can cause earlier removal.
/v1/headless/course/{id}Path parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Restore a course
Use this endpoint to restore a soft-deleted course within its workspace or customer retention period, 30 days by default. After that period, the nightly cleanup permanently removes it and it can no longer be restored. Workspace or customer closure can cause earlier removal. Courses belonging to a deleted customer can't be restored.
/v1/headless/course/{id}/restorePath parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Export SCORM
Use this endpoint to export a SCORM package for a course.
The default type=dynamic package works on every plan. type=static (Standalone SCORM) needs the Standalone SCORM add-on, available to Partner customers on approved request.
/v1/headless/course/scorm/{id}Path parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Query parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
type | string | No | — | dynamicstatic | |
version | string | No | — | 1.22004 |
Before downloading a Standalone SCORM package, call the estimate endpoint for its size and whether it exceeds the export cap. It accepts only type=static.
/v1/headless/course/scorm/{id}/estimatePath parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Query parameters
| Field | Type | Required | Default | Description | Options |
|---|---|---|---|---|---|
type | string | No | — | dynamicstatic | |
version | string | No | — | 1.22004 |
Unscored quizzes in Builder 2 exports
Unscored quizzes count toward course completion and never fail. The quiz score is the percentage of questions answered correctly, for information only. Use the LMS completion or success status for the outcome.
With type=static, the player sends a pass and the percentage when the quiz finishes. In SCORM 2004, it sets cmi.success_status to passed and writes the percentage to cmi.score.raw. At course end, it sets cmi.completion_status to completed. In SCORM 1.2, it sets cmi.core.lesson_status to passed and writes to cmi.core.score.raw when the quiz finishes, even if screens remain.
For a type=dynamic export with only unscored quizzes, the server reports completion only. At course end, it sets cmi.completion_status to completed in SCORM 2004 or cmi.core.lesson_status to completed in SCORM 1.2. The player reports the unscored quiz's pass and percentage only if the learner finishes the quiz and the course in the same session.
When the player reports several quiz results, the raw score is the average of the quizzes finished in that session, scored or unscored. The combined result is a pass only if all those quizzes passed. Neither export type lowers a score or overwrites a pass or completion that the LMS already holds.
Generate a course (Deprecated)
POST /v1/headless/generate/course endpoint instead. See recommended alternative →This legacy route is still available for backwards compatibility and delegates to the new generate controller.
/v1/headless/course/generateBody parameters
| Field | Type | Required | Desc | Options |
|---|---|---|---|---|
prompt | string | Yes | The topic or learning objective to generate a course from | — |
audience | string | Yes | Who the course is for (e.g. "new hires") | — |
familiarity | string | Yes | How familiar the audience is with the topic (e.g. "beginner") | — |
tone | string | Yes | Tone of voice for the generated content (e.g. "professional") | — |
screenCount | number | Yes | Approximate number of screens to generate | — |
identifier | string | Yes | Your stable identifier for the course owner | — |
clientIdentifier | string | No | The client this course belongs to | — |
Publish a course
Use this endpoint to publish a course programmatically.
Translations need no separate publish. A learner who opens the course with a language gets that translation's current content, and GET /v1/headless/courses/{id}?language= returns its outline.
/v1/headless/course/{id}/publishPath parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |
Revert a course
Use this endpoint to revert a course to its published version programmatically.
/v1/headless/course/{id}/revertPath parameters
| Field | Description | Options |
|---|---|---|
id | Course ID | — |