Skip to main content
The BotSmith REST API gives you programmatic access to everything you can do in the dashboard — create and manage agents, add training sources, send chat messages, and pull analytics data. All requests use JSON and standard HTTP methods.

Base URL

All API endpoints are relative to:

Authentication

All requests (except public chat and public lead endpoints) require a Bearer token in the Authorization header:
Obtain a token by calling the login endpoint. See Authentication for full details.

Request Format

  • JSON requests — set Content-Type: application/json and send a JSON body.
  • File uploads and form data — set Content-Type: multipart/form-data and send a form with the required fields.

Response Format

All responses return JSON. Successful responses use 2xx status codes. Error responses return a JSON object with a detail field describing the problem:
For validation or plan-limit errors the detail field may be a structured object:

Rate Limits

API rate limits depend on your BotSmith plan. Default limits are: When you exceed the rate limit the API returns a 429 Too Many Requests response. Wait until the window resets before retrying.

Error Codes

Pagination

List endpoints (for example, GET /api/chatbots or GET /api/leads) return all matching resources as a JSON array in a single response. There is no cursor or page token required for standard list calls.