Azure / Azure/azure-powershell
Can Get-AzSubscription provide an -Expand parameter to list its management group ancestors?
- Dominant language
- C#
- Stars
- 4.8k
- Forks
- 4.3k
- Avg merge
- 3d 14h
- Merged PRs (30d)
- 54
Description
## Description of the new feature
Can Get-AzSubscription provide an -Expand parameter to list its management group ancestors?
I know that GET https://management.azure.com/subscriptions/{subID}?api-version=2018-11-01&$expand=ancestors provide the ancestor details, could PowerShell provide the same functionality?
## Proposed implementation details (optional)
Contributor guide
Research direction
Start by locating the Get-AzSubscription cmdlet implementation and its tests, then compare its subscription request with GET https://management.azure.com/subscriptions/{subID}?api-version=2018-11-01&$expand=ancestors. Done means an -Expand option exposes the management group ancestor details and the behavior is covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, csharp, powershell
- Domain
- api, cli, cloud
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100