Skip to content
Levr API Documentation
Download OpenAPI specOpenAPI

Hand off to an AI agent

Copy instructions to your AI agent

Copy this guide into your AI agent. It links to the current REST API and MCP documentation.

You are helping someone integrate their system with Levr. Use Levr's published documentation and machine-readable contracts as the source of truth. Do not invent endpoints, fields, or MCP tools.

  1. Start with the Levr API documentation to choose between a server-to-server REST integration and a user-authorized MCP connection.
  2. For REST, read the Markdown REST API guide, choose the user’s task, then fetch only the relevant resource guide and operation Markdown. Resource indexes include task guidance. For funding recommendations, start with the Matchmaking guide. Use the OpenAPI specification for exact paths, authentication, parameters, and envelope schemas.
  3. For REST client intake, Deal applications, or project Criteria, fetch that resource's contract_url. Its Application Contract is the authority for the current questions, stable keys, repeatable groups, file-transfer steps, accepted answer shapes, conditional visibility, supported operation URLs, and integration instructions. Repeatable fields require the returned item_id. File bytes use the expiring upload_url and multipart field named file; they never belong in JSON. Do not substitute a static example or the latest application definition.
  4. For an AI client acting with a signed-in user's access, read the MCP connection instructions in Markdown first, then the Model Context Protocol guide if needed. Let the connected MCP server expose its current tools and input contracts; do not infer tools from the REST API. Read the relevant MCP resource guide and follow the discovered tool’s revision, file-transfer, and confirmation requirements.
  5. Use URLs from the record handoff when supplied; otherwise use this documentation environment. Keep API keys and file-transfer credentials out of browser code, logs, prompts, and source control.
  6. Before implementing a write, verify authentication, required inputs, idempotency, error responses, and retry guidance in the current contract. If an operation is not documented, do not assume it exists.

Early access

Request an integration

Tell us what your integration needs to do. Add an email if you want a reply.

Choose an action to read its inputs, results, and usage guidance. Your connection determines which tools are available to you.

Find a person's CRM record, understand their relationships and permitted history, and make a deliberate change. People belong to the selected Portal and are separate from Levr login accounts and chat participants.

Discover the record

Choose provider_slug from providers.list, then call people.list with an optional search, tag, or is_archived. Follow next_cursor until it is null, preserving the query and selected Portal. Copy the returned id as person_id; it is an opaque pers_ slug, such as pers_7k2m9q4v6x8n3p5r. Never construct it from a name or email.

Call people.get_details with those selectors. The result's person contains the existing profile, assignee and tags, plus contact methods, communication choices, archive/merge status, a revision, and a stable detail_link.

Example arguments (MCP transport wrappers omitted):

{
  "provider_slug": "acme",
  "person_id": "pers_7k2m9q4v6x8n3p5r"
}

Example result excerpt:

{
  "person": {
    "id": "pers_7k2m9q4v6x8n3p5r",
    "object": "person",
    "full_name": "Alex Rivera",
    "email": "alex@example.invalid",
    "is_archived": false,
    "merged_into_id": null,
    "contact_methods": [
      {"slug": "pcm_7n2v9k4m6p3r8x5q", "kind": "email", "value": "alex@example.invalid", "label": "", "is_primary": true},
      {"slug": "pcm_2q8v4n6k9m3x7p5r", "kind": "email", "value": "alex.personal@example.invalid", "label": "Personal", "is_primary": false},
      {"slug": "pcm_5r8x2k6m9v3n7q4p", "kind": "phone", "value": "+16045550123", "label": "", "is_primary": true}
    ],
    "revision": 1768471200000000,
    "detail_link": "https://example.invalid/portal/acme/people/pers_7k2m9q4v6x8n3p5r"
  }
}

These are illustrative IDs and links. Use actual returned values; example.invalid is not a live Portal.

Read context before acting

Use people.list_relationships for businesses/deals and contextual roles, people.list_activity for permitted notes and events, and people.list_conversations for associated conversations you can currently read. Each collection is bounded and paginated; read another page with its next_cursor. Neither a person association nor a known chat ID expands your permissions.

The chat tool chain remains chat.participants and chat.messages before chat.send. A person can have multiple conversations; choose the intended audience rather than assuming one thread. Use people.link_conversation only to log an existing readable conversation. Logging it adds no recipient and grants no access.

MCP acts as the signed-in user, including their authorized private groups and direct conversations. API keys instead use a separate integration identity and public groups only. See the API People guide for that boundary.

Change CRM data safely

The original people.upsert and people.set_tags remain available for profile, assignee and tag changes. New CRM writes require expected_revision from people.get_details and a unique client_request_id. After a timeout, retry the identical call with its original request ID. Do not reuse that ID with changed inputs. On a stale conflict, read again and reconcile before retrying.

  • people.set_contact_methods replaces the complete set to retain, including the primary values. Each method has kind, value, optional label, and is_primary. Each populated kind requires exactly one primary. Ordinary edits allow 20 methods; larger merged address books can retain or remove inherited methods and edit their labels/primary choices. Changing a contact method does not rewrite authorship or redirect an existing conversation.
  • people.set_relationship changes a selected business/deal association, its role and primary designation. Copy record_id from that resource's discovery and set kind explicitly. Use remove: true only when unlinking is intended.
  • people.add_note records the user's note. It does not send a message or notify conversation participants.
  • people.set_archive uses is_archived: true to remove a record from active use, or false to restore it. History and conversation permissions are preserved. Prefer archiving for routine removal over permanent deletion.
  • people.set_communication_preferences records email/phone choices for operational/marketing purposes. Read current choices before changing them. Omitted channel/purpose pairs remain unchanged; reset a pair explicitly to unspecified. Do-not-contact overrides individual allowances; unspecified marketing is not consent. These settings do not change the user's own chat notification preferences.

Emails are trimmed/lowercased. National phone input defaults to +1 (Canada/USA); explicit international codes override that default. Complete numbers use E.164 with an optional ext. N suffix. Ask for an area code when new input is local-only; do not invent digits. Existing incomplete historical values can be retained until corrected.

Merge only after review

Use people.list_duplicates to find candidates. An address match is a suggestion for review, not proof that two humans are identical. Confirm the survivor, then call people.review_merge with the duplicate's person_id and survivor's target_id in the same Portal. Review all conflicts and effects. The target retains its chosen profile values; empty fields can be filled from the source. History and relationships are combined, and the duplicate becomes an archived record linking to the retained person.

After explicit approval, call people.merge with the same selectors, unchanged review_token, source expected_revision, and a new client_request_id. Public MCP also requires user_confirmed: true after the user reviews this exact merge. Built-in AI uses the server-owned approval flow. The review token binds state; it is not approval.

Changes to either record invalidate the review. A merge does not combine user accounts, grant conversation access, redirect message recipients, or rewrite original authorship. Keep the retained person.id for future work.

Available tools