Course AI Assistant
Online
Enter to send · Shift+Enter for a new line
Learn from it
How This Chatbot Works
This chatbot is not a mock-up — it is a live example of the architecture taught in Module 3 (AI APIs) and built in Module 6.
USERtypes a question
WEBSITEthis page, running in your browser
OUR BACKEND APIholds the secret API key — server-side only
OPENAI APIreceives the securely forwarded request
AI MODELgenerates the answer
RESPONSEtravels back the same path to your screen
The OpenAI API key stays on our server. The user's browser talks to our
backend, and our backend securely talks to OpenAI. If you open your browser's developer
tools on this page, you will see requests going only to
/api/chat
on this website — never to OpenAI, and never containing a key. That is the whole point:
an API key is like a password that lets a server spend money on an AI account, so it must
never be given to the browser.