Built LMS Help Center
MCP Server

MCP Examples

Call tools/list and common Built LMS MCP tools from a backend agent.

MCP Examples

All examples call the hosted endpoint with a Bearer token issued by OAuth client credentials.

Discover Available Tools

curl -sS https://mcp.builtlms.com/mcp \
  -H "authorization: Bearer $BUILT_LMS_MCP_ACCESS_TOKEN" \
  -H 'content-type: application/json' \
  -H 'accept: application/json, text/event-stream' \
  --data '{
    "jsonrpc": "2.0",
    "id": "tools-1",
    "method": "tools/list"
  }'

The response only includes tools allowed by the token scopes and current kill-switch state.

Read Courses

curl -sS https://mcp.builtlms.com/mcp \
  -H "authorization: Bearer $BUILT_LMS_MCP_ACCESS_TOKEN" \
  -H 'content-type: application/json' \
  -H 'accept: application/json, text/event-stream' \
  --data '{
    "jsonrpc": "2.0",
    "id": "courses-1",
    "method": "tools/call",
    "params": {
      "name": "list_courses",
      "arguments": {
        "limit": 25
      }
    }
  }'

Create A User

Mutating tools require idempotency_key. Retry with the same key and same input to receive the cached successful result.

curl -sS https://mcp.builtlms.com/mcp \
  -H "authorization: Bearer $BUILT_LMS_MCP_ACCESS_TOKEN" \
  -H 'content-type: application/json' \
  -H 'accept: application/json, text/event-stream' \
  --data '{
    "jsonrpc": "2.0",
    "id": "user-1",
    "method": "tools/call",
    "params": {
      "name": "save_user",
      "arguments": {
        "email": "learner@example.com",
        "first_name": "Learner",
        "last_name": "Example",
        "role_id": 1,
        "idempotency_key": "hris-user-learner-example-20260707"
      }
    }
  }'

Add Group Members

set_group_members with op set to add is synchronous and capped at 100 user ids.

{
  "jsonrpc": "2.0",
  "id": "group-members-1",
  "method": "tools/call",
  "params": {
    "name": "set_group_members",
    "arguments": {
      "id": "00000000-0000-4000-8000-000000000001",
      "op": "add",
      "user_ids": [
        "00000000-0000-4000-8000-000000000002"
      ],
      "idempotency_key": "group-members-sync-20260707"
    }
  }
}

Handle Tool Errors

Validation errors and REST 4xx responses return a successful JSON-RPC envelope with result.isError: true. REST 5xx, timeouts, network failures, and blocked egress return JSON-RPC error.code: -32000.

On this page