POST Cancel a course generation run
Cancels a running or paused run. A canceled run cannot be restarted. Repeating the call reports already_canceled.
Cancels a running or paused run. A canceled run cannot be restarted. Repeating the call reports already_canceled.
Send API keys and access tokens as Authorization: Bearer .
In: header
Path Parameters
uuidRequest Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/course-generations/{id}/cancel" \ -H "Content-Type: application/json" \ -d '{ "reason": "Example reason", "idempotency_key": "Example idempotency key" }'{ "data": { "data": null, "meta": { "organization_id": "{organization_id}", "total": 0, "total_count": 0, "limit": 0, "offset": 0, "has_more": true, "requested_at": "2019-08-24T14:15:22Z" } }, "meta": { "organization_id": "{organization_id}", "total": 0, "total_count": 0, "limit": 0, "offset": 0, "has_more": true, "requested_at": "2019-08-24T14:15:22Z" }}{ "error": "string", "code": "string", "message": "string"}{ "error": "string", "code": "string", "message": "string"}{ "error": "string", "code": "string", "message": "string"}{ "error": "string", "code": "string", "message": "string"}{ "error": "string", "code": "string", "message": "string"}GET Get a course generation run GET
Returns the run status, stage, progress, and event feed. When the run is paused for manuscript review, review_url links to the admin dashboard review screen. Pass next_cursor.since and next_cursor.since_id back as since and since_id to read only newer events.
POST Start a course generation run POST
Starts an asynchronous AI course generation run and returns its run_id at once. The run writes a manuscript and pauses for human review in the admin dashboard. Poll GET /api/public/v1/course-generations/{id} for status. Requires an OAuth access token; API keys are refused.