superserve secrets commands manage encrypted environment variables for your agents.
Secrets are injected into the agent’s runtime environment and never appear in logs or LLM context.
Set Secrets
Set one or more secrets for an agent:Single Secret
Multiple Secrets
Example Output
List Secrets
List secret keys configured for an agent:Example Output
For security, the CLI only shows secret keys, never values. Values are encrypted and cannot be retrieved.
No Secrets
If no secrets are configured:Delete Secret
Delete a specific secret from an agent:y to confirm.
Skip Confirmation
Example Output
Command Reference
superserve secrets set
Set one or more secrets for an agent.
Agent name or ID (e.g.,
my-agent or agt_abc123def456)One or more
KEY=VALUE pairs separated by spacessuperserve secrets list
List secret keys for an agent.
Agent name or ID (e.g.,
my-agent or agt_abc123def456)superserve secrets delete
Delete a secret from an agent.
Agent name or ID (e.g.,
my-agent or agt_abc123def456)Secret key to delete (e.g.,
ANTHROPIC_API_KEY)Skip confirmation prompt
Required Secrets
You can specify required secrets insuperserve.yaml:
Secret Format
Secrets must follow theKEY=VALUE format:
✅ Valid:
Values with Spaces or Special Characters
Quote the entireKEY=VALUE pair:
How Secrets Work
Secrets are:- Encrypted at rest - Stored with AES-256 encryption
- Injected at runtime - Available as environment variables to your agent
- Never logged - Don’t appear in logs, traces, or LLM context
- Network proxied - Can be auto-injected into HTTP requests (with credential proxy)
Accessing Secrets in Code
Examples
Set Multiple Secrets from .env File
If you have a.env file:
Update a Secret
To change a secret value, set it again:Verify Secrets are Set
Delete All Secrets
Security Best Practices
- Never commit secrets - Don’t add API keys to version control
- Use different keys per environment - Separate keys for dev/staging/prod agents
- Rotate regularly - Update API keys every 90 days
- Use minimal permissions - Grant agents only the API access they need
- Monitor usage - Check API provider dashboards for unexpected activity
Credential Proxy
Superserve can automatically inject secrets into HTTP requests without exposing them to the agent:api.anthropic.com, the proxy injects the x-api-key header automatically.
The agent never sees the API key - it doesn’t appear in:
- LLM context
- Tool outputs
- Logs
- Network traces visible to the agent
Troubleshooting
”Invalid format ‘KEY’. Use KEY=VALUE”
Ensure you use the= separator:
“Agent not found”
Verify the agent exists:Values with = Characters
If your secret value contains = (e.g., Base64), quote it: