Preconditions
Related command
az postgres flexible-server connect
Resource Provider
Microsoft.DBforPostgreSQL/flexibleServers
Description of Feature or Work Requested
In the present version 2.86.0 az postgres flexible-server connect supports only username + password authentication. That works well for PostgreSQL internal / admin accounts and not that well for Entra ID accounts.
In the case of authenticating with Entra ID account the CLI expects not the user's password, but an authentication token which can be obtained by running:
az account get-access-token --resource https://ossrdbms-aad.database.windows.net
Feature request is to make az postgres flexible-server connect try using the already authenticated account first:
- if parameters
--admin-user and --admin-password do not specify any other credentials
- then check if authentication refresh token exists and is valid,
- if yes, then obtain the token for the target server scope,
- then use account name from the token cache and password from the access token.
Minimum API Version Required
N/A
Swagger PR link / SDK link
N/A
Request Example
No response
Target Date
2026-12-31
PM Contact
@pm
Engineer Contact
@engineer
Additional context
No response
Preconditions
Related command
az postgres flexible-server connect
Resource Provider
Microsoft.DBforPostgreSQL/flexibleServers
Description of Feature or Work Requested
In the present version 2.86.0
az postgres flexible-server connectsupports only username + password authentication. That works well for PostgreSQL internal / admin accounts and not that well for Entra ID accounts.In the case of authenticating with Entra ID account the CLI expects not the user's password, but an authentication token which can be obtained by running:
az account get-access-token --resource https://ossrdbms-aad.database.windows.netFeature request is to make
az postgres flexible-server connecttry using the already authenticated account first:--admin-userand--admin-passworddo not specify any other credentialsMinimum API Version Required
N/A
Swagger PR link / SDK link
N/A
Request Example
No response
Target Date
2026-12-31
PM Contact
@pm
Engineer Contact
@engineer
Additional context
No response