headless lms

Update an activity

PATCH /api/courses/{courseId}/modules/{moduleId}/activities/{activityId}. Update an activity. Headless LMS Content API reference.

PATCH
/api/courses/{courseId}/modules/{moduleId}/activities/{activityId}

Requires courses:write. Replaces its content and records the library files it uses; each must be a ready library file (409 otherwise). A file the course does not already use must be uploaded for the course, or the caller needs media:read (403 otherwise). Returns the course's modules.

Path Parameters

courseId*string
moduleId*string
activityId*string

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

application/json

application/json

curl -X PATCH "https://example.com/api/courses/string/modules/string/activities/string" \  -H "Content-Type: application/json" \  -d '{}'
[  {    "orgId": "string",    "id": "string",    "courseId": "string",    "title": "string",    "seq": 0,    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  }]
{  "error": "string",  "message": "string",  "requestId": "string",  "issues": [    {      "path": "string",      "message": "string"    }  ]}
{  "error": "string",  "message": "string",  "requestId": "string"}
{  "error": "string",  "message": "string",  "requestId": "string"}
{  "error": "string",  "message": "string",  "requestId": "string"}
{  "error": "string",  "message": "string",  "requestId": "string"}
{  "error": "string",  "message": "string",  "requestId": "string"}