Skip to main content

Manage Azure subscription information. Part of az, the command-line client for Microsoft Azure.

# To print a list of subscriptions for the logged in account:
az account list

# To set a 'subscription' to be the currently active subscription:
az account set --subscription <subscription_id>

# To list supported regions for the currently active subscription:
az account list-locations

# To print an access token to be used with 'MS Graph API':
az account get-access-token --resource-type <ms-graph>

# To print details of the currently active subscription in a specific format:
az account show --output <json|tsv|table|yaml>