az account alias
Note
This reference is part of the account extension for the Azure CLI (version 2.38.0 or higher). The extension will automatically install the first time you run an az account alias command. Learn more about extensions.
Manage subscription alias.
Commands
Name | Description | Type | Status |
---|---|---|---|
az account alias create |
Create Alias Subscription. |
Extension | GA |
az account alias delete |
Delete Alias. |
Extension | GA |
az account alias list |
List Alias Subscriptions. |
Extension | GA |
az account alias show |
Get Alias Subscription. |
Extension | GA |
az account alias wait |
Place the CLI in a waiting state until a condition of the account alias is met. |
Extension | GA |
az account alias create
Create Alias Subscription.
az account alias create --name
[--billing-scope]
[--display-name]
[--no-wait]
[--reseller-id]
[--subscription-id]
[--workload {DevTest, Production}]
Examples
CreateAlias
az account alias create --name "aliasForNewSub" --billing-scope "/providers/Microsoft.Billing/billingAccounts/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx:024cabf4-7321-4cf9-be59-df0c77ca51de_2019-05-31/billingProfiles/PE2Q-NOIT-BG7-TGB/invoiceSections/MTT4-OBS7-PJA-TGB" --display-name "Contoso MCA subscription" --workload "Production"
Required Parameters
Alias Name.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Billing scope. It determines whether the subscription is Field-Led, Partner-Led or LegacyEA.
The friendly name of the subscription.
Do not wait for the long-running operation to finish.
Property | Value |
---|---|
Default value: | False |
Reseller ID, basically MPN Id.
This parameter can be used to create alias for existing subscription ID.
The workload type of the subscription. It can be either Production or DevTest.
Property | Value |
---|---|
Accepted values: | DevTest, Production |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az account alias delete
Delete Alias.
az account alias delete --name
Examples
DeleteAlias
az account alias delete --name "aliasForNewSub"
Required Parameters
Alias Name.
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az account alias list
List Alias Subscriptions.
az account alias list
Examples
List Alias Subscriptions
az account alias list
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az account alias show
Get Alias Subscription.
az account alias show --name
Examples
GetAlias
az account alias show --name "aliasForNewSub"
Required Parameters
Alias Name.
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az account alias wait
Place the CLI in a waiting state until a condition of the account alias is met.
az account alias wait --name
[--created]
[--custom]
[--deleted]
[--exists]
[--interval]
[--timeout]
[--updated]
Examples
Pause executing next line of CLI script until the account alias is successfully created.
az account alias wait --name "aliasForNewSub" --created
Required Parameters
Alias Name.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Wait until created with 'provisioningState' at 'Succeeded'.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | False |
Wait until the condition satisfies a custom JMESPath query. E.g. provisioningState!='InProgress', instanceView.statuses[?code=='PowerState/running'].
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Wait until deleted.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | False |
Wait until the resource exists.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | False |
Polling interval in seconds.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | 30 |
Maximum wait in seconds.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | 3600 |
Wait until updated with provisioningState at 'Succeeded'.
Property | Value |
---|---|
Parameter group: | Wait Condition Arguments |
Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |