Get-AzureWebHostingPlan

Gets Azure web hosting plans in the current subscription.

Note

The cmdlets referenced in this documentation are for managing legacy Azure resources that use Azure Service Manager (ASM) APIs. This legacy PowerShell module isn't recommended when creating new resources since ASM is scheduled for retirement. For more information, see Azure Service Manager retirement.

The Az PowerShell module is the recommended PowerShell module for managing Azure Resource Manager (ARM) resources with PowerShell.

Syntax

Get-AzureWebHostingPlan
   [-WebSpaceName <String>]
   [-Name <String>]
   [-Profile <AzureSMProfile>]
   [<CommonParameters>]

Description

This topic describes the cmdlet in the 0.8.10 version of the Microsoft Azure PowerShell module. To get the version of the module you're using, in the Azure PowerShell console, type (Get-Module -Name Azure).Version.

The Get-AzureWebHostingPlan cmdlet gets the Azure web hosting plans in the current subscription.

By default, Get-AzureWebHostingPlan gets all Azure hosting plans in the current subscription and returns an object that provides basic information about the plans. When you use the WebSpace and Name parameters, Get-AzureWebHostingPlan returns a specific hosting plan object.

To find the current subscription, use the Current parameter of the Get-AzureSubscription cmdlet. To change the current subscription, use the Select-AzureSubscription cmdlet.

Examples

Example 1: Get all web hosting plans in a subscription

PS C:\> Get-AzureWebHostingPlan 

Name : Default1 
SKU : Basic 
WorkerSize : Small 
NumberOfWorkers : 1 
CurrentWorkerSize : Small 
CurrentNumberOfWorkers : 1 
Status : Ready 
WebSpace : eastuswebspace 
Name : Default0 
SKU : Free 
WorkerSize : Small 
NumberOfWorkers : 0 
CurrentWorkerSize : Small 
CurrentNumberOfWorkers : 0 
Status : Ready

This command gets all Azure web hosting plans in the current subscription.

Example 2: Get a specific web hosting plan in a subscription

PS C:\> Get-AzureWebHostingPlan -WebSpaceName "westeuropewebspace" -Name "Default0" 

Name : Default0 
SKU : Free 
WorkerSize : Small 
NumberOfWorkers : 0 
CurrentWorkerSize : Small 
CurrentNumberOfWorkers : 0 
Status : Ready 
WebSpace : westeuropewebspace

This command gets the web hosting plan named Default0 in the webspace named westeuropewebspace in the current subscription.

Parameters

-Name

Specifies the name of a plan in the subscription. By default, this cmdlet gets all plans in the current subscription. This parameter does not support wildcard characters.

Type:String
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

-Profile

Specifies the Azure profile from which this cmdlet reads. If you do not specify a profile, this cmdlet reads from the local default profile.

Type:AzureSMProfile
Position:Named
Default value:None
Required:False
Accept pipeline input:False
Accept wildcard characters:False

-WebSpaceName

Specifies the name of a webspace in the subscription. By default, this cmdlet gets all websites in the specified webspace. This parameter does not support wildcard characters.

Type:String
Aliases:WebSpace
Position:Named
Default value:None
Required:False
Accept pipeline input:True
Accept wildcard characters:False

Inputs

You can pass input to this cmdlet by property name, but not by value.

Outputs

Microsoft.WindowsAzure.Commands.Utilities.Websites.Services.WebEntities.WebHostingPlan

By default, Get-AzureWebHostingPlan returns an array of WebHostingPlan objects.