Azure / azure-rest-api-specs

The source for REST API specifications for Microsoft Azure.
MIT License
2.67k stars 5.1k forks source link

[BUG] Microsoft.Network - privateEndpoint - GET Private Endpoint : etag, isIPv6EnabledPrivateEndpoint -- additional properties #31315

Open dj-r1 opened 1 week ago

dj-r1 commented 1 week ago

API Spec link

https://github.com/Azure/azure-rest-api-specs/blob/main/specification/network/resource-manager/Microsoft.Network/stable/2023-11-01/privateEndpoint.json

API Spec version

2023-11-01, 2024-03-01

Describe the bug

As example PrivateEndpointGet.json, response describing a resource, it should be without: etag properties.isIPv6EnabledPrivateEndpoint properties.privateLinkServiceConnections[0].etag

There are also examples in Azure REST API for Private Endpoints - Get. Found with Microsoft.Network/privateEndpoints ARM template/Bicep description.

Additional properties.isIPv6EnabledPrivateEndpoint has an impact on WhatIf Bicep operation, as showing as a Bicep difference/change.

Expected behavior

{
  "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe",
  "location": "europe",
  "name": "mystorageacc-blob-pe",
  "properties": {
    "customDnsConfigs": [],
    "customNetworkInterfaceName": "",
    "ipConfigurations": [],
    "manualPrivateLinkServiceConnections": [],
    "networkInterfaces": [
      {
        "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/networkInterfaces/mystorageacc-blob-pe.nic.2f1f0c13-1055-4a66-8bc0-0e4e603a4a63"
      }
    ],
    "privateLinkServiceConnections": [
      {
        "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe/privateLinkServiceConnections/mystorageacc-link",
        "name": "mystorageacc-link",
        "properties": {
          "groupIds": [
            "blob"
          ],
          "privateLinkServiceConnectionState": {
            "actionsRequired": "None",
            "description": "Auto-Approved",
            "status": "Approved"
          },
          "privateLinkServiceId": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-second-rg/providers/Microsoft.Storage/storageAccounts/mystorageacc",
          "provisioningState": "Succeeded"
        },
        "type": "Microsoft.Network/privateEndpoints/privateLinkServiceConnections"
      }
    ],
    "provisioningState": "Succeeded",
    "resourceGuid": "111aaa11-11a1-11a1-a1a1-a111e111a11a",
    "subnet": {
      "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-second-rg/providers/Microsoft.Network/virtualNetworks/my-vnet-hub/subnets/MyFirstSubnet"
    }
  },
  "type": "Microsoft.Network/privateEndpoints"
}

Actual behavior

{
  "etag": "W/\"111ttt11-11t1-11t1-t1t1-t111e111t11t\"",
  "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe",
  "location": "europe",
  "name": "mystorageacc-blob-pe",
  "properties": {
    "customDnsConfigs": [],
    "customNetworkInterfaceName": "",
    "ipConfigurations": [],
    "isIPv6EnabledPrivateEndpoint": false,
    "manualPrivateLinkServiceConnections": [],
    "networkInterfaces": [
      {
        "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/networkInterfaces/mystorageacc-blob-pe.nic.2f1f0c13-1055-4a66-8bc0-0e4e603a4a63"
      }
    ],
    "privateLinkServiceConnections": [
      {
        "etag": "W/\"111ttt11-11t1-11t1-t1t1-t111e111t11t\"",
        "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe/privateLinkServiceConnections/mystorageacc-link",
        "name": "mystorageacc-link",
        "properties": {
          "groupIds": [
            "blob"
          ],
          "privateLinkServiceConnectionState": {
            "actionsRequired": "None",
            "description": "Auto-Approved",
            "status": "Approved"
          },
          "privateLinkServiceId": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-second-rg/providers/Microsoft.Storage/storageAccounts/mystorageacc",
          "provisioningState": "Succeeded"
        },
        "type": "Microsoft.Network/privateEndpoints/privateLinkServiceConnections"
      }
    ],
    "provisioningState": "Succeeded",
    "resourceGuid": "111aaa11-11a1-11a1-a1a1-a111e111a11a",
    "subnet": {
      "id": "/subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-second-rg/providers/Microsoft.Network/virtualNetworks/my-vnet-hub/subnets/MyFirstSubnet"
    }
  },
  "type": "Microsoft.Network/privateEndpoints"
}

Reproduction Steps

az rest --method get --header "Accept=application/json" --url 'https://management.azure.com//subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe?api-version=2023-11-01' || GET https://management.azure.com//subscriptions/aaaaaaaa-0000-1111-2222-bbbbbbbbbbbb/resourceGroups/my-rg/providers/Microsoft.Network/privateEndpoints/mystorageacc-blob-pe?api-version=2023-11-01

also with api-version=2024-03-01

Environment

No response

v-jiaodi commented 1 week ago

@GuptaVertika please help take a look, thanks.