Skip to main content
Glama

LearnWorlds MCP by usefulapi

Enroll a user in a product

learnworlds_enroll_user
Destructive

WRITE: manually enroll a user in a course, bundle or subscription. This grants access and records a manual enrollment at the given price (use 0 for a free grant) — it does not charge the learner's card. Optionally emails the learner. LearnWorlds: POST /v2/users/{id}/enrollment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
userYesThe user's id, or their email address.
priceYesPrice recorded for this enrollment; 0 for a free grant.
durationNoSubscriptions only: how many duration_type units.
product_idYesThe product id (for a course, its slug).
product_typeYes
duration_typeNoSubscriptions only.
justificationNoA note, e.g. "Added by admin".
send_enrollment_emailNoSend the enrollment email to the learner.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. First observed

TDQS

A4.2/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The annotation only gives destructiveHint=true; the description goes further by explaining that enrollment grants access, records a manual enrollment at the given price, does not charge the card, and may email the learner — all meaningful behavioral detail. It stops short of covering repeat/idempotent enrollment or permission requirements.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two tight sentences, front-loaded with the WRITE prefix and the core action, with no redundant or filler content. Every clause (no card charge, optional email, endpoint) earns its place.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter mutation with no output schema, the description covers effect, pricing semantics, and side effects (email) well. It omits what the call returns and how duplicate enrollments are handled, which keeps it just below fully complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is already 88%, so the schema documents user, price, duration, duration_type, product_id, justification, and send_enrollment_email. The description's only added nuance ("use 0 for a free grant") duplicates the schema's price description, so the baseline 3 applies.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Specific verb (enroll) plus resource (a user into a course, bundle or subscription) with the WRITE marker up front. It is clearly distinguishable from siblings like learnworlds_add_user_to_group or learnworlds_create_user, and it even names the underlying endpoint.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

"manually enroll" plus "it does not charge the learner's card" tells the agent this is an admin/free-grant path rather than a purchase flow, which is real usage context. However it never names an alternative tool or states an explicit when-not condition, so it falls short of 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.