azure extra — Phoenix handles token acquisition and refresh automatically on every new database connection.
Setup
Install theazure extra to pull in azure-identity and aiohttp:
PHOENIX_POSTGRES_AZURE_SCOPE defaults to https://ossrdbms-aad.database.windows.net/.default. Override it only if you are running in a sovereign cloud such as Azure US Government:
Notes
- Mutual exclusion —
PHOENIX_POSTGRES_USE_AZURE_MANAGED_IDENTITYandPHOENIX_POSTGRES_USE_AWS_IAM_AUTHcannot both betrue; Phoenix raises aValueErrorat startup if both are set. PHOENIX_POSTGRES_AWS_IAM_TOKEN_LIFETIME_SECONDSis deprecated — the env var is now silently ignored with a startup warning. Connection pool hygiene is managed internally.
Using Azure Managed Identity
Full setup guide for Azure managed-identity PostgreSQL connections.
Amazon Aurora (AWS IAM)
Configure AWS RDS IAM authentication for PostgreSQL.

