Azure / Azure/azure-powershell

[Doc]: New-AzStaticWebApp : -SkuName should be marked as required or have a default value

Open
#29,010 3 comments 0 reactions 0 assignees View on GitHub
act-observability-squad App Services customer-reported Service Attention
Dominant language
C#
Stars
4.8k
Forks
4.3k
Avg merge
2d 17h
Merged PRs (30d)
51

Description

### Type of issue

Other (describe below)

### Feedback

When `-SkuName` is not provided:

```
PS> New-AzStaticWebApp -Name $staticAppName -ResourceGroupName $ResourceGroupName -Location "West US 2" -SkipGithubActionWorkflowGeneration
Az.Websites.internal\New-AzStaticWebApp : The server responded with a Request Error, Status: BadRequest
At C:\Program Files\WindowsPowerShell\Modules\Az.Websites\3.4.2\Websites.Autorest\custom\New-AzStaticWebApp.ps1:299 char:13
+ Az.Websites.internal\New-AzStaticWebApp @PSBoundParameter ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: ({ ResourceGroup...": ""
}
} }:<>f__AnonymousType18`4) [New-AzStaticWebApp_CreateExpanded], RestException`1
+ FullyQualifiedErrorId : BadRequest,Microsoft.Azure.PowerShell.Cmdlets.Websites.Cmdlets.NewAzStaticWebApp_CreateExpanded
```

Adding `-SkuName Free` resolves the issue.

### Page URL

https://learn.microsoft.com/en-us/powershell/module/az.websites/new-azstaticwebapp?view=azps-15.1.0

### Content source URL

https://github.com/Azure/azure-powershell/blob/main/src/Websites/Websites/help/New-AzStaticWebApp.md

### Author

@mikefrobbins

### Document Id

d3234102-aeaf-d9e9-06ae-7bebcd20505d

### Platform Id

f345b8b6-217b-c36a-380f-f9f385ab60c0

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.