Attach Dedicated IP to Endpoint

POST /v1/endpoints/{uuid}/dedicated-ip

Attach a dedicated IP (previously provisioned via /dedicated-ips/requests and fulfilled by the operator) to an endpoint. Once attached, the platform updates DNS so the endpoint's hostname resolves to the dedicated IP instead of the shared anycast pool.

Use cases:

  • Allow-listing: customer firewalls that only let traffic in from a specific IP.
  • SLA / reputation: avoid getting "noisy neighbor" rate-limits or blocklist entries from shared anycast IPs.
  • Compliance: regulators that demand dedicated infrastructure.

Each dedicated IP can be attached to one endpoint at a time. Re-attaching to a different endpoint requires detaching first. DNS propagation typically takes 1-2 minutes after attach.

A single-IP binding is mutually exclusive with a per-region group: attaching a single IP here clears any group binding on the endpoint, and vice-versa.

The IP's region binding lives on the dedicated-IP assignment (region_slug), not on the endpoint — endpoints are region-less. The IP is validated against the allowed CIDR ranges for its own region before the binding is persisted.

Path parameters

uuid string (uuid) Req
Endpoint UUID. The endpoint must be eligible for dedicated IPs (use /dedicated-ips/attachable-endpoints to filter).

Request body

assignment_id int64 Req
Numeric ID of an active dedicated-IP assignment allocated to your account. Get from /dedicated-ips. The assignment must be in active status and belong to your account.

Response (200 OK)

endpoint_id int64
Numeric endpoint ID (echo).
assignment_id int64
The dedicated-IP assignment ID now bound to this endpoint (echo).
ip_address string
The IP address now associated with this endpoint.
region_slug string
Region the dedicated IP belongs to (from the assignment).

Errors

400 Bad Request
Missing assignment_id (must be > 0) or invalid JSON.
401 Unauthorized
Missing auth.
403 Forbidden
Plan doesn't include the dedicated_ips entitlement, or the endpoint/assignment belongs to another tenant.
404 Not Found
Endpoint or assignment doesn't exist.
409 Conflict
Assignment is not active, or the IP fails CIDR validation for its region.
502 Bad Gateway
DNS repoint failed after the binding was written — the change is automatically reverted; safe to retry.
Request
curl -X POST "https://api.ngris.com/v1/endpoints/<uuid>/dedicated-ip" \ -H "X-API-KEY: <your_api_key>" \ -H "Content-Type: application/json" \ -d '{"assignment_id": 7}'
Python
from ngris import Ngris client = Ngris(api_key="<your_api_key>") result = client._post_raw("/endpoints/<endpoint_uuid>/dedicated-ip", {"assignment_id": 7}) print(f"Now serving from {result['ip_address']}")
Response — 200 OK
{ "endpoint_id": 184, "assignment_id": 7, "ip_address": "203.0.113.5", "region_slug": "eu-central" }
Iris