Networking
IP Addresses Assign
https://api.linode.com/v4/networking/ips/assign
Assign multiple IPv4 addresses and/or IPv6 ranges to multiple Linodes in one Region. This allows swapping, shuffling, or otherwise reorganizing IPs to your Linodes.
The following restrictions apply:
- All Linodes involved must have at least one public IPv4 address after assignment.
- Linodes may have no more than one assigned private IPv4 address.
- Linodes may have no more than one assigned IPv6 range.
- Shared IP addresses cannot be swapped between Linodes.
Open a Support Ticket to request additional IPv4 addresses or IPv6 ranges beyond standard account limits.
Note: Removing an IP address that has been set as a Managed Linode's ssh.ip
causes the Managed Linode's SSH access settings to reset to their default values. To view and configure Managed Linode SSH settings, use the following commands:
- Linode's Managed Settings View (GET /managed/linode-settings/{linodeId})
- Linode's Managed Settings Update (PUT /managed/linode-settings/{linodeId})
Request Body Schema
The list of assignments to make. You must have read_write access to all IPs being assigned and all Linodes being assigned to in order for the assignments to succeed.
The ID of the Region in which these assignments are to take place. All IPs and Linodes must exist in this Region.
Request Samples
- Shell
- CLI
curl -H "Content-Type: application/json" \
-H "Authorization: Bearer $TOKEN" \
-X POST -d '{
"region": "us-east",
"assignments": [
{
"address": "192.0.2.1",
"linode_id": 123
},
{
"address": "2001:db8:3c4d:15::/64",
"linode_id": 234
}
]
}' \
https://api.linode.com/v4/networking/ips/assign
Response Samples
- 200
- default
{}
Responses
200: All assignments completed successfully.
default: Error
What happened to cause this error. In most cases, this can be fixed immediately by changing the data you sent in the request, but in some cases you will be instructed to open a Support Ticket or perform some other action before you can complete the request successfully.
The field in the request that caused this error. This may be a path, separated by periods in the case of nested fields. In some cases this may come back as "null" if the error is not specific to any single element of the request.