other
Clerk MCP, CLI, and Lua Integration for AI Agents
Clerk integration docs for AI agents: MCP gateway setup, Clerk CLI commands, Lua API reference, credentials, and function schemas.
7 functions 4 read 3 write API key auth
Clerk for agents
Credentials can be configured manually in web or CLI hosts.
Use this integration from Lua code mode, the headless integrations CLI, or the KosmoKrator MCP gateway. The same package metadata powers all three surfaces.
Machine-Readable Metadata
- integration_slug
clerk- route_slug
clerk- package
clerk- auth_strategy
api_keyAPI key- cli_setup_supported
true- cli_runtime_supported
true- mcp_gateway_supported
true- lua_supported
true- supports_multi_account
true
Quick Links
Lua APIAgent-facing namespace and function reference. Clerk CLIHeadless setup and direct function calls. Clerk MCPMCP gateway setup for external clients. Submit feedbackReport missing tools, auth problems, wrong docs, or runtime issues. ContributeAdd tools or improve metadata in the integrations repo.
Clerk MCP Client Matrix
Use these pages when a specific agent client or framework needs copy-pasteable MCP setup for Clerk.
Claude Code Clerk MCP setup for Claude Code. Cursor Clerk MCP setup for Cursor. Codex Clerk MCP setup for Codex. OpenAI Agents Clerk MCP setup for OpenAI Agents SDK. Claude Agent SDK Clerk MCP setup for Claude Agent SDK. Vercel AI SDK Clerk MCP setup for Vercel AI SDK. LangChain Clerk MCP setup for LangChain. LangGraph Clerk MCP setup for LangGraph. CrewAI Clerk MCP setup for CrewAI. MCP clients Clerk MCP setup for Generic MCP Clients.
Clerk CLI Matrix
Use these pages for direct Clerk CLI workflows in scripts, CI, cron, and agent wrappers.
CI Clerk CLI for CI. Cron Jobs Clerk CLI for cron jobs. Shell Scripts Clerk CLI for shell scripts. Headless Automation Clerk CLI for headless automation. Coding Agents Clerk CLI for coding agents.
Function Catalog
| Function | Type | Parameters | Description |
|---|---|---|---|
clerk.clerk_list_users | Read read | 6 | List users from Clerk with optional filtering and pagination. Returns user IDs, emails, names, and profile details. |
clerk.clerk_get_user | Read read | 1 | Retrieve a single Clerk user by their user ID. Returns full profile details including email, name, and metadata. |
clerk.clerk_create_user | Write write | 5 | Create a new user in Clerk. Requires at least one email address. Optionally set name, password, and username. |
clerk.clerk_update_user | Write write | 4 | Update an existing Clerk user's profile. Provide the user ID and fields to update. |
clerk.clerk_delete_user | Write write | 1 | Delete a user from Clerk. This action is irreversible and will remove all associated data. |
clerk.clerk_list_organizations | Read read | 3 | List organizations from Clerk with optional filtering and pagination. Returns organization IDs, names, and metadata. |
clerk.clerk_get_current_user | Read read | 0 | Health check — verify Clerk API connectivity by fetching the first user. Returns a single user or empty result to confirm the API is reachable. |