Skip to main content

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.

VariableRequiredUsed byDescription
CUSTODIAN_SDK_API_KEYYesPython SDKAPI key read by the Python SDK.
CUSTODIAN_API_KEYYesPlatform API examplesYour 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.

VariableRequiredUsed byDescription
CUSTODIAN_SDK_BASE_URLNoPython SDKPlatform API base URL override. Defaults to https://platform.custodianlabs.io/v1.

Legacy SDK variables may still work as fallbacks:

Legacy variablePrefer
AI_SDK_API_KEYCUSTODIAN_SDK_API_KEY
AI_SDK_BASE_URLCUSTODIAN_SDK_BASE_URL
GUARDIAN_LAYER_BASE_URLCUSTODIAN_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.