Create Tutor LMS Lesson


Adds a lesson to the end of a topic of a Tutor LMS course. Name the topic by topic_id or topic_title; without either, the lesson goes into the course's last topic. A topic is created when the course has none, when topic_title matches no topic, or when new_topic is true. The lesson is created as a draft that students cannot see unless publish is true; saving it in Tutor's course builder also publishes it. Reversible: the lesson can be edited or deleted in Tutor afterwards. Get the course ID from mosmcp/tutor-list-courses.

Also known as: add a lesson, add course content, add a module, add a chapter.

Property Value
Ability slug mosmcp/tutor-create-lesson
Wire tool name mosmcp__tutor-create-lesson
Category Tutor LMS (mosmcp-tutor)
Plan Pro

 

Required access

Requirement Value
Capability edit_tutor_lessons
Minimum default role Administrator
Annotations readOnly: false · destructive: false · idempotent: false · openWorld: false

 

Input schema

Field Type Required Default Description
course_id integer (min 1) Yes — The Tutor LMS course ID, as returned by mosmcp/tutor-list-courses.
title string (min length 1) Yes — The lesson title.
content string — Optional lesson content. HTML is saved the way the WordPress editor saves it: a user with the unfiltered_html capability can save any markup, including forms, scripts and styles, and markup a user is not allowed to save is refused with the reason rather than silently removed. Backslashes are kept.
topic_id integer (min 1) — Optional ID of the topic to add the lesson to. It must belong to this course.
topic_title string — Optional topic title. The lesson goes into the course's topic with this title (ignoring case), or into a new topic with this title when there is none.
new_topic boolean false Start a new topic at the end of the course for this lesson, even when the course already has topics. Uses topic_title as its title when given.
publish boolean false Publish the lesson straight away. Leave false to create a draft.

 

Output schema

Field Type Required Description
lesson_id integer Yes
title string Yes
status string Yes
order integer The lesson's position among the topic's contents.
course_id integer Yes
course_title string
topic object Yes
topic.topic_id integer Yes
topic.title string Yes
topic.order integer
topic.created boolean Yes Whether this call created the topic.
builder_url string
view_url string
warnings object[] Notes about the save, such as markup that could not be kept.
warnings[].code string
warnings[].message string
warnings[].context string
notes string[]

 


<< Previous Next >>
Create Tutor LMS Course Create Tutor LMS Quiz

For more information about the Secure MCP Server for WordPress plugin, explore the following resources:

Product Overview | Pricing | Try for Free | Documentation

If you have any questions regarding plugin configuration, pricing plans or licensing, please contact us or mail us at aisupport@xecurify.com.