IP pools
Named sets of dedicated IPs that mail picks with X-Capsule-Pool.
An IP pool is a named set of your dedicated IPs that mail opts into with the X-Capsule-Pool header. Every cluster keeps its default pool: the sending IPs on the cluster. Mail with no header sends from the default pool. A pool has a classification, transactional or bulk, that can't change later. It can hold any dedicated IP your team owns, of either class, each with a weight from 1 to 100 (default 100). Weights are relative and don't need to add up to 100. Attach a pool to any of your live shared clusters of the same class, then send with X-Capsule-Pool: . An IP sends from a cluster's default pool or from IP pools, never both, so unpinned mail never uses a pool IP. An IP can sit in several of your pools. Adding a reserved dedicated IP to a pool starts its 14-day warm-up. While every IP in a pool is still warming, a pool with warmup_overflow on (the default) sends the mail its IPs can't take yet from the cluster's default pool. With warmup_overflow off, that mail waits for the warming IPs. Pool mail counts toward the cluster's hourly and daily caps. Writes return 403 {error: team_suspended} while the account is suspended, except delete and detach.
GET /api/v1/teams/:obfuscated_team_id/ip_pools
List the team's IP pools by name, with their IPs, weights, and attached clusters.
classification: Optional. transactional or bulk.
POST /api/v1/teams/:obfuscated_team_id/ip_pools
Create an empty pool. name is lowercased and trimmed. It must be 1 to 63 characters of a-z, 0-9, _ and -, start with a letter or digit, and be unique in the team. default is reserved. Returns 422 {error: name_taken, errors} when the team already has a pool with that name, and 422 {error: invalid, errors} for any other invalid field.
name: Pool name. The value you send in X-Capsule-Pool.classification: transactional or bulk. Can't change later.warmup_overflow: Optional, default true. While every IP in the pool is warming, send what they can't take yet from the cluster's default pool.
PATCH /api/v1/ip_pools/:id
Rename a pool or change warmup_overflow. classification is ignored. Mail already queued under the old name keeps its pool. Returns 422 name_taken or invalid like create.
id: Public IP pool id
DELETE /api/v1/ip_pools/:id
Delete a pool. Its IPs stay with your team. Returns 422 pool_attached while it is attached to a live cluster. Detach it first.
id: Public IP pool id
POST /api/v1/ip_pools/:id/add_ip
Add a dedicated IP your team owns, or change its weight if it is already in the pool. A reserved IP starts its 14-day warm-up. Returns 404 when the IP isn't a dedicated IP your team owns, and 422 in_default_pool when the IP sends from a cluster's default pool (unassign it first), weight when weight isn't a whole number from 1 to 100, or ip_unusable when the IP is released or quarantined.
id: Public IP pool idip_address_id: Public id of a dedicated IP your team ownsweight: Optional. 1 to 100. Defaults to 100 for a new IP and keeps the current weight when re-adding.
POST /api/v1/ip_pools/:id/remove_ip
Remove an IP from the pool. The IP stays with your team. Queued mail pinned to it goes out on the rest of the pool. Returns 404 when the IP isn't in the pool, and 422 last_ip when the pool is attached to a live cluster and this is its last live IP.
id: Public IP pool idip_address_id: Public IP id
POST /api/v1/ip_pools/:id/attach
Attach the pool to one of your live clusters so its mail can use X-Capsule-Pool. Attaching again is a no-op. Returns 404 for another team's cluster or a deprovisioned one, and 422 class_mismatch when the classes differ, dedicated_cluster for a dedicated-node cluster, or empty_pool when the pool has no live IPs.
id: Public IP pool idcluster_id: Public cluster id
POST /api/v1/ip_pools/:id/detach
Detach the pool from a cluster. New mail with this X-Capsule-Pool on that cluster is rejected with 550. Mail already queued for the pool stays queued and is retried. It never goes out on the default pool. Returns 404 for another team's cluster.
id: Public IP pool idcluster_id: Public cluster id