Ip Allocations - Create Or Update
Creates or updates an IpAllocation in the specified resource group.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Network/IpAllocations/{ipAllocationName}?api-version=2024-03-01
URI Parameters
Name | In | Required | Type | Description |
---|---|---|---|---|
ip
|
path | True |
string |
The name of the IpAllocation. |
resource
|
path | True |
string |
The name of the resource group. |
subscription
|
path | True |
string |
The subscription credentials which uniquely identify the Microsoft Azure subscription. The subscription ID forms part of the URI for every service call. |
api-version
|
query | True |
string |
Client API version. |
Request Body
Name | Type | Description |
---|---|---|
id |
string |
Resource ID. |
location |
string |
Resource location. |
properties.allocationTags |
object |
IpAllocation tags. |
properties.ipamAllocationId |
string |
The IPAM allocation ID. |
properties.prefix |
string |
The address prefix for the IpAllocation. |
properties.prefixLength |
integer |
The address prefix length for the IpAllocation. |
properties.prefixType |
The address prefix Type for the IpAllocation. |
|
properties.type |
The type for the IpAllocation. |
|
tags |
object |
Resource tags. |
Responses
Name | Type | Description |
---|---|---|
200 OK |
Update successful. The operation returns the resulting IpAllocation resource. |
|
201 Created |
Create successful. The operation returns the resulting IpAllocation resource. |
|
Other Status Codes |
Error response describing why the operation failed. |
Security
azure_auth
Azure Active Directory OAuth2 Flow.
Type:
oauth2
Flow:
implicit
Authorization URL:
https://login.microsoftonline.com/common/oauth2/authorize
Scopes
Name | Description |
---|---|
user_impersonation | impersonate your user account |
Examples
Create IpAllocation
Sample request
PUT https://management.azure.com/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/IpAllocations/test-ipallocation?api-version=2024-03-01
{
"properties": {
"type": "Hypernet",
"prefix": "3.2.5.0/24",
"allocationTags": {
"VNetID": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/HypernetVnet1"
}
},
"location": "centraluseuap"
}
Sample response
{
"name": "test-ipallocation",
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/IpAllocations/test-ipallocation",
"type": "Microsoft.Network/IpAllocations",
"location": "centraluseuap",
"properties": {
"type": "Hypernet",
"prefix": "3.2.5.0/24",
"ipamAllocationId": "916d3b28-663f-448b-9abc-1bea9d5fed8f",
"allocationTags": {
"VNetID": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/HypernetVnet1"
}
}
}
{
"name": "test-ipallocation",
"id": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/IpAllocations/test-ipallocation",
"type": "Microsoft.Network/IpAllocations",
"location": "centraluseuap",
"properties": {
"type": "Hypernet",
"prefix": "3.2.5.0/24",
"ipamAllocationId": "916d3b28-663f-448b-9abc-1bea9d5fed8f",
"allocationTags": {
"VNetID": "/subscriptions/subid/resourceGroups/rg1/providers/Microsoft.Network/virtualNetworks/HypernetVnet1"
}
}
}
Definitions
Name | Description |
---|---|
Cloud |
An error response from the service. |
Cloud |
An error response from the service. |
Ip |
IpAllocation resource. |
Ip |
IpAllocation type. |
IPVersion |
IP address version. |
Sub |
Reference to another subresource. |
CloudError
An error response from the service.
Name | Type | Description |
---|---|---|
error |
Cloud error body. |
CloudErrorBody
An error response from the service.
Name | Type | Description |
---|---|---|
code |
string |
An identifier for the error. Codes are invariant and are intended to be consumed programmatically. |
details |
A list of additional details about the error. |
|
message |
string |
A message describing the error, intended to be suitable for display in a user interface. |
target |
string |
The target of the particular error. For example, the name of the property in error. |
IpAllocation
IpAllocation resource.
Name | Type | Default value | Description |
---|---|---|---|
etag |
string |
A unique read-only string that changes whenever the resource is updated. |
|
id |
string |
Resource ID. |
|
location |
string |
Resource location. |
|
name |
string |
Resource name. |
|
properties.allocationTags |
object |
IpAllocation tags. |
|
properties.ipamAllocationId |
string |
The IPAM allocation ID. |
|
properties.prefix |
string |
The address prefix for the IpAllocation. |
|
properties.prefixLength |
integer |
0 |
The address prefix length for the IpAllocation. |
properties.prefixType |
The address prefix Type for the IpAllocation. |
||
properties.subnet |
The Subnet that using the prefix of this IpAllocation resource. |
||
properties.type |
The type for the IpAllocation. |
||
properties.virtualNetwork |
The VirtualNetwork that using the prefix of this IpAllocation resource. |
||
tags |
object |
Resource tags. |
|
type |
string |
Resource type. |
IpAllocationType
IpAllocation type.
Name | Type | Description |
---|---|---|
Hypernet |
string |
|
Undefined |
string |
IPVersion
IP address version.
Name | Type | Description |
---|---|---|
IPv4 |
string |
|
IPv6 |
string |
SubResource
Reference to another subresource.
Name | Type | Description |
---|---|---|
id |
string |
Resource ID. |