< Back
Get-ProvAzureSubscription
Post
NAME Get-ProvAzureSubscription
SYNOPSIS
Read details of an Azure Subscription.
SYNTAX
Get-ProvAzureSubscription -AuthContext <object> [-ApiVersion <string>] [-Name <string>] [-SubscriptionId <Guid>]
[<CommonParameters>]
DESCRIPTION
This cmdlet connects to the Azure REST API and reads subscription details.
PARAMETERS
-AuthContext <object>
A valid authentication token, as provided by "Get-ProvAzureAuthContext"
Required? true
Position? named
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? false
-ApiVersion <string>
The REST API Version used to read the data from Azure. Default is "2016-01-01", but may be changed due to
updates in the REST API
See https://docs.microsoft.com/en-us/rest/a ... scriptions for updates.
Required? false
Position? named
Default value 2016-01-01
Accept pipeline input? false
Accept wildcard characters? false
-Name <string>
The name of the subscription to look for.
If this parameter is not specified, all subscriptions will be returned.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-SubscriptionId <Guid>
The GUID of the subscription to look for.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
System.Object
A valid authentication token, as provided by "Get-ProvAzureAuthContext"
OUTPUTS
Provance.Azure.Common.Model.Subscription
---------- EXAMPLE 1 ----------
Retrieve all Azure Subscriptions of a tenant
$mysubscription = Get-ProvAzureSubscription -AuthContext $token
The $token object shall be generated with Get-ProvAzureAuthContext first
---------- EXAMPLE 2 ----------
Retrieve Azure Subscription(s) by Subscription Name
$mysubscription = Get-ProvAzureSubscription -AuthContext $token -SubscriptionName 'Microsoft Partner*'
The $token object shall be generated with Get-ProvAzureAuthContext first
---------- EXAMPLE 3 ----------
Retrieve one Azure Subscription by Subscription ID
$mysubscription = Get-ProvAzureSubscription -AuthContext $token -SubscriptionID
'90419738-1ef5-4c31-a142-0dc9603958e2'
The $token object shall be generated with Get-ProvAzureAuthContext first
RELATED LINKS
Provance Technologies Inc. (http://provance.com)
Help (http://help.provance.com)
SYNOPSIS
Read details of an Azure Subscription.
SYNTAX
Get-ProvAzureSubscription -AuthContext <object> [-ApiVersion <string>] [-Name <string>] [-SubscriptionId <Guid>]
[<CommonParameters>]
DESCRIPTION
This cmdlet connects to the Azure REST API and reads subscription details.
PARAMETERS
-AuthContext <object>
A valid authentication token, as provided by "Get-ProvAzureAuthContext"
Required? true
Position? named
Default value
Accept pipeline input? true (ByValue)
Accept wildcard characters? false
-ApiVersion <string>
The REST API Version used to read the data from Azure. Default is "2016-01-01", but may be changed due to
updates in the REST API
See https://docs.microsoft.com/en-us/rest/a ... scriptions for updates.
Required? false
Position? named
Default value 2016-01-01
Accept pipeline input? false
Accept wildcard characters? false
-Name <string>
The name of the subscription to look for.
If this parameter is not specified, all subscriptions will be returned.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
-SubscriptionId <Guid>
The GUID of the subscription to look for.
Required? false
Position? named
Default value
Accept pipeline input? false
Accept wildcard characters? false
<CommonParameters>
This cmdlet supports the common parameters: Verbose, Debug,
ErrorAction, ErrorVariable, WarningAction, WarningVariable,
OutBuffer, PipelineVariable, and OutVariable. For more information, see
about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).
INPUTS
System.Object
A valid authentication token, as provided by "Get-ProvAzureAuthContext"
OUTPUTS
Provance.Azure.Common.Model.Subscription
---------- EXAMPLE 1 ----------
Retrieve all Azure Subscriptions of a tenant
$mysubscription = Get-ProvAzureSubscription -AuthContext $token
The $token object shall be generated with Get-ProvAzureAuthContext first
---------- EXAMPLE 2 ----------
Retrieve Azure Subscription(s) by Subscription Name
$mysubscription = Get-ProvAzureSubscription -AuthContext $token -SubscriptionName 'Microsoft Partner*'
The $token object shall be generated with Get-ProvAzureAuthContext first
---------- EXAMPLE 3 ----------
Retrieve one Azure Subscription by Subscription ID
$mysubscription = Get-ProvAzureSubscription -AuthContext $token -SubscriptionID
'90419738-1ef5-4c31-a142-0dc9603958e2'
The $token object shall be generated with Get-ProvAzureAuthContext first
RELATED LINKS
Provance Technologies Inc. (http://provance.com)
Help (http://help.provance.com)