Azure / Azure/azure-cli-extensions
az account reference content is stating that --display-name is optional; also needs clarification of an enrollment account
- Dominant language
- Python
- Stars
- 454
- Forks
- 1.7k
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 64
Description
# Primary feedback
Link to reference --> https://docs.microsoft.com/en-us/cli/azure/ext/subscription/account?view=azure-cli-latest
### description of command
Create a subscription.
### now create a subscription
az account create --enrollment-account-name mySub --offer-type MS-AZR-0148P
#### see error
MissingParameter - Required parameter DisplayName not provided.
### check reference content
https://docs.microsoft.com/en-us/cli/azure/ext/subscription/account?view=azure-cli-latest#ext-subscription-az-account-create-optional-parameters
**_Optional Parameters_**
**--display-name
The display name of the subscription.**
### create subscription with what is really a non-optional display-name
az account create --enrollment-account-name subLearnLocalContext --offer-type MS-AZR-0148P --display-name subLearn1
#### see permissions error
UserNotAuthorized - User is not authorized to create subscriptions on this enrollment account
# Secondary feedback
The command description says "create a subscription" so this should align to creating a subscription [in the portal](https://docs.microsoft.com/en-us/azure/cost-management-billing/manage/create-subscription). There is no explanation of a relationship with `az billing enrollment-account` or even the concept of an enrollment account. It might be helpful to provide a link to this article --> https://docs.microsoft.com/en-us/azure/azure-resource-manager/management/grant-access-to-create-subscription?tabs=azure-cli%2Crest-2
Contributor guide
Assessment
This issue has not been assessed yet.