Authorizations
API key for authentication. Make sure to include the word apikey
, followed by a single space and then your token.
Example: apikey 1234$abcdef
Path Parameters
Project ID
1
Region ID
1
Subnet ID
"b39792c3-3160-4356-912e-ba396c95cdcf"
Body
List IP addresses of DNS servers to advertise via DHCP.
["8.8.4.4", "1.1.1.1"]
True if DHCP should be enabled
true
Default GW IPv4 address to advertise in DHCP routes in this subnet. Omit this field to let the cloud backend allocate it automatically. Set to null if no gateway must be advertised by this subnet's DHCP (useful when attaching instances to multiple subnets in order to prevent default route conflicts).
"192.168.10.1"
List of custom static routes to advertise via DHCP.
[
{
"destination": "10.0.3.0/24",
"nexthop": "10.0.0.13"
}
]
Name
"some_name"
Update key-value tags using JSON Merge Patch semantics (RFC 7386). Provide key-value pairs to add or update tags. Set tag values to null
to remove tags. Unspecified tags remain unchanged. Read-only tags are always preserved and cannot be modified.
Examples:
* Add/update tags: {'tags': {'environment': 'production', 'team': 'backend'}}
adds new tags or updates existing ones.
* Delete tags: {'tags': {'
old_tag': null}}
removes specific tags.
* Remove all tags: {'tags': null}
removes all user-managed tags (read-only tags are preserved).
* Partial update: {'tags': {'environment': 'staging'}}
only updates specified tags.
* Mixed operations: {'tags': {'environment': 'production', '
cost_center': 'engineering', '
deprecated_tag': null}}
adds/updates 'environment' and 'cost_center
' while removing 'deprecated_tag
', preserving other existing tags.
* Replace all: first delete existing tags with null values, then add new ones in the same request.
{
"my-tag": "my-tag-value",
"my-tag-to-remove": null
}
Response
OK
CIDR
"192.168.13.0/24"
Datetime when the subnet was created
"2019-06-13T13:58:12+0000"
True if DHCP should be enabled
true
IP version
4
, 6
Subnet name
"subnet_3"
Network ID
"b30d0de7-bca2-4c83-9c57-9e645bd2cc92"
Project ID
1337
Region name
"Luxembourg 1"
Region ID
7
List of key-value tags associated with the resource. A tag is a key-value pair that can be associated with a resource, enabling efficient filtering and grouping for better organization and management. Some tags are read-only and cannot be modified by the user. Tags are also integrated with cost reports, allowing cost data to be filtered based on tag keys or values.
[
{
"key": "my-tag",
"read_only": false,
"value": "my-tag-value"
}
]
Datetime when the subnet was last updated
"2019-06-13T13:58:12+0000"
Number of available ips in subnet
250
Task that created this entity
"5cc890da-d031-4a23-ac31-625edfa22812"
List IP addresses of a DNS resolver reachable from the network
["8.8.8.8", "8.8.4.4"]
Default GW IPv4 address, advertised in DHCP routes of this subnet. If null, no gateway is advertised by this subnet.
"192.168.13.1"
Deprecated. Always returns false
.
false
List of custom static routes to advertise via DHCP.
[]
Subnet id.
"b39792c3-3160-4356-912e-ba396c95cdcf"
The UUID of the active task that currently holds a lock on the resource. This lock prevents concurrent modifications to ensure consistency. If null
, the resource is not locked.
null
Total number of ips in subnet
253