Lodol Docs

LearnDash

API actions for the LearnDash integration.

LearnDash

Manage LearnDash courses and enrollments on your WordPress site.


Create a course

Create a new LearnDash course with the given title and optional status.

Parameters

ParameterTypeRequiredDescription
titlestringYesTitle of the new course.
statusstringNoOptional publication status for the course (for example, 'publish').

Response

{
  "id": "mock_value",
  "status": "mock_value",
  "title": "mock_value"
}

Enroll a user in a course

Enroll an existing WordPress user into a LearnDash course.

Parameters

ParameterTypeRequiredDescription
learner_idstringYesID of the WordPress user to enroll.
course_idstringYesID of the LearnDash course to enroll the user in.

Response

{}

List courses

List courses from your LearnDash site, one page at a time.

Parameters

ParameterTypeRequiredDescription
pagenumberNoWhich page of results to return (defaults to 1).
per_pagenumberNoNumber of courses to return per page (defaults to 50).

Response

[
  {}
]

On this page