Integrate AI Chatbot Feature

via Freelancer ·

Budget / Salary$30–250
TypeFreelance project
LocationRemote
Posted1 hour ago
I have a production Node.js / React application and need to fold in a lightweight AI-powered chatbot. The user will type messages inside an existing text box, those messages must travel securely to either OpenAI or Claude, and the conversational reply should flow back into the current UI exactly where a normal system response appears.

Scope of work
• Wire the front-end component to my backend route without ever exposing the API key client-side (I’m using Express with dotenv for secrets).
• Craft a concise, reusable prompt so replies stay friendly and on-brand, and return them as structured JSON that the UI can parse.
• Add robust error handling for timeouts, rate limits, and empty inputs.
• Write a couple of Jest or Vitest cases to prove the integration works and provide instructions so I can extend the tests later.
• Deliver short setup notes (env variables, endpoint path, how to swap providers between OpenAI and Anthropic).

Acceptance criteria
1. A user enters text, clicks “Send,” and receives a conversational reply in under three seconds.
2. No API keys or sensitive headers appear anywhere in the browser network tab.
3. Test script passes locally with `npm test` and covers success + error paths.
4. Code is clean, commented, and dropped into a single pull request for review.

If you are comfortable with React hooks, Express middleware, and either the openai or anthropic NPM SDKs, you’ll fly through this. Feel free to suggest small UX tweaks, but the primary goal is a solid, secure chatbot integration.
node.js api development api integration api testing chatgpt ai chatbot development ai content creation ai development ai integration ai automation
Apply on Freelancer →

Project sourced from Freelancer.com. Applications happen directly on the original platform — we never collect your data.