CI Workflows
Generate API key
Your API key authenticates you with Replay App and allows you to record test runs and automatically upload replays to the Replay App.
Creating a new API key
- To generate a new API key, go to Replay app and API Keys section in the team settings section.
- Add permissions and name to your API key and click "Add"
- Copy your API key
Keeping your API key safe
Make sure to copy and save your key immediately as you will not be able to see it again after you close the settings. Keep your API key safe and avoid committing it to your repo.
Delete API key
Your API keys are accessible in your team settings. You can delete any API key if necessary. A list of all active API keys is also available in the team settings.
Using your API key
Saving Key to Local Environment
Save Locally: Store the API key in a secure location on your local machine, such as an environment variable.
Terminal
export REPLAY_APP_API_KEY=<Your-API-Key>
Using .env
file
For local development and easier environment secrets management, you can use dotenv package and save your API key to a .env
file. Make sure this file is listed in your .gitignore
file so that you accidentally don’t expose it.
.env
REPLAY_API_KEY=<your_api_key>
Saving API key to remote environment
Most CI/CD providers (e.g. GitHub, CircleCI) offer an interface where you can securely add repository secrets or store your environment variables.