Programmatically manage leads, conversations, knowledge base documents, analytics, and webhooks. Integrate Synaptiq into your existing stack with a few API calls.
Public endpoints (/api/chat, /api/widget, /api/health) require no authentication.
All other endpoints require an API key. Include it as a Bearer token in the Authorization header, or authenticate via the admin token flow to obtain a session cookie.
curl https://app.synaptiq.ai/api/admin/leads \
-H "Authorization: Bearer YOUR_API_KEY"Authenticate with your admin token. Returns an HTTP-only session cookie valid for 7 days.
curl -X POST https://app.synaptiq.ai/api/admin/auth \
-H "Content-Type: application/json" \
-d '{"token": "your-admin-token"}'Create, retrieve, update, and search leads captured by the Synaptiq chat agent. All leads endpoints require authentication.
Retrieve all leads, ordered by creation date (newest first).
curl https://app.synaptiq.ai/api/leads \
-H "Authorization: Bearer YOUR_API_KEY"{
"leads": [
{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Jane Smith",
"email": "jane@example.com",
"company": "Acme Corp",
"status": "qualified",
"qualificationScore": 78,
"createdAt": "2026-04-01T14:30:00.000Z"
}
]
}Retrieve a single lead by ID.
curl https://app.synaptiq.ai/api/leads/550e8400-e29b-41d4-a716-446655440000 \
-H "Authorization: Bearer YOUR_API_KEY"Create a new lead manually.
curl -X POST https://app.synaptiq.ai/api/admin/leads \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Jane Smith",
"email": "jane@example.com",
"company": "Acme Corp"
}'| Field | Type | Required | Description |
|---|---|---|---|
| name | string | Yes | Contact name (1-200 chars) |
| string | Yes | Valid email address | |
| phone | string | No | Phone number (max 50 chars) |
| company | string | No | Company name (max 200 chars) |
| metadata | object | No | Arbitrary JSON |
Update a lead's profile fields.
curl -X PATCH https://app.synaptiq.ai/api/leads/550e8400... \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"status": "booked", "qualificationScore": 92}'| Status | Description |
|---|---|
| new | Lead created, no qualification started |
| qualifying | Conversation in progress |
| qualified | Meets qualification criteria |
| booked | Meeting scheduled |
| disqualified | Does not meet criteria |
| nurturing | Not ready now, follow up later |
Full-text search across lead names, emails, and companies.
curl "https://app.synaptiq.ai/api/leads?q=acme" \
-H "Authorization: Bearer YOUR_API_KEY"Access the full message history of AI chat conversations.
List all conversations for a lead, ordered by most recent first.
curl https://app.synaptiq.ai/api/leads/550e8400.../conversations \
-H "Authorization: Bearer YOUR_API_KEY"Get a conversation with its full message history.
curl https://app.synaptiq.ai/api/conversations/660e8400... \
-H "Authorization: Bearer YOUR_API_KEY"{
"conversation": {
"id": "660e8400-e29b-41d4-a716-446655440000",
"leadId": "550e8400-e29b-41d4-a716-446655440000",
"channel": "web_chat",
"status": "completed",
"summary": "Prospect asked about pricing and integration.",
"messages": [
{
"role": "assistant",
"content": "Hey there! What brings you here today?",
"createdAt": "2026-04-01T14:30:01.000Z"
},
{
"role": "user",
"content": "I need help handling inbound leads faster.",
"createdAt": "2026-04-01T14:30:15.000Z"
}
]
}
}Upload, list, and manage documents that the AI agent uses to answer questions. Supports PDF, DOCX, and plain text formats.
Upload a document to the knowledge base. The content is automatically parsed and indexed.
curl -X POST https://app.synaptiq.ai/api/admin/knowledge-base \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"title": "Product FAQ",
"content": "Q: What is Synaptiq?\nA: An AI-powered SDR agent...",
"type": "faq"
}'List all documents in the knowledge base.
curl https://app.synaptiq.ai/api/admin/knowledge-base \
-H "Authorization: Bearer YOUR_API_KEY"Remove a document from the knowledge base. The AI agent will no longer reference it.
curl -X DELETE https://app.synaptiq.ai/api/admin/knowledge-base/doc-id \
-H "Authorization: Bearer YOUR_API_KEY"Access performance metrics, funnel data, and daily activity for your pipeline.
High-level performance metrics.
curl https://app.synaptiq.ai/api/analytics/overview \
-H "Authorization: Bearer YOUR_API_KEY"| Field | Description |
|---|---|
| totalLeads | Total number of leads captured |
| totalConversations | Total conversations across all leads |
| avgMessagesPerConversation | Average message count per conversation |
| conversionRate | Percentage of leads that reached qualified or booked |
Lead distribution by qualification status.
{
"funnel": {
"new": 45,
"qualifying": 32,
"qualified": 28,
"booked": 21,
"disqualified": 12,
"nurturing": 4
}
}Daily lead creation counts for the last 30 days. Days with no activity return a count of 0.
{
"activity": [
{ "date": "2026-03-06", "count": 3 },
{ "date": "2026-03-07", "count": 7 },
{ "date": "2026-03-08", "count": 0 }
]
}Receive real-time notifications when events happen in your Synaptiq account. Configure webhook URLs in your dashboard under Settings → Webhooks.
All webhook payloads follow the same envelope format:
{
"event": "lead.created",
"timestamp": "2026-04-01T14:30:00.000Z",
"data": {
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Jane Smith",
"email": "jane@example.com",
"company": "Acme Corp",
"status": "new",
"qualificationScore": 0
}
}Each webhook request includes an X-Synaptiq-Signature header containing an HMAC-SHA256 signature of the request body using your webhook secret.
import crypto from 'crypto';
function verifyWebhook(body, signature, secret) {
const expected = crypto
.createHmac('sha256', secret)
.update(body)
.digest('hex');
return crypto.timingSafeEqual(
Buffer.from(signature),
Buffer.from(expected),
);
}If your endpoint returns a non-2xx status code or times out (30s), Synaptiq retries with exponential backoff: 1 min, 5 min, 30 min, 2 hours, 24 hours. After 5 failed attempts the event is dropped and logged in your dashboard.
| Attempt | Delay |
|---|---|
| 1 | Immediate |
| 2 | 1 minute |
| 3 | 5 minutes |
| 4 | 30 minutes |
| 5 | 2 hours |
| 6 | 24 hours (final) |
Get Synaptiq running on your site in under 2 minutes.
<script
src="https://app.synaptiq.ai/widget.js"
data-tenant="YOUR_TENANT_ID"
></script>// Listen for Synaptiq events
window.addEventListener('synaptiq:lead.qualified', (e) => {
console.log('Lead qualified:', e.detail);
// Push to your CRM, trigger a Slack notification, etc.
});
window.addEventListener('synaptiq:meeting.booked', (e) => {
console.log('Meeting booked:', e.detail);
});SynaptiqWidget API to open, close, or update the widget at runtime.// Open the chat when a CTA button is clicked
document.getElementById('talk-to-ai')
.addEventListener('click', () => SynaptiqWidget.open());
// Dynamically switch tenant
SynaptiqWidget.setTenant('new-tenant-id');
// Remove the widget entirely
SynaptiqWidget.destroy();Requests are rate-limited per API key based on your plan tier. Exceeding the limit returns a 429 Too Many Requests response with a Retry-After header.
| Header | Description |
|---|---|
| X-RateLimit-Limit | Max requests allowed per window |
| X-RateLimit-Remaining | Requests remaining in current window |
| X-RateLimit-Reset | Unix timestamp when the window resets |
| Retry-After | Seconds until you can retry (only on 429) |
All errors return a JSON body with an error field.
{
"error": "Description of what went wrong"
}| Status | Meaning | Common causes |
|---|---|---|
| 400 | Bad Request | Missing required fields, validation error |
| 401 | Unauthorized | Invalid or missing API key / session cookie |
| 404 | Not Found | Resource does not exist |
| 429 | Rate Limited | Too many requests; check Retry-After header |
| 503 | Service Unavailable | External API key not configured or downstream service down |
/api/health endpoint to confirm database and service connectivity.