Environment Variables
This page lists the environment variables you use when integrating Custodian Labs into your application.
Do not commit secret values to version control.
Custodian Labs API Key
Your API key authenticates every request to the Custodian Labs Platform API.
| Variable | Required | Used by | Description |
|---|---|---|---|
CUSTODIAN_SDK_API_KEY | Yes | Python SDK | API key read by the Python SDK. |
CUSTODIAN_API_KEY | Yes | Platform API examples | Your API key, used in curl or backend examples in the Platform API docs. |
Platform API Base URL
The Platform API is served at https://platform.custodianlabs.io/v1.
| Variable | Required | Used by | Description |
|---|---|---|---|
CUSTODIAN_SDK_BASE_URL | No | Python SDK | Platform API base URL override. Defaults to https://platform.custodianlabs.io/v1. |
Legacy SDK variables may still work as fallbacks:
| Legacy variable | Prefer |
|---|---|
AI_SDK_API_KEY | CUSTODIAN_SDK_API_KEY |
AI_SDK_BASE_URL | CUSTODIAN_SDK_BASE_URL |
GUARDIAN_LAYER_BASE_URL | CUSTODIAN_MASKING_BASE_URL |
Security Notes
- Store API keys in backend environment variables or a secret manager.
- Restart your application after changing environment variables.
- Do not expose Custodian Labs keys in browser-side code.
- Use production values for production deployments and test values for local testing.