Your first customer chat bot needs a narrow job
A customer chat bot is a chat window connected to an AI model and, ideally, reliable information about your business. The model reads a conversation and writes a reply. Your application decides which information it receives, which actions it can request, and when a person should take over.
Start with one useful task: answering questions about shipping, explaining a return policy, or helping customers find setup instructions. Avoid launching with a promise to handle everything. A small, well-defined support job is easier to test and safer to put in front of customers.
Give Sonnet and Haiku clear support roles
Claude Haiku 4.5 can be a starting point for tightly scoped conversations, such as identifying a question’s topic or answering from a short approved help document. Claude Sonnet 5.5 is worth testing for conversations that require combining several policy details or working through an unclear customer request.
These are starting roles, not guarantees. Test both against your own support examples before choosing. You can launch with one model, then add routing later. Routing simply means your application selects a model according to rules you define, such as sending policy exceptions to a more carefully evaluated workflow.
Connect the chat window to trusted answers
The basic path is straightforward: a customer sends a message, your server gathers relevant information, and your server sends that context to the model. The reply returns through your server to the chat window. Keep API credentials on the server, never in browser code.
For a practical connection layer, SwiftRelay provides pay-as-you-go access to these models through an OpenAI-compatible SDK. Set the SDK base URL to https://api.fastapirelay.com/v1, store your API key securely, and use the exact model identifier shown in your relay account. Sign up for SwiftRelay to use the small gift credit for an initial support test.
The relay connects your application to the model; it does not automatically supply your store policies or customer records. Your application still needs to retrieve relevant help content and control access to private data.
Write support instructions that limit guessing
A good instruction tells the bot what it supports, which sources it may use, and what to do when information is missing. For example: answer shipping questions from the supplied policy, ask for the destination country when needed, and hand off questions the policy does not cover.
- Use approved information: supply relevant help articles rather than asking the model to recall your business policies.
- Admit missing details: never invent delivery dates, refund approvals, or account status.
- Protect customer data: require authentication before retrieving private order information.
- Separate replies from actions: a written promise must not automatically trigger a refund or account change.
Treat customer messages and retrieved documents as information, not permission to override your support rules. Your server should validate every requested action independently.
Make human handoff part of the first release
A useful bot needs an exit route. Offer a human handoff when a customer asks for one, when the approved information cannot resolve the issue, or when a case involves sensitive account changes. Tell the customer what happens next without inventing a response deadline.
Pass the human agent a short conversation summary and the unresolved question. Include only necessary customer information. This helps avoid making the customer repeat the entire problem.
Check answers and token costs before launch
Build a test set from realistic questions, including vague requests, missing order details, policy exceptions, and attempts to bypass rules. Check factual accuracy, appropriate clarification, privacy protection, and successful handoffs. Repeat the checks whenever you change instructions, documents, or models.
SwiftRelay bills per token. Tokens are pieces of text processed as input and generated as output. Long conversation histories and large pasted documents can increase usage, so retrieve only relevant passages and keep answers focused.
For the first release, keep the bot’s job narrow and review unresolved conversations. Expand only after your tests show that customers receive grounded answers and a clear path to human help.