Create an IP pool
Create an IP pool owned by your account.
Creates a pool owned by your account. The pool is immediately visible in GET /v3/pools and its IPs join the GET /v3/ips inventory.
POST /v3/pools
Body parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
name | string | Required | Display name (max 255 chars). |
provider | string | Required | Delivery backend the pool's IPs belong to: cloud-relay or apifon-postal. Immutable after creation. |
region | string | Optional | Sending region label (max 50 chars), e.g. europe-west. |
type | string | Optional | dedicated, shared or warming. Default shared. |
ips | array of strings | Optional | IPs assigned to the pool — each must be a valid IPv4 or IPv6 literal, up to 256 per pool. Default empty. |
Responses
| Status | Description |
|---|---|
201 | Created. The full pool object, including its generated id. |
400 | Validation error — missing name, provider isn't one of the supported backends, or ips contains a value that isn't a valid IP literal / exceeds 256 entries. |
401 | Missing or invalid API key. |
403 | Plan limit. Dedicated IP pools aren't available on your plan — upgrade to a plan that includes dedicated IPs to create pools. |
Code examples
cURL
curl -X POST https://api.wemail.io/v3/pools \
-H "Authorization: Bearer afn_live_…" \
-H "Content-Type: application/json" \
-d '{
"name": "transactional-eu",
"provider": "apifon-postal",
"region": "europe-west",
"type": "dedicated",
"ips": ["203.0.113.10"]
}'
# List pools visible to your account (own + platform-shared)
curl https://api.wemail.io/v3/pools -H "Authorization: Bearer afn_live_…"
# Flattened IP inventory, optionally filtered by pool
curl "https://api.wemail.io/v3/ips?pool_id=<uuid>" -H "Authorization: Bearer afn_live_…"Node.js
const pool = await wemail.pools.create({
name: "transactional-eu",
provider: "apifon-postal",
region: "europe-west",
type: "dedicated",
ips: ["203.0.113.10"],
});
const { items } = await wemail.ips.list({ pool_id: pool.id });Python
pool = wemail.pools.create(
name="transactional-eu",
provider="apifon-postal",
region="europe-west",
type="dedicated",
ips=["203.0.113.10"],
)
ips = wemail.ips.list(pool_id=pool.id)PHP
$pool = $wemail->pools->create([
'name' => 'transactional-eu',
'provider' => 'apifon-postal',
'region' => 'europe-west',
'type' => 'dedicated',
'ips' => ['203.0.113.10'],
]);
$ips = $wemail->ips->list(['pool_id' => $pool->id]);Ruby
pool = wemail.pools.create(
name: "transactional-eu",
provider: "apifon-postal",
region: "europe-west",
type: "dedicated",
ips: ["203.0.113.10"]
)
ips = wemail.ips.list(pool_id: pool.id)Go
pool, err := client.Pools.Create(ctx, &wemail.PoolParams{
Name: "transactional-eu",
Provider: "apifon-postal",
Region: "europe-west",
Type: "dedicated",
IPs: []string{"203.0.113.10"},
})
ips, _ := client.IPs.List(ctx, &wemail.IPListParams{PoolID: pool.ID})Java
Pool pool = wemail.pools().create(
PoolParams.builder()
.name("transactional-eu")
.provider("apifon-postal")
.region("europe-west")
.type("dedicated")
.ip("203.0.113.10")
.build());
IpPage ips = wemail.ips().list(IpListParams.builder().poolId(pool.getId()).build());.NET
var pool = await wemail.Pools.CreateAsync(new PoolParams {
Name = "transactional-eu",
Provider = "apifon-postal",
Region = "europe-west",
Type = "dedicated",
Ips = new[] { "203.0.113.10" },
});
var ips = await wemail.Ips.ListAsync(new IpListParams { PoolId = pool.Id });ResponseExample response
{
"items": [
{
"id": "5f2d8a1e-3b7c-4c1d-9e2f-8a1b2c3d4e5f",
"name": "transactional-eu",
"provider": "apifon-postal",
"region": "europe-west",
"type": "dedicated",
"ips": ["203.0.113.10"],
"reputation": 98,
"created_at": "2026-05-10T09:42:18Z"
}
],
"pagination": { "page": 1, "per_page": 25, "total_count": 1, "total_pages": 1 }
}