An app that sends text prompts to the OpenAI API and displays the results in a list. The AI model generates a text completion that attempts to match whatever context or pattern you give it!
Click here to view the app.
Tech used: HTML, CSS, JavaScript, React
- Never expose API keys in client-side code! I set my API key in a .env file and added it to .gitignore to avoid pushing my API key to GitHub. If the key gets compromised, OpenAI triggers a key rotation and a new API key is assigned. To deploy my project with Heroku, I used config vars to set the API key as an environment variable.