Create an IP pool
Create an account-scoped pool of dedicated IPs. Set is_default or domain_id for the pool to carry mail; a pool with neither carries none.
POST
/
email
/
ip_pools
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const IpPoolShow = await client.email.ipPools.create({
name: 'name',
});
console.log(IpPoolShow.data);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
ip_pool_show = client.email.ip_pools.create(
name="name",
)
print(ip_pool_show.data)
package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
iPPool, err := client.Email.IPPools.New(
context.TODO(),
telnyx.EmailIPPoolNewParams{
Name: "name",
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", iPPool.Data)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.email.ipPools.IpPoolCreateParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
IpPoolCreateParams params = IpPoolCreateParams.builder()
.name("name")
.build();
var response = client.email().ipPools().create(params);
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
ip_pool_show = telnyx.email.ip_pools.create(name: "name")
puts(ip_pool_show)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$ip_pool_show = $client->email->ipPools->create(
name: 'name',
);
var_dump($ip_pool_show);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx email:ip-pools create \
--api-key 'My API Key' \
--name namecurl --request POST \
--url https://api.telnyx.com/v2/email/ip_pools \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "primary-pool",
"is_default": true
}
'{
"data": {
"id": "9b1c4d70-abcd-4e5f-8a9b-0c1d2e3f4a5b",
"record_type": "ip_pool",
"name": "primary-pool",
"is_default": true,
"domain_id": null,
"ips": [],
"created_at": "2026-09-30T02:03:09.474123Z",
"updated_at": "2026-09-30T02:03:09.474123Z"
}
}{
"errors": [
{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
}
}
]
}{
"errors": [
{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
}
}
]
}{
"errors": [
{
"code": "10001",
"title": "Not Found",
"detail": "The requested email domain was not found"
}
]
}{
"errors": [
{
"code": "10015",
"title": "Validation Failed",
"detail": "already has a default pool",
"source": {
"pointer": "/data/attributes/account_id"
}
}
]
}Authorizations
Body
application/json
Was this page helpful?
JavaScript
import Telnyx from 'telnyx';
const client = new Telnyx({
apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});
const IpPoolShow = await client.email.ipPools.create({
name: 'name',
});
console.log(IpPoolShow.data);import os
from telnyx import Telnyx
client = Telnyx(
api_key=os.environ.get("TELNYX_API_KEY"), # This is the default and can be omitted
)
ip_pool_show = client.email.ip_pools.create(
name="name",
)
print(ip_pool_show.data)
package main
import (
"context"
"fmt"
"github.com/team-telnyx/telnyx-go"
"github.com/team-telnyx/telnyx-go/option"
)
func main() {
client := telnyx.NewClient(
option.WithAPIKey("My API Key"),
)
iPPool, err := client.Email.IPPools.New(
context.TODO(),
telnyx.EmailIPPoolNewParams{
Name: "name",
},
)
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", iPPool.Data)
}
package com.telnyx.sdk.example;
import com.telnyx.sdk.client.TelnyxClient;
import com.telnyx.sdk.client.okhttp.TelnyxOkHttpClient;
import com.telnyx.sdk.models.email.ipPools.IpPoolCreateParams;
public final class Main {
private Main() {}
public static void main(String[] args) {
TelnyxClient client = TelnyxOkHttpClient.fromEnv();
IpPoolCreateParams params = IpPoolCreateParams.builder()
.name("name")
.build();
var response = client.email().ipPools().create(params);
}
}require "telnyx"
telnyx = Telnyx::Client.new(api_key: "My API Key")
ip_pool_show = telnyx.email.ip_pools.create(name: "name")
puts(ip_pool_show)<?php
require_once dirname(__DIR__) . '/vendor/autoload.php';
use Telnyx\Client;
use Telnyx\Core\Exceptions\APIException;
$client = new Client(apiKey: getenv('TELNYX_API_KEY') ?: 'My API Key');
try {
$ip_pool_show = $client->email->ipPools->create(
name: 'name',
);
var_dump($ip_pool_show);
} catch (APIException $e) {
echo $e->getMessage();
}telnyx email:ip-pools create \
--api-key 'My API Key' \
--name namecurl --request POST \
--url https://api.telnyx.com/v2/email/ip_pools \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "primary-pool",
"is_default": true
}
'{
"data": {
"id": "9b1c4d70-abcd-4e5f-8a9b-0c1d2e3f4a5b",
"record_type": "ip_pool",
"name": "primary-pool",
"is_default": true,
"domain_id": null,
"ips": [],
"created_at": "2026-09-30T02:03:09.474123Z",
"updated_at": "2026-09-30T02:03:09.474123Z"
}
}{
"errors": [
{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
}
}
]
}{
"errors": [
{
"code": "<string>",
"title": "<string>",
"detail": "<string>",
"source": {
"pointer": "<string>",
"parameter": "<string>"
}
}
]
}{
"errors": [
{
"code": "10001",
"title": "Not Found",
"detail": "The requested email domain was not found"
}
]
}{
"errors": [
{
"code": "10015",
"title": "Validation Failed",
"detail": "already has a default pool",
"source": {
"pointer": "/data/attributes/account_id"
}
}
]
}