30 days free. No credit card. Full access from the moment you connect your site.

Start free trial

LearnDash Set Enrollment Date

learndash/set-enrollment-date sets the date a learner’s access to a course began.

It is not a cosmetic field.

At a glance

Abilitylearndash/set-enrollment-date
ToolsetLearnDash — toolset/learndash
GroupLearnDash › Enrolment & Access
RequiresAcrossAI Pro, plus LearnDash LMS active on the site
Capabilitymanage_options
SafetyWrites data
RepeatableIdempotent — running it twice leaves the same result
Ships inAcrossAI Pro 0.9.16 and later

Two things are computed from this date

Drip-feed lesson release is the first. A lesson set to appear thirty days after enrolment appears thirty days after this date, so backdating an enrolment by two months releases everything at once.

Access expiry is the second. A course with a ninety-day access window expires ninety days after this date — so backdating far enough expires access immediately, and the learner loses the course as a result of what looked like a record correction.

The response reports the recomputed expiry and whether access is now expired, which is the only warning before somebody notices.

Both consequences are legitimate uses as well as accidents: releasing a drip-fed course to a learner who joined late is exactly this operation.

Accepts a Unix timestamp or a UTC date string such as 2026-01-31 or 2026-01-31 09:00:00.

The learner must already be enrolled. Enrol first.

Idempotent.

Input

NameTypeRequiredWhat it is
learnerstring | integerYesUser ID, login or email.
course_idintegerYesThe course.
datestring | integerYesA Unix timestamp, or a UTC date string.

What comes back

NameTypeWhat it is
access_fromstringThe date as stored.
expiresstringThe recomputed expiry.
expiredbooleanWhether access is now expired.
successbooleanWhether the call completed.
messagestringA one-line summary of what happened, suitable for showing a human.
error_codestringPresent only on failure — a stable machine-readable reason, such as a missing field, a wrong field type or an unmet confirmation.

Example

Ask your assistant:

Backdate this learner’s enrolment to when they actually started.

It resolves to one call:

{
  "ability": "learndash/set-enrollment-date",
  "parameters": {
    "learner": "sam@example.com",
    "course_id": 412,
    "date": "2026-01-31"
  }
}

Worth knowing

  • Drip-feed release and access expiry are both computed from this date.
  • Backdating can release everything at once, or expire access immediately.
  • The response reports the recomputed expiry — read it.
  • The learner must already be enrolled.

Related abilities


Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager

Browse the rest: Every ability, by category


Keep reading