Manage API Keys
API keys are required to authenticate your requests to Wren AI's API. This guide will help you create and manage your API keys.
Creating an API Key
- Navigate to the main dashboard
- Select "API" from the main navigation menu
- Click on the "API Keys" tab
- Click the "Create API Key" button
- Enter a name for your API key (e.g., "Production", "Development")
- Click "Create"
caution
Make sure to copy your API key immediately after creation. For security reasons, you won't be able to view it again.
Using Your API Key
Include your API key in the Authorization
header of your requests:
Authorization: Bearer YOUR_API_KEY
Revoking API Keys
To revoke an API key:
- Find the key in the API Keys list
- Click the more icon (⋮)
- Select "Delete"
warning
Revoking an API key is permanent and cannot be undone. Any applications using the revoked key will stop working.
Best Practices
- Create separate API keys for different environments (development, staging, production)
- Regularly rotate your API keys
- Never share your API keys in public repositories or client-side code
- Monitor your API usage in the API History