NUWAY API
NUWAY API
The NUWAY API is a REST API over HTTPS with JSON request and response bodies. It gives your systems the same AI workers, knowledge, plan and billing as your dashboard and website widget.
Base URL
https://ai.nuway.co/api/v1/externalAll endpoints in this documentation are relative to this base URL. The version, v1, is part of the path.
Authentication
Send your API key in the X-API-KEY header on every request. See Authentication and API keys.
Resources
| Resource | What you can do |
|---|---|
| Chat | Send a customer's message to your AI workers and get the reply, in a new or an existing conversation. |
| Conversations | List conversations from every channel, and read one with its messages. |
| Leads | List scored leads and read one lead. |
| Team members | List the people customers can book meetings with. |
| Meetings | List meetings, find free time slots and cancel meetings. |
| Knowledge | List training data, upload documents and add, update or delete FAQs. |
See the API reference for every endpoint.
Conventions
- JSON request and response bodies, UTF-8. File uploads use
multipart/form-data. - List endpoints are paginated. See Requests and responses.
- Errors return an HTTP status and a JSON body with
detail. See Errors and rate limits. - Requests count against a per-company rate limit, and chat replies are billed like website chat replies. See Usage limits and billing.
Server-side only
The API key gives full access to your company's conversations, leads and training data. Call the API from your server, never from browser JavaScript or mobile apps. See Security.
In this section
API referenceEvery NUWAY API endpoint by resource: chat, conversations, leads, team members, meetings and knowledge.Requests and responsesBase URL, formats, timestamps, time zones, timeouts and pagination for the NUWAY API.Errors and rate limitsHTTP status codes, error bodies and rate limits of the NUWAY API, and how to handle them.Usage and billingHow NUWAY API usage is billed against your plan and wallet, and what happens when nothing can pay for a reply.SecurityKeep your NUWAY API key safe: where to store it, how to call the API from a browser app, and when to rotate the key.Code examplesComplete, copyable NUWAY API examples: a server-side chat relay and small helpers in cURL, JavaScript and Python.