---
title: "Allocate an IP address"
method: POST
path: "/ipam"
tags: ["ipam"]
---

# Allocate an IP address

`POST /ipam`

## Query parameters

- `family` 'ipv4' | 'ipv6'
- `owner` string
- `pool` string

## Headers

- `expiration` boolean

## Response `201`

Success

- IPAMResponse — IPAM configuration of an endpoint
  - `address` AddressPair, required — Addressing information of an endpoint
    - `ipv4` string — IPv4 address
    - `ipv4-expiration-uuid` string — UUID of IPv4 expiration timer
    - `ipv4-pool-name` string — IPAM pool from which this IPv4 address was allocated
    - `ipv6` string — IPv6 address
    - `ipv6-expiration-uuid` string — UUID of IPv6 expiration timer
    - `ipv6-pool-name` string — IPAM pool from which this IPv6 address was allocated
  - `ipv4` IPAMAddressResponse — IPAM configuration of an individual address family
    - `ip` string — IP address
    - `gateway` string — IP address
    - `cidrs` CIDR[] — List of CIDRs out of which IPs are allocated
    - `master-mac` string — MAC of master interface if address is a slave/secondary of a master interface
    - `expiration-uuid` string — The UUID for the expiration timer. Set when expiration has been enabled while allocating.
    - `interface-number` string — InterfaceNumber is a field for generically identifying an interface. This is only useful in ENI mode.
    - `skip-masquerade` boolean — SkipMasquerade indicates whether the datapath should avoid masquerading connections from this IP.
  - `ipv6` IPAMAddressResponse — IPAM configuration of an individual address family
    - `ip` string — IP address
    - `gateway` string — IP address
    - `cidrs` CIDR[] — List of CIDRs out of which IPs are allocated
    - `master-mac` string — MAC of master interface if address is a slave/secondary of a master interface
    - `expiration-uuid` string — The UUID for the expiration timer. Set when expiration has been enabled while allocating.
    - `interface-number` string — InterfaceNumber is a field for generically identifying an interface. This is only useful in ENI mode.
    - `skip-masquerade` boolean — SkipMasquerade indicates whether the datapath should avoid masquerading connections from this IP.
  - `host-addressing` NodeAddressing, required — Addressing information of a node for all address families +k8s:deepcopy-gen=true
    - `ipv6` NodeAddressingElement — Addressing information
      - `enabled` boolean — True if address family is enabled
      - `ip` string — IP address of node
      - `alloc-range` string — Address pool to be used for local endpoints
      - `address-type` string — Node address type, one of HostName, ExternalIP or InternalIP
    - `ipv4` NodeAddressingElement — Addressing information
      - `enabled` boolean — True if address family is enabled
      - `ip` string — IP address of node
      - `alloc-range` string — Address pool to be used for local endpoints
      - `address-type` string — Node address type, one of HostName, ExternalIP or InternalIP

## Other responses

- `403` — Forbidden
- `502` — Allocation failure

---

[API](https://skmtc.net/cilium/apis/cilium-api.md) · [All operations](https://skmtc.net/cilium/apis/cilium-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cilium/cilium-api/revisions/351336b27221/schema)
