Skip to content

Support creating user subscription as a Reseller administrator #50

@bganapa

Description

@bganapa

we need a parameter set in New-AzsSubscription or a new cmdlet for the following REST call

$g = [guid]::NewGuid()
$n = "BalaSubcription3"
$b=@"
{
"id":"",
"subscriptionId":"$g",
"displayName":"$n",
"offerId":"/subscriptions/-5318---/resourceGroups/testRP/providers/Microsoft.Subscriptions/offers/offerd",
"state":"Enabled",
"owner":"delegateduser@masselfhost.onmicrosoft.com"
}
"@
$u = "${armendpoint}subscriptions/---903c-8f4c301ee1d0/providers/Microsoft.Subscriptions/subscriptions/${g}?api-version=2018-04-01"
Invoke-RestMethod -Method PUT -Uri $u -Headers @{ Authorization = $C.GetAuthorizationHeader() } -ContentType "application/json" -Body $b

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions