Azure / Azure/azure-rest-api-specs

[APIM] cannot create an APIM with public network access disabled

Open
#23,683 9 comments 2 reactions 0 assignees View on GitHub
API Management customer-reported needs-team-attention question Service Attention
Dominant language
TypeSpec
Stars
3.1k
Forks
5.9k
Avg merge
2d 22h
Merged PRs (30d)
444

Description

Following the documentation, I am trying to issue the following command:

```
az apim create --name "my-private-apim" --publisher-email "" --publisher-name "" --resource-group some-rg-name --location eastus --sku-name Developer --public-network-access false --virtual-network None
```

When I look at the result in the Azure Portal, I can see that the APIM has been provided with a public IP address. When I export the template on azure portal, I can see that the field "publicNetworkAccess" is filled with value "Enabled".

I tried to do the same with option `--virtual-network` set to `Internal` and I also get that the public network access actually is enabled.

Am I doing something wrong? What is happening here?

Contributor guide

Open the contributing guide

Research direction

No source file or test is named. Start by tracing how the APIM create command maps --public-network-access and --virtual-network to the Azure API specification, then reproduce the reported command; done means the resulting setting matches the requested value or the behavior is clearly documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
api, cloud
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.