Create a public IPv4 network for a dedicated server

POST/v1/hosts/dedicated_servers/{server_id}/networks/public_ipv4

A POST request sent to the /v1/hosts/dedicated_servers/{server_id}/networks/public_ipv4 endpoint will initiate creation of a public IPv4 network for the selected server. Specify a host ID in the path parameter. The subnet mask is a required parameter to be mentioned in the request body. To order an alias IP, use the route method with a /32 mask.

Authorization

bearerAuth
AuthorizationBearer <token>

In: header

Path Parameters

FieldDetails
server_id
string

A unique identifier of a server.

Request Body

FieldDetails
distribution_method?
string

Value in: "gateway", "route"

Default: "gateway"

A distribution method (see details in the response description). The route method is compatible only with a /32 mask for alias IP creation; use gateway to allocate networks with other masks.

mask
integer

A subnet mask. Available subnet sizes are /29 - /26 for gateway and /32 for the route method. If you need a /29 subnet, specify 29 in this parameter.

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/hosts/dedicated_servers/l9avZgaG/networks/public_ipv4" \  -H "Content-Type: application/json" \  -d '{    "distribution_method": "gateway",    "mask": 29  }'
{  "id": "WPe9OYbL",  "title": "Alias",  "status": "new",  "cidr": null,  "family": "ipv4",  "interface_type": "public",  "distribution_method": "route",  "additional": true,  "updated_at": "2026-05-28T06:57:50Z",  "created_at": "2026-05-28T06:57:50Z"}