unLocked CRM API Documentation for Every System Your Agency Runs.

A shared API for your CRM records, an API key or OAuth 2.0 with 20 scopes, 27 signed webhook events, JSON errors with stable codes, and a published OpenAPI 3.1 spec. Now also manage contacts and messages, run live quotes and underwriting, send branded quote PDFs, track opens, and share intake and booking links. These API actions power the connected AI tools on Pro.

Create a lead

curl -X POST 'https://gzigyepfasiumngxilai.supabase.co/functions/v1/public-api?resource=leads' \
  -H 'x-api-key: sk_live_xxxxxxxxxxxx' \
  -H 'Content-Type: application/json' \
  -d '{
    "first_name": "Jane",
    "last_name": "Doe",
    "email": "jane@example.com",
    "phone": "+15551234567",
    "source": "Website",
    "income": "85000",
    "custom_fields": { "preferred_contact_time": "Evenings" }
  }'

Response 200 OK

{
  "data": {
    "id": "7f3a9c2e-…",
    "first_name": "Jane",
    "household_income": "85000",
    "source": "Website",
    "created_at": "2026-09-03T14:20:00Z"
  }
}

The income field was rewritten to household_income on write, and the custom field matched by name.

How Every Call Works.

One shape for every resource, so the client you write for leads works for policies and commissions.

01

One base URL

Every call goes to the functions origin, not the app domain. The app runs at app.unlockedcrm.ai; the API runs at the base URL below.

https://gzigyepfasiumngxilai.supabase.co/functions/v1

02

One endpoint, one parameter

GET, POST, PUT, and DELETE against /public-api, with the record type in the resource query parameter and the id for single-record calls.

/public-api?resource=leads&id=…

03

List, filter, sort, search

GET accepts limit (max 100, default 50), offset, sort as field:dir, fields, search, and status, so a sync pulls only what changed.

?resource=policies&status=active&sort=renewal_date:asc&limit=100

04

Field aliases on leads

Common names are rewritten on write: income to household_income, dob to date_of_birth, zipcode to zip_code, mobile to phone. Unknown keys match your custom fields by name.

{ "dob": "1961-04-02", "zipcode": "80202" }

Twenty-Five Resources, One Query Parameter.

Every record type the CRM stores, addressable by name. Two meta resources sit beside them: health, which needs no auth, and whoami, which returns the workspace, plan, and scopes your key resolves to.

leads
clients
activities
tasks
policies
appointments
communications
webhooks
pipelines
pipeline_stages
opportunities
workflows
email_campaigns
commissions
aca_leads
agent_ai_call_logs
agent_ai_scripts
agent_ai_campaigns
quotes
tags
call_recordings
call_disposition_logs
agent_presence
inbound_campaigns
inbound_vendors

Authenticate Two Ways.

A key for your own systems, OAuth for apps that act on behalf of a user. Both are scoped to the resources and actions you allow.

API key

Created in Settings, then API, and sent as the x-api-key header. Each key carries per-resource read, create, update, and delete permissions, supports IP allowlisting, and is limited to 100 requests per minute.

x-api-key: sk_live_…

OAuth 2.0 with 20 scopes

Authorization code flow, with discovery at the standard well-known paths. A read and a write scope for each of the ten resource groups, so an app that only reports never gets write.

read:contacts · write:contactsread:leads · write:leadsread:policies · write:policiesread:quotes · write:quotesread:commissions · write:commissionsread:tasks · write:tasksread:appointments · write:appointmentsread:activities · write:activitiesread:communications · write:communicationsread:agent_ai · write:agent_ai

Signed webhooks

Verify every event before your systems act on it.

100 requests per minute

Per key, with Retry-After on the 429 so a sync backs off instead of failing.

HIPAA infrastructure

The API runs on the same HIPAA-compliant infrastructure as the CRM, with a BAA available.

Twenty-Seven Webhook Events, Signed.

Subscribe through the webhooks resource and your systems hear about the change the moment it happens, instead of polling for it.

Leads and clients

lead.createdlead.updatedlead.deletedlead.status_changedclient.createdclient.updated

Tasks and appointments

task.createdtask.completedappointment.createdappointment.cancelledactivity.created

Policies, quotes, and commissions

policy.createdpolicy.renewedquote.savedcommission.createdcommission.updated

Pipeline and campaigns

opportunity.createdopportunity.updatedopportunity.stage_changedworkflow.activatedworkflow.deactivatedemail_campaign.sentemail_campaign.completed

SMS

sms.sentsms.receivedsms.deliveredsms.failed

Every Error Is JSON, Never an HTML Page.

A stable code to branch on, a message for a person, whether to retry, and how to fix it. The catalog is also machine-readable at /api/errors.json.

HTTP/1.1 403 Forbidden
Content-Type: application/json

{
  "error": {
    "code": "permission_denied",
    "message": "Permission denied for this resource or action.",
    "status": 403,
    "retryable": false,
    "resolution": "Request the scope named in error.required_scope and retry.",
    "required_scope": "write:leads",
    "request_id": "req_01J9ZC7Q2X5T",
    "docs_url": "https://unlockedcrm.ai/api#errors"
  }
}
CodeHTTPRetryResolve
invalid_request400NoFix the resource parameter or required body fields.
unauthenticated401NoSend a valid x-api-key header or a bearer token.
permission_denied403NoRequest the scope named in error.required_scope.
not_found404NoVerify the id; do not retry the same request.
conflict409OnceRe-fetch the record, merge, and retry once.
validation_failed422NoRead error.details[] and correct the named fields.
rate_limited429YesWait Retry-After or error.retry_after_seconds, then back off.
internal_error500YesRetry with exponential backoff; quote error.request_id to support.
upstream_error502YesA carrier or provider API failed. Retry with backoff.

What Agencies Build With It.

Reporting warehouse

Pull policies, commissions, lead sources, and pipeline activity into your BI stack on a schedule, or on every commission.updated event.

Partner or agent portal

Let partners create leads, read status, and submit updates without a CRM login. Lead field aliases mean their form fields map without a translation layer.

Commission operations

Match carrier payment files against expected commissions from the commissions resource and flag exceptions in your finance system.

Enrollment workflow engine

Subscribe to policy.created and appointment.created, then create tasks, notify the team, and update the opportunity stage from your own service.

The API, the MCP Server, or the Tool Manifest?

Same data, three doors, picked by who is calling.

The API, for systems

REST access with webhooks, for syncs, dashboards, portals, and partner tools. You are here.

The MCP server, for assistants

Permission-controlled contact, messaging, quote, underwriting, and link actions at mcp.unlockedcrm.ai that Claude, Cursor, ChatGPT, and Codex call in conversation.

See the MCP server

The tool manifest, for function calling

Six ready-made OpenAI and Anthropic function definitions: list, get, create, update, and delete records, plus whoami.

Open tools.json

openapi.json·api.md·errors.json·Developer portal

API FAQ

Can I run insurance quotes through the API?

Yes. On Pro, the API runs live quotes for Life and Final Expense, Medicare Advantage, Supplement and Part D, ACA and private health, and ancillary lines, saves the quote to the client record, and sends it to the client. Annuity quoting is not included. Starting the application from a quote is coming soon. See unlockedcrm.ai/quote-from-ai-tools.

Does unLocked CRM have a public REST API?

Yes. One endpoint, /public-api, serves CRM resources (leads, clients, policies, quotes, commissions, tasks, appointments, activities, communications, pipelines, opportunities, workflows, campaigns, tags, call recordings, Agent AI logs, and more) over GET, POST, PUT, and DELETE, with the record type in the resource query parameter. The OpenAPI 3.1 spec is published at unlockedcrm.ai/openapi.json.

How do I authenticate?

Two ways. An API key created in Settings, then API, sent as the x-api-key header, with per-resource read, create, update, and delete permissions, optional IP allowlisting, and a limit of 100 requests per minute. Or OAuth 2.0 with 20 named scopes, a read and a write scope for each of contacts, leads, policies, quotes, commissions, tasks, appointments, activities, communications, and Agent AI.

Can I receive webhooks?

Yes. Subscribe through the webhooks resource to 27 events across leads, clients, tasks, appointments, activities, policies, quotes, commissions, opportunities, workflows, email campaigns, and SMS. Events are signed so your receiver can verify them before acting.

What do errors look like?

Every non-2xx response is JSON, never an HTML page. The envelope carries a stable error.code to branch on, a human message, the HTTP status, whether it is retryable, a resolution hint, and a request_id for support. The nine codes and their retry rules are on this page and in the machine-readable catalog at unlockedcrm.ai/api/errors.json.

How is the API different from the MCP server?

The API is for systems: syncs, dashboards, portals, and partner tools that need REST endpoints and webhooks. The MCP server at mcp.unlockedcrm.ai is for AI assistants like Claude, Cursor, and ChatGPT, exposing permission-controlled contact, messaging, quote, underwriting, and link actions they can call in conversation. There is also a six-function tool manifest for OpenAI and Anthropic function calling at unlockedcrm.ai/.well-known/tools.json.

Is there a spec I can import?

Yes. The full OpenAPI 3.1 spec is at unlockedcrm.ai/openapi.json, a slim public subset is at /.well-known/openapi.json, a YAML copy is at /openapi.yaml, and a Swagger 2 copy is at /swagger.json. The agent-readable Markdown reference is at /api.md.

Live On Pro And Max · October 2026

One API, The Same Connected Actions

The unLocked API powers the secure AI connection. Your preferred AI tool accesses these supported actions through that connection, within your permissions and plan—not a separate, smaller set of CRM features.

unLocked stays the system of record. Customer data is never used to train AI. Starting an application from a quote is coming soon; annuity quoting is not included.

Daily Priorities And Contact Profiles

Daily Priorities
Review missing replies, unread messages, scheduled appointments, notes, and memories to decide what to work on today.
Whole Contact Profile
Pull the whole contact profile in one call, including details, tags, notes, memories, messages, calls, quotes, and documents.

Contacts

Leads
List, search, get one, create, update, find duplicates, scan the workspace for duplicates, and merge.
Clients
List, search, get one, create, update, and bulk create.
Tags
List definitions, create, list a contact's tags, add, and remove.
Notes And Memories
List, add, and edit both.
Documents
List, upload, link an external file, delete, and download email attachments.
Messages
Text and email history, send a text or email, reply in a thread, schedule a message, and edit or cancel a scheduled one.
Calls
Recordings with playback link, dispositions, and voicemails.
Activities And Communications
List and log.
Lead Scores
List and re-score.
Custom Fields And Sections
List, create, and update definitions.

Quotes

Live Quotes
From plain details for life, Medicare Advantage, Part D, ACA, Medicare Supplement, dental-vision-hearing, and hospital indemnity.
Saved Quotes
List by contact or workspace, get one, save, file on a contact, favorite, note, change status, unfile, and delete.
Send As A Branded PDF
By email or text, now or scheduled, with saved wording and a chosen mailbox. Or get the PDF link without sending.
Scheduled Sends
List, reschedule, and cancel.
Quote Opens
See when a client opened a quote.
Saved Wording
Email and text wording per product: list, create, and update.
Underwriting
Run and save an assessment, list assessments, quote from an assessment, and get a case report PDF link.

Intake, Quote, And Booking Links

All Sendable Links
Retrieve all sendable links in one call, including the default Medicare intake, ACA intake, and Medicare quote links.
Booking Links
List, get, and create, with the public URL.
Intake And Medicare Quote Campaign Links
List, get, and create, with the public URL.
Life Quote Links
List and get, with the public URL.
Send Any Link
Send any link to a contact by text or email.

New In November 2026

Recently shipped here. Every release is on the Product Updates page.

Public API Expansion

The public API adds recruiting, calendars, bookings, templates, webhooks, UTM fields, and key rotation.