A clear path forward
What is the purpose of API keys and secrets?
An application programming interface (API) key lets your app use a service. A secret keeps this private key out of your code.
Replit Secrets encrypts private keys and gives them to your app as environment variables. Environment variables are named values your app can read. This keeps keys out of project files.
Some supported Replit-managed artificial intelligence (AI) integrations provide the provider's keys, so you do not need your own. Replit bills managed use. The provider bills calls made with your own key. Check which integration Agent is setting up. Then add any needed private key through Secrets.
Read Managed AI integrations for more detail.
Was this page helpful?
Still stuck? Try troubleshooting with Agent.
Still stuck? Try troubleshooting with Agent.
Copy this prompt and paste it into Agent. For a project issue, open the project where it happens first. Add what happened and anything you've already tried. Don't include passwords, API keys, database connection strings or payment-card details.
Copying does not open Agent or send a support request. Agent availability and usage depend on your account.
Can't open your project, or need another kind of help? Get help.