swagger: "2.0"
schemes:
  - https
host: management.azure.com
info:
  description: The Microsoft Azure Network management API provides a RESTful set of web services that interact with Microsoft Azure Networks service to manage your network resources. The API has entities that capture the relationship between an end user and the Microsoft Azure Networks service.
  title: NetworkManagementClient
  version: 2017-11-01
  x-apisguru-categories:
    - cloud
  x-logo:
    url: https://api.apis.guru/v2/cache/logo/https_assets.onestore.ms_cdnfiles_onestorerolling-1606-01000_shell_v3_images_logo_microsoft.png
  x-origin:
    - format: swagger
      url: https://raw.githubusercontent.com/Azure/azure-rest-api-specs/master/specification/network/resource-manager/Microsoft.Network/stable/2017-11-01/publicIpAddress.json
      version: "2.0"
  x-preferred: false
  x-providerName: azure.com
  x-serviceName: network-publicIpAddress
  x-tags:
    - Azure
    - Microsoft
consumes:
  - application/json
  - text/json
produces:
  - application/json
  - text/json
securityDefinitions:
  azure_auth:
    authorizationUrl: https://login.microsoftonline.com/common/oauth2/authorize
    description: Azure Active Directory OAuth2 Flow
    flow: implicit
    scopes:
      user_impersonation: impersonate your user account
    type: oauth2
security:
  - azure_auth:
      - user_impersonation
parameters:
  ApiVersionParameter:
    description: Client API version.
    in: query
    name: api-version
    required: true
    type: string
  SubscriptionIdParameter:
    description: The subscription credentials which uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call.
    in: path
    name: subscriptionId
    required: true
    type: string
paths:
  "/subscriptions/{subscriptionId}/providers/Microsoft.Network/publicIPAddresses":
    get:
      description: Gets all the public IP addresses in a subscription.
      operationId: PublicIPAddresses_ListAll
      parameters:
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
      responses:
        "200":
          description: Request successful. The operation returns a list of PublicIPAddress resources.
          schema:
            $ref: "#/definitions/PublicIPAddressListResult"
      tags:
        - PublicIPAddresses
      x-ms-examples:
        List all public IP addresses:
          parameters:
            api-version: 2017-11-01
            subscriptionId: subid
          responses:
            "200":
              body:
                value:
                  - id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/testDNS-ip
                    location: westus
                    name: testDNS-ip
                    properties:
                      idleTimeoutInMinutes: 4
                      ipConfiguration:
                        id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                      provisioningState: Succeeded
                      publicIPAddressVersion: IPv4
                      publicIPAllocationMethod: Dynamic
                    type: Microsoft.Network/publicIPAddresses
                  - id: /subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/publicIPAddresses/ip01
                    location: westus
                    name: ip01
                    properties:
                      dnsSettings:
                        domainNameLabel: testlbl
                        fqdn: testlbl.westus.cloudapp.azure.com
                      idleTimeoutInMinutes: 4
                      ipAddress: 40.85.154.247
                      ipConfiguration:
                        id: /subscriptions/subid/resourceGroups/rg2/providers/Microsoft.Network/loadBalancers/testLb/frontendIPConfigurations/LoadBalancerFrontEnd
                      provisioningState: Succeeded
                      publicIPAddressVersion: IPv4
                      publicIPAllocationMethod: Dynamic
                    type: Microsoft.Network/publicIPAddresses
      x-ms-pageable:
        nextLinkName: nextLink
  "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/publicIPAddresses":
    get:
      description: Gets all public IP addresses in a resource group.
      operationId: PublicIPAddresses_List
      parameters:
        - description: The name of the resource group.
          in: path
          name: resourceGroupName
          required: true
          type: string
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
      responses:
        "200":
          description: Request successful. The operation returns a list of PublicIPAddress resources.
          schema:
            $ref: "#/definitions/PublicIPAddressListResult"
      tags:
        - PublicIPAddresses
      x-ms-examples:
        List resource group public IP addresses:
          parameters:
            api-version: 2017-11-01
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200":
              body:
                value:
                  - id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/testDNS-ip
                    location: westus
                    name: testDNS-ip
                    properties:
                      idleTimeoutInMinutes: 4
                      ipConfiguration:
                        id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                      ipTags:
                        - ipTagType: FirstPartyUsage
                          tag: SQL
                        - ipTagType: FirstPartyUsage
                          tag: Storage
                      provisioningState: Succeeded
                      publicIPAddressVersion: IPv4
                      publicIPAllocationMethod: Dynamic
                    type: Microsoft.Network/publicIPAddresses
                  - id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/ip03
                    location: westus
                    name: ip03
                    properties:
                      dnsSettings:
                        domainNameLabel: testlbl
                        fqdn: testlbl.westus.cloudapp.azure.com
                      idleTimeoutInMinutes: 4
                      ipAddress: 40.85.154.247
                      ipConfiguration:
                        id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/loadBalancers/testLb/frontendIPConfigurations/LoadBalancerFrontEnd
                      provisioningState: Succeeded
                      publicIPAddressVersion: IPv4
                      publicIPAllocationMethod: Dynamic
                    type: Microsoft.Network/publicIPAddresses
      x-ms-pageable:
        nextLinkName: nextLink
  "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/publicIPAddresses/{publicIpAddressName}":
    delete:
      description: Deletes the specified public IP address.
      operationId: PublicIPAddresses_Delete
      parameters:
        - description: The name of the resource group.
          in: path
          name: resourceGroupName
          required: true
          type: string
        - description: The name of the subnet.
          in: path
          name: publicIpAddressName
          required: true
          type: string
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
      responses:
        "200":
          description: Delete successful.
        "202":
          description: Accepted and the operation will complete asynchronously.
        "204":
          description: Request successful. Resource does not exist.
      tags:
        - PublicIPAddresses
      x-ms-examples:
        Delete public IP address:
          parameters:
            api-version: 2017-11-01
            publicIpAddressName: test-ip
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200": {}
            "202": {}
            "204": {}
      x-ms-long-running-operation: true
    get:
      description: Gets the specified public IP address in a specified resource group.
      operationId: PublicIPAddresses_Get
      parameters:
        - description: The name of the resource group.
          in: path
          name: resourceGroupName
          required: true
          type: string
        - description: The name of the subnet.
          in: path
          name: publicIpAddressName
          required: true
          type: string
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
        - description: Expands referenced resources.
          in: query
          name: $expand
          required: false
          type: string
      responses:
        "200":
          description: Request successful. The operation returns the resulting PublicIPAddress resource.
          schema:
            $ref: "#/definitions/PublicIPAddress"
      tags:
        - PublicIPAddresses
      x-ms-examples:
        Get public IP address:
          parameters:
            api-version: 2017-11-01
            publicIpAddressName: testDNS-ip
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/testDNS-ip
                location: westus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 4
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  ipTags:
                    - ipTagType: FirstPartyUsage
                      tag: SQL
                    - ipTagType: FirstPartyUsage
                      tag: Storage
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Dynamic
                type: Microsoft.Network/publicIPAddresses
    patch:
      description: Updates public IP address tags.
      operationId: PublicIPAddresses_UpdateTags
      parameters:
        - description: The name of the resource group.
          in: path
          name: resourceGroupName
          required: true
          type: string
        - description: The name of the public IP address.
          in: path
          name: publicIpAddressName
          required: true
          type: string
        - description: Parameters supplied to update public IP address tags.
          in: body
          name: parameters
          required: true
          schema:
            description: Tags object for patch operations.
            properties:
              tags:
                additionalProperties:
                  type: string
                description: Resource tags.
                type: object
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
      responses:
        "200":
          description: Update successful. The operation returns the resulting PublicIPAddress resource.
          schema:
            $ref: "#/definitions/PublicIPAddress"
      tags:
        - PublicIPAddresses
      x-ms-examples:
        Update public IP address tags:
          parameters:
            api-version: 2017-11-01
            parameters:
              tags:
                tag1: value1
                tag2: value2
            publicIpAddressName: test-ip
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: westus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 10
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Static
                tags:
                  tag1: value1
                  tag2: value2
                type: Microsoft.Network/publicIPAddresses
      x-ms-long-running-operation: true
    put:
      description: Creates or updates a static or dynamic public IP address.
      operationId: PublicIPAddresses_CreateOrUpdate
      parameters:
        - description: The name of the resource group.
          in: path
          name: resourceGroupName
          required: true
          type: string
        - description: The name of the public IP address.
          in: path
          name: publicIpAddressName
          required: true
          type: string
        - description: Parameters supplied to the create or update public IP address operation.
          in: body
          name: parameters
          required: true
          schema:
            $ref: "#/definitions/PublicIPAddress"
        - $ref: "#/parameters/ApiVersionParameter"
        - $ref: "#/parameters/SubscriptionIdParameter"
      responses:
        "200":
          description: Update successful. The operation returns the resulting PublicIPAddress resource.
          schema:
            $ref: "#/definitions/PublicIPAddress"
        "201":
          description: Create successful. The operation returns the resulting PublicIPAddress resource.
          schema:
            $ref: "#/definitions/PublicIPAddress"
      tags:
        - PublicIPAddresses
      x-ms-examples:
        Create public IP address DNS:
          parameters:
            api-version: 2017-11-01
            parameters:
              location: eastus
              properties:
                dnsSettings:
                  domainNameLabel: dnslbl
            publicIpAddressName: test-ip
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  dnsSettings:
                    domainNameLabel: dnslbl
                    fqdn: dnslbl.westus.cloudapp.azure.com
                  idleTimeoutInMinutes: 4
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Dynamic
                type: Microsoft.Network/publicIPAddresses
            "201":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  dnsSettings:
                    domainNameLabel: dnslbl
                    fqdn: dnslbl.westus.cloudapp.azure.com
                  idleTimeoutInMinutes: 4
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Dynamic
                type: Microsoft.Network/publicIPAddresses
        Create public IP address allocation method:
          parameters:
            api-version: 2017-11-01
            parameters:
              location: eastus
              properties:
                idleTimeoutInMinutes: 10
                publicIPAddressVersion: IPv4
                publicIPAllocationMethod: Static
              sku:
                name: Standard
            publicIpAddressName: test-ip
            resourceGroupName: rg1
            subscriptionId: subid
            zones:
              - "1"
          responses:
            "200":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 10
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Static
                sku:
                  name: Standard
                type: Microsoft.Network/publicIPAddresses
                zones:
                  - "1"
            "201":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 10
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Static
                sku:
                  name: Standard
                type: Microsoft.Network/publicIPAddresses
                zones:
                  - "1"
        Create public IP address defaults:
          parameters:
            api-version: 2017-11-01
            parameters:
              location: eastus
            publicIpAddressName: test-ip
            resourceGroupName: rg1
            subscriptionId: subid
          responses:
            "200":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 4
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Dynamic
                sku:
                  name: Basic
                type: Microsoft.Network/publicIPAddresses
            "201":
              body:
                id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/publicIPAddresses/test-ip
                location: eastus
                name: testDNS-ip
                properties:
                  idleTimeoutInMinutes: 4
                  ipConfiguration:
                    id: /subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/networkInterfaces/testDNS649/ipConfigurations/ipconfig1
                  provisioningState: Succeeded
                  publicIPAddressVersion: IPv4
                  publicIPAllocationMethod: Dynamic
                sku:
                  name: Basic
                type: Microsoft.Network/publicIPAddresses
      x-ms-long-running-operation: true
definitions:
  IpTag:
    description: Contains the IpTag associated with the public IP address
    properties:
      ipTagType:
        description: "Gets or sets the ipTag type: Example FirstPartyUsage."
        type: string
      tag:
        description: Gets or sets value of the IpTag associated with the public IP. Example SQL, Storage etc
        type: string
  PublicIPAddress:
    allOf:
      - description: Common resource representation.
        properties:
          id:
            description: Resource ID.
            type: string
          location:
            description: Resource location.
            type: string
          name:
            description: Resource name.
            readOnly: true
            type: string
          tags:
            additionalProperties:
              type: string
            description: Resource tags.
            type: object
          type:
            description: Resource type.
            readOnly: true
            type: string
        x-ms-azure-resource: true
    description: Public IP address resource.
    properties:
      etag:
        description: A unique read-only string that changes whenever the resource is updated.
        type: string
      properties:
        $ref: "#/definitions/PublicIPAddressPropertiesFormat"
        description: Public IP address properties.
        x-ms-client-flatten: true
      sku:
        description: SKU of a public IP address
        properties:
          name:
            description: Name of a public IP address SKU.
            enum:
              - Basic
              - Standard
            type: string
            x-ms-enum:
              modelAsString: true
              name: PublicIPAddressSkuName
      zones:
        description: A list of availability zones denoting the IP allocated for the resource needs to come from.
        items:
          type: string
        type: array
  PublicIPAddressDnsSettings:
    description: Contains FQDN of the DNS record associated with the public IP address
    properties:
      domainNameLabel:
        description: Gets or sets the Domain name label.The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system.
        type: string
      fqdn:
        description: Gets the FQDN, Fully qualified domain name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone.
        type: string
      reverseFqdn:
        description: "Gets or Sets the Reverse FQDN. A user-visible, fully qualified domain name that resolves to this public IP address. If the reverseFqdn is specified, then a PTR DNS record is created pointing from the IP address in the in-addr.arpa domain to the reverse FQDN. "
        type: string
  PublicIPAddressListResult:
    description: Response for ListPublicIpAddresses API service call.
    properties:
      nextLink:
        description: The URL to get the next set of results.
        type: string
      value:
        description: A list of public IP addresses that exists in a resource group.
        items:
          $ref: "#/definitions/PublicIPAddress"
        type: array
  PublicIPAddressPropertiesFormat:
    description: Public IP address properties.
    properties:
      dnsSettings:
        description: Contains FQDN of the DNS record associated with the public IP address
        properties:
          domainNameLabel:
            description: Gets or sets the Domain name label.The concatenation of the domain name label and the regionalized DNS zone make up the fully qualified domain name associated with the public IP address. If a domain name label is specified, an A DNS record is created for the public IP in the Microsoft Azure DNS system.
            type: string
          fqdn:
            description: Gets the FQDN, Fully qualified domain name of the A DNS record associated with the public IP. This is the concatenation of the domainNameLabel and the regionalized DNS zone.
            type: string
          reverseFqdn:
            description: "Gets or Sets the Reverse FQDN. A user-visible, fully qualified domain name that resolves to this public IP address. If the reverseFqdn is specified, then a PTR DNS record is created pointing from the IP address in the in-addr.arpa domain to the reverse FQDN. "
            type: string
      idleTimeoutInMinutes:
        description: The idle timeout of the public IP address.
        format: int32
        type: integer
      ipAddress:
        description: The IP address associated with the public IP address resource.
        type: string
      ipConfiguration:
        $ref: ./networkInterface.json#/definitions/IPConfiguration
        description: The IP configuration associated with the public IP address.
        readOnly: true
      ipTags:
        description: The list of tags associated with the public IP address.
        items:
          description: Contains the IpTag associated with the public IP address
          properties:
            ipTagType:
              description: "Gets or sets the ipTag type: Example FirstPartyUsage."
              type: string
            tag:
              description: Gets or sets value of the IpTag associated with the public IP. Example SQL, Storage etc
              type: string
        type: array
      provisioningState:
        description: "The provisioning state of the PublicIP resource. Possible values are: 'Updating', 'Deleting', and 'Failed'."
        type: string
      publicIPAddressVersion:
        description: "The public IP address version. Possible values are: 'IPv4' and 'IPv6'."
        enum:
          - IPv4
          - IPv6
        type: string
        x-ms-enum:
          modelAsString: true
          name: IPVersion
      publicIPAllocationMethod:
        description: "The public IP allocation method. Possible values are: 'Static' and 'Dynamic'."
        enum:
          - Static
          - Dynamic
        type: string
        x-ms-enum:
          modelAsString: true
          name: IPAllocationMethod
      resourceGuid:
        description: The resource GUID property of the public IP resource.
        type: string
  PublicIPAddressSku:
    description: SKU of a public IP address
    properties:
      name:
        description: Name of a public IP address SKU.
        enum:
          - Basic
          - Standard
        type: string
        x-ms-enum:
          modelAsString: true
          name: PublicIPAddressSkuName
