Authentication
To use the Fonema.ai API, you need an API key to authenticate your requests. Follow these steps to generate and manage your keys.
Generate a new API key
-
Access the Dashboard
-
Create a new key
- Click "Add API Key"
-
Configure the key
- Descriptive name: Use a name that helps identify the key purpose (e.g. "Production App", "Internal Testing")
- Scope: Choose the access level for this key (see Key scopes below)
- Click "Create API Key" to finish
Key scopes
When you create an API key you choose its scope, which determines how many of your agents the key can access:
| Scope | Dashboard label | Access |
|---|---|---|
| All agents | All agents | Company-wide access. The key can read, create, and edit every agent in your company, including agents created later. Use this for admin or backend integrations. |
| Specific agents | Specific agents | Restricted access. The key can only access the agents you explicitly select. Agents created through the API with this key are automatically added to the key's allowed list. |
tip
Use an All agents key when you need a single key to manage your whole account programmatically. Use a Specific agents key to limit a key to a subset of agents (recommended for keys shared with third parties).
Using the API key
Once you have your API key, include it in all API requests using the authorization header:
Authentication header
Authorization: Bearer YOUR_API_KEY_HERE