Developer Docs

API Documentation

Complete reference for authentication, endpoint behavior, request contracts, response schemas, and field-level specifications.

Quick Start

Use your API domain, select the right token type, and send JSON payloads.

Base URL

https://api.chatwithlead.com

Or use your mapped custom domain.

Default Headers

JSON
{
  "Content-Type": "application/json",
  "Authorization": "Bearer <token>"
}

Reference Groups

Documentation is separated by token scope and resource domain.

Chat-Public

Endpoints for fetching and sending chat messages.

Open Section
  • GET /api/v1/chat/message
  • POST /api/v1/chat/message

Project API-Key

Project-level APIs for metadata, conversations, and leads.

Open Section
  • GET /api/v1/key/projects
  • PUT /api/v1/key/projects
  • GET /api/v1/key/projects/conversations
  • GET /api/v1/key/projects/conversations/:conversationId
  • GET /api/v1/key/projects/leads
  • PUT /api/v1/key/projects/leads/:leadId/status

Document API-Key

Document lifecycle APIs for listing, creating, updating, and deleting.

Open Section
  • GET /api/v1/key/projects/documents
  • GET /api/v1/key/projects/documents/:docId
  • POST /api/v1/key/projects/documents
  • PUT /api/v1/key/projects/documents/:docId
  • PATCH /api/v1/key/projects/documents/:docId/content
  • DELETE /api/v1/projects/:projectId/documents/:docId

Authentication Matrix

Use the token type matching the endpoint family.

SectionTokenHeader Format
Chat-PublicchatKeyAuthorization: Bearer {{chatKey}}
Project API-KeyAPI-KEYAuthorization: Bearer {{API-KEY}}
Document API-KeyAPI-KEYAuthorization: Bearer {{API-KEY}}