learndash/query-activity is the general reporting query across LearnDash activity: who started or completed what, and when.
It reads the same data source as LearnDash’s own reporting screens, so the numbers agree with what an administrator sees.
At a glance
| Ability | learndash/query-activity |
| Toolset | LearnDash — toolset/learndash |
| Group | LearnDash › Reporting |
| Requires | AcrossAI Pro, plus LearnDash LMS active on the site |
| Capability | manage_options |
| Safety | Writes data |
| Repeatable | Idempotent — running it twice leaves the same result |
| Ships in | AcrossAI Pro 0.9.16 and later |
How it works
That agreement matters more than it sounds. A report computed a different way produces numbers that are defensible and do not match the admin screen, and reconciling the two is work nobody wants.
Filter by courses, users, groups, step type — course, lesson, topic, quiz or access — and completion status, and narrow by date range.
The step type filter is what makes this more than a completion report. access records enrolment events rather than progress, so “who gained access in March” is the same query with a different type.
Users can be given as IDs, logins or emails, which matters when the list came from somewhere other than the site.
For one learner in one course, learndash/get-user-progress is more direct and returns the per-step breakdown this does not.
Input
| Name | Type | Required | What it is |
|---|---|---|---|
courses | array | No | Course IDs to include. |
users | array | No | User IDs, logins or emails. |
groups | array | No | Group IDs to include. |
step_type | string | No | course, lesson, topic, quiz or access. |
status | string | No | Completion status. |
from | string | No | Start of the date range. |
to | string | No | End of the date range. |
What comes back
| Name | Type | What it is |
|---|---|---|
activity | array | Matching activity records. |
total | integer | How many matched. |
success | boolean | Whether the call completed. |
message | string | A one-line summary of what happened, suitable for showing a human. |
error_code | string | Present 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:
Who completed anything last month?
It resolves to one call:
{
"ability": "learndash/query-activity",
"parameters": {
"step_type": "course",
"status": "completed",
"from": "2026-08-01",
"to": "2026-08-31"
}
}Worth knowing
- Same data source as LearnDash’s own reporting, so the numbers reconcile.
accessrecords enrolment events rather than progress.- Users can be addressed by email.
- For one learner in one course, the progress read is more direct.
Related abilities
- LearnDash Course Progress Report — one course’s cohort
- LearnDash Get User Progress — one learner in detail
Get the plugins:
AcrossAI Abilities Manager · AcrossAI MCP Manager
Browse the rest: Every ability, by category