Lease an IPv4 Subnet
This guide walks through the complete process of leasing an IPv4 subnet using the IPXO API — from discovering available subnets to successfully placing an order. By the end of this flow, you will have:- Selected an available IPv4 subnet
- Added it to a cart
- Completed checkout
- Created an active order (and subscription)
Prerequisites
Before starting this flow, make sure you have:- A valid access token (
{access_token}) - Your tenant UUID (
{tenant_uuid}) - At least one:
- billing address
- payment method (card or credits)
Flow overview
At a high level, leasing a subnet consists of these steps:- Search for available subnets
- Add a subnet to cart
- Review cart and cart items
- Attach billing address
- Attach payment method (and optionally credits)
- Checkout cart
- Verify created order
1) Search for available subnets
Try itStart by searching the IP market for IPv4 subnets that match your requirements.
What this does
- Queries the IPXO marketplace
- Returns available subnets filtered by:
- prefix length (
/24) - country (
US) - sorted by lowest price first
- prefix length (
What to save from the response
From the selected subnet, store:address→{address}prefix_length→{cidr}
2) Add the selected subnet to cart
Try itOnce you choose a subnet, add it to the tenant’s cart.
What this does
- Creates (or reuses) an active cart
- Adds the IPv4 subnet as a recurring monthly product
Response
- No response body
HTTP 204 No Content
3) View cart summary
Try itRetrieve the current cart to get totals and the cart identifier.
What to save from the response
uuid→{cart_uuid}
4) List cart items
Try itInspect what exactly has been added to the cart.
Why this is useful
- Verify the correct subnet is in the cart
- Confirm pricing and billing period
- Retrieve cart line identifiers if needed later
5) List company billing addresses
Try itA billing address is required before checkout.
What to save from the response
uuid→{address_uuid}
6) Attach billing address to cart
Try itAssign the selected billing address to the cart.
What this does
- Associates the cart with a billing address
- Enables checkout and invoice generation
7) List available payment methods
Try itRetrieve saved payment methods for the tenant.
What to save from the response
uuid→{payment_method_uuid}
8) Attach payment method to cart
Try itAssign the selected payment method to the cart.
What this does
- Sets the payment method used during checkout
- Required even if credits cover part of the total
⚠️ Important: Currently, it is not possible to complete checkout (pay by card) due to 3DS card security. Please use Credit balance to pay for the cart.
9) (Optional) Check available credit balance
Try itBefore checkout, you can check if credits are available.
10) (Optional) Apply credits to cart
Try itIf credits are available, apply them to reduce the payable amount.
11) Checkout cart and create order
Try itFinalize the cart and create an order.
What happens here
- An order is created
- Payment is initiated
- A subscription for the subnet is created in the background
What to save from the response
order.uuid→{order_uuid}
12) Retrieve order details
Try itVerify the order status and totals.
Successful outcome
- Order status moves to
completed - Subnet becomes active
- Recurring billing starts based on the billing cycle
ℹ️ If order status is processing, it’s most likely due to the attached payment method (as mentioned above, card payments via API will not be completed).