synaptiq Live demo
  • How It Works
  • Pricing
  • Blog
  • FAQ
Start Free Pilot
synaptiq

AI-powered sales agent that qualifies leads and books meetings autonomously.

Product
  • How It Works
  • Pricing
  • FAQ
Resources
  • Blog
  • Docs
  • API Reference
  • Embed Guide
Legal
  • Privacy Policy
  • Terms of Service
  • Cookie Policy
2026 Synaptiq. All rights reserved.
Back to home
API Reference

Synaptiq API

Programmatically manage leads, conversations, knowledge base documents, analytics, and webhooks. Integrate Synaptiq into your existing stack with a few API calls.

Base URLhttps://app.synaptiq.ai

Authentication

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"
API Key Management
Generate and revoke API keys from your Synaptiq dashboard under Settings → API Keys. Keys are scoped to your tenant and inherit your admin permissions.

Session-based Authentication

POST/api/admin/auth

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"}'

Leads API

Create, retrieve, update, and search leads captured by the Synaptiq chat agent. All leads endpoints require authentication.

GET/api/leads

Retrieve all leads, ordered by creation date (newest first).

curl https://app.synaptiq.ai/api/leads \
  -H "Authorization: Bearer YOUR_API_KEY"
Response
{
  "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"
    }
  ]
}
GET/api/leads/:id

Retrieve a single lead by ID.

curl https://app.synaptiq.ai/api/leads/550e8400-e29b-41d4-a716-446655440000 \
  -H "Authorization: Bearer YOUR_API_KEY"
POST/api/admin/leads

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"
  }'
FieldTypeRequiredDescription
namestringYesContact name (1-200 chars)
emailstringYesValid email address
phonestringNoPhone number (max 50 chars)
companystringNoCompany name (max 200 chars)
metadataobjectNoArbitrary JSON
PATCH/api/leads/:id

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}'
StatusDescription
newLead created, no qualification started
qualifyingConversation in progress
qualifiedMeets qualification criteria
bookedMeeting scheduled
disqualifiedDoes not meet criteria
nurturingNot ready now, follow up later
GET/api/leads?q=search+term

Full-text search across lead names, emails, and companies.

curl "https://app.synaptiq.ai/api/leads?q=acme" \
  -H "Authorization: Bearer YOUR_API_KEY"

Conversations API

Access the full message history of AI chat conversations.

GET/api/leads/:id/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/api/conversations/:id

Get a conversation with its full message history.

curl https://app.synaptiq.ai/api/conversations/660e8400... \
  -H "Authorization: Bearer YOUR_API_KEY"
Response
{
  "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"
      }
    ]
  }
}

Knowledge Base API

Upload, list, and manage documents that the AI agent uses to answer questions. Supports PDF, DOCX, and plain text formats.

POST/api/admin/knowledge-base

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"
  }'
GET/api/admin/knowledge-base

List all documents in the knowledge base.

curl https://app.synaptiq.ai/api/admin/knowledge-base \
  -H "Authorization: Bearer YOUR_API_KEY"
DELETE/api/admin/knowledge-base/:id

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"

Analytics API

Access performance metrics, funnel data, and daily activity for your pipeline.

GET/api/analytics/overview

High-level performance metrics.

curl https://app.synaptiq.ai/api/analytics/overview \
  -H "Authorization: Bearer YOUR_API_KEY"
FieldDescription
totalLeadsTotal number of leads captured
totalConversationsTotal conversations across all leads
avgMessagesPerConversationAverage message count per conversation
conversionRatePercentage of leads that reached qualified or booked
GET/api/analytics/funnel

Lead distribution by qualification status.

Response
{
  "funnel": {
    "new": 45,
    "qualifying": 32,
    "qualified": 28,
    "booked": 21,
    "disqualified": 12,
    "nurturing": 4
  }
}
GET/api/analytics/activity

Daily lead creation counts for the last 30 days. Days with no activity return a count of 0.

Response
{
  "activity": [
    { "date": "2026-03-06", "count": 3 },
    { "date": "2026-03-07", "count": 7 },
    { "date": "2026-03-08", "count": 0 }
  ]
}

Webhooks

Receive real-time notifications when events happen in your Synaptiq account. Configure webhook URLs in your dashboard under Settings → Webhooks.

Event Types

lead.created
Fired when a new lead is captured from chat or created via the API.
lead.qualified
Fired when a lead's status changes to "qualified" based on conversation signals.
meeting.booked
Fired when the AI agent successfully books a discovery meeting.

Payloads

All webhook payloads follow the same envelope format:

Payload
{
  "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
  }
}

Signature Verification

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),
  );
}

Retry Policy

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.

AttemptDelay
1Immediate
21 minute
35 minutes
430 minutes
52 hours
624 hours (final)

SDK Quickstart

Get Synaptiq running on your site in under 2 minutes.

  1. 1
    Install the widget
    Add the embed script to your site. No npm package required for the basic widget.
<script
  src="https://app.synaptiq.ai/widget.js"
  data-tenant="YOUR_TENANT_ID"
></script>
  1. 2
    Listen for events
    React to lead qualification and meeting events from the widget.
// 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);
});
  1. 3
    Control programmatically (optional)
    Use the global 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();
Full embed guide
For advanced configuration options (position, theme, greeting message), see the Embed Integration Guide.

Rate Limits

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.

Starter
100
requests / minute
Growth
500
requests / minute
Enterprise
2,000
requests / minute
HeaderDescription
X-RateLimit-LimitMax requests allowed per window
X-RateLimit-RemainingRequests remaining in current window
X-RateLimit-ResetUnix timestamp when the window resets
Retry-AfterSeconds until you can retry (only on 429)

Error Codes

All errors return a JSON body with an error field.

Error format
{
  "error": "Description of what went wrong"
}
StatusMeaningCommon causes
400Bad RequestMissing required fields, validation error
401UnauthorizedInvalid or missing API key / session cookie
404Not FoundResource does not exist
429Rate LimitedToo many requests; check Retry-After header
503Service UnavailableExternal API key not configured or downstream service down
Troubleshooting
If you receive persistent 503 errors, verify that your OpenAI API key is configured in the Synaptiq dashboard. Check the /api/health endpoint to confirm database and service connectivity.