| external help file | utils-help.xml |
|---|---|
| Module Name | utils |
| online version | |
| schema | 2.0.0 |
Retrieves the path of the Azure REST API URI.
Get-AzureRestMethodUriPath -SubscriptionId <String> -ResourceProviderName <String> -ResourceType <String>
-ApiVersion <String> [-QueryString <String>] [-ProgressAction <ActionPreference>] [<CommonParameters>]Get-AzureRestMethodUriPath -SubscriptionId <String> -ResourceGroupName <String> -ResourceProviderName <String>
-ResourceType <String> -Name <String> -ApiVersion <String> [-QueryString <String>]
[-ProgressAction <ActionPreference>] [<CommonParameters>]The Get-AzureRestMethodUriPath function retrieves the formatted path of the Azure REST API URI based on the specified URI parts as parameters. The path represents the Azure REST API URI without the protocol (e.g. https), host (e.g. management.azure.com).
For example, /subscriptions/11111111-1111-1111-1111-111111111111/resourceGroups/rg1/providers/Microsoft.Storage/storageAccounts/stsample1234?api-version=2024-01-01
$path = Get-AzureRestMethodUriPath -SubscriptionId '11111111-1111-1111-1111-111111111111' -ResourceGroupName 'rg1' -ResourceProviderName 'Microsoft.Storage' -ResourceType 'storageAccounts' -Name 'stsample1234' -ApiVersion '2024-01-01' -QueryString 'param1=value1'The subscription ID that constitutes the path of Azure REST API URI.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe resource group name that constitutes the path of Azure REST API URI.
Type: String
Parameter Sets: WithResourceGroup
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe resource provider name that constitutes the path of Azure REST API URI. It's usually as the XXXX.XXXX format.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe resource type that constitutes the path of Azure REST API URI.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe resource name that constitutes the path of Azure REST API URI.
Type: String
Parameter Sets: WithResourceGroup
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe Azure REST API version that constitutes the path of Azure REST API URI. It's usually as the yyyy-mm-dd format.
Type: String
Parameter Sets: (All)
Aliases:
Required: True
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThe query string that constitutes the path of Azure REST API URI.
Type: String
Parameter Sets: (All)
Aliases:
Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: FalseThis cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.
Returns a URI path to call Azure REST API.
Author: Takeshi Katano Date: 2024-10-23