Quick start
1. Choose your setup
- Claude Desktop / Claude.ai / Claude remote connector (recommended): use the hosted MCP endpoint directly. No Leonar API key is required; Claude redirects you to Leonar and you authorize one workspace via OAuth.
- Claude Code / Codex / Cursor / generic MCP clients that do not support OAuth remote connectors: use either Direct HTTP with a Bearer API key, or the local
@leonar/mcpNPX bridge.
2. Configure your MCP client
For Claude Desktop, prefer the remote connector tab below. The NPX package is only for local/API-key clients that need a stdio command.- Claude remote connector (recommended)
- NPX package (local/API-key fallback)
- Direct HTTP
In Claude Desktop or Claude.ai, go to Settings / Customize > Connectors, choose Add custom connector, and enter the Leonar MCP endpoint:When Claude connects without a token, Leonar advertises its OAuth metadata automatically. Claude opens Leonar’s sign-in page, you choose the workspace to share, and Leonar returns an OAuth access token scoped to that workspace.For Team and Enterprise Claude plans, an organization owner may need to add the custom connector first. Members can then connect and enable it individually.
3. Start using tools
Once connected, your AI assistant has access to the same safe workflow tools used by Leonar’s integrated AI agent, plus 4 contextual resources. Ask it things like:- “Search for backend engineers in Paris”
- “Show me the context for the Senior PM project”
- “Find sourcing candidates for this project”
Authentication
Leonar supports two authentication modes for MCP:- OAuth for Claude remote connectors. This is the recommended path for Claude Desktop and Claude.ai. Claude discovers Leonar’s OAuth metadata automatically from the MCP endpoint, redirects you to Leonar, and receives an access token scoped to one workspace.
- Bearer API keys for local/API-key clients such as Claude Code, Codex, Cursor, and generic MCP clients that do not use the OAuth connector flow.
leo_ API keys as the REST API. Pass your key as a Bearer token in the Authorization header.
Transport
The MCP server uses Streamable HTTP transport over a single endpoint (POST /api/mcp). It is stateless — no session management is required. All MCP clients that support the url transport type can connect directly.
For custom HTTP clients or manual tests, include both accepted response types:
Available resources
The server also exposes these read-only resources:| Resource URI | Description |
|---|---|
leonar://workspace/context | Workspace metadata, billing state, and lightweight counters |
leonar://accounts/connected | Active connected accounts available for sending and sourcing |
leonar://team/members | Workspace members and roles |
leonar://pipeline/templates | Pipeline templates with their stages |
Available tools
The MCP server exposes the main CRM API resources as explicit tools. Advanced sourcing and assistant memory tools are not exposed over external MCP.| Object | Tools | Scopes |
|---|---|---|
| Contacts | search_contacts, get_contact, create_contact, update_contact, delete_contact | contacts:read, contacts:write, contacts:delete |
| Companies | search_companies, get_company, create_company, update_company, delete_company | companies:read, companies:write, companies:delete |
| Projects | search_projects, get_project, create_project, update_project, delete_project, add_contact_to_project | projects:read, projects:write, pipeline:write |
| Sequences | search_sequences, get_sequence, get_sequence_steps, update_sequence_steps, list_sequence_enrollments, enroll_contacts_in_sequence, unenroll_contacts_from_sequence | sequences:read, sequences:write |
| Deals | search_deals, get_deal, create_deal, update_deal, delete_deal | deals:read, deals:write, deals:delete |
| Notes | search_notes, create_note, update_note, delete_note | notes:read, notes:write |
Tool parameters reference
Common read parameters
Contacts
Companies
Projects
Sequences
Deals
Notes
Example use cases
CRM lookup
“Find contacts at Acme and summarize their current roles.”The assistant calls
search_contacts and reads the returned contact records.Pipeline preparation
“Create a project for our new backend role and attach Acme as the client company.”The assistant can use
search_companies then create_project.Deal update
“Update this deal amount and expected close date.”Uses
update_deal with the same API key scopes as the REST API.Meeting note
“Add this call summary to the company record.”Uses
create_note with entity_type: "company".Rate limits
The MCP server shares the same base rate limit as the REST API: 2000 requests per hour.- For API-key clients, the quota is tracked per API key.
- For Claude remote connectors, the quota is tracked per OAuth authorization (
client + workspace + user). Refreshing an access token does not reset the quota.
MCP vs REST API
| MCP Server | REST API | |
|---|---|---|
| Best for | AI assistants (Claude, Cursor, Codex) | Custom integrations, scripts |
| Protocol | Model Context Protocol | HTTP REST |
| Auth | OAuth for Claude remote connectors; leo_ API keys for local/API-key MCP clients | Same leo_ API keys |
| Scopes | Same scope system | Same scope system |
| Tools | Main CRM object tools, project pipeline entry tools, sequence enrollment tools + 4 resources | 60+ endpoints (full CRUD) |