Update Syllabus
update_syllabusSet or edit the Canvas syllabus tab content for a course. Replacing an existing syllabus previews first and requires a confirmation token, while empty, append, or prepend writes take one call.
Instructions
Set the Canvas Syllabus tab content for a course.
Canvas keeps no revision history for the syllabus, so replacing a syllabus that already has content is a two-step call: call without confirmation_token to get a preview plus a single-use token, show the preview to the educator, and only after they approve it call again with the token and identical arguments. Writing into an empty syllabus, or appending/prepending, destroys nothing and takes a single call.
Optional guards, independent of the confirmation token: the syllabus has no updated_at, so expect_body_sha256 (shown by get_syllabus) refuses if the body changed since you read it; find/replace edits one fragment of the current body instead of sending syllabus_body (mode must be "replace", and it still previews first); require lists strings that must already be present.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| find | No | Exact HTML fragment that must occur exactly once in the current body | |
| mode | No | "replace" (default) swaps the whole body, "append" adds to the end of the existing body, "prepend" adds to the start. | replace |
| replace | No | Text that replaces find (may be empty to delete it) | |
| require | No | Strings that must already be present in the current body | |
| syllabus_body | No | HTML for the syllabus. Canvas stores this as HTML; plain text is accepted but renders without formatting. | |
| course_identifier | Yes | Course code or Canvas ID | |
| confirmation_token | No | Token from the preview call. Only needed when replacing a syllabus that already has content; a token that is supplied is always checked, in every mode. | |
| expect_body_sha256 | No | SHA-256 of the syllabus body when you read it (get_syllabus prints it); refuse if the body has changed |