Key Types
Endprompt has two types of API keys:| Key Type | Prefix | Purpose |
|---|---|---|
| Endpoint Key | ep_ | Execute endpoints only — for your application code |
| Admin Key | epa_ | Full management access — for Admin API and MCP |
Admin keys can also execute endpoints, so you only need one key for both management and execution during development.
Creating an Admin API Key
Set Permission Level
Choose a permission level:
- ReadWrite — Full access to all operations (create, update, delete, read)
- ReadOnly — Can only read resources (GET operations). Write attempts return 403.
Name Your Key
Give it a descriptive name:
MCP - VS CodeCI/CD Pipeline - AdminDevelopment - Local Admin
Using Your Admin Key
Admin keys work with both the REST API and MCP server. Include the key in your requests:REST API (x-api-key header)
REST API (Bearer token)
MCP Server
MCP connections use the Bearer token format in the transport configuration. See MCP Server for setup details.Permission Matrix
| Operation | ReadWrite | ReadOnly |
|---|---|---|
| List / Get resources | ✅ | ✅ |
| Create resources | ✅ | ❌ (403) |
| Update resources | ✅ | ❌ (403) |
| Delete resources | ✅ | ❌ (403) |
| Execute endpoints | ✅ | ✅ |
| View logs & stats | ✅ | ✅ |
Security Best Practices
Separate Keys by Environment
Use different admin keys for development, staging, and production.
Use ReadOnly Where Possible
If you only need to read data (monitoring, reporting), use a ReadOnly key.
Store Keys Securely
Use environment variables or secret managers. Never commit keys to git.
Rotate Periodically
Create new keys, update your integrations, then revoke old keys.

