Using IP Pools with the SMTP API Header

IP pools can only be used with whitelabeled IP addresses.

IP Pools allow you to group your dedicated SendGrid IP addresses together. For example, you might have separate pools named transactional and marketing.

Then, when sending marketing emails, you may specify that the marketing pool be used, so that your transactional IPs maintain their own reputation.

1
{"to": ["destination.com"],"ip_pool": "pool_name"}

If an IP pool is NOT specified for an email, it will use any IP available, including ones in pools.


POST

Create an IP pool.

There is a limit of 100 IP pools per user.

URI Parameter Required Requirements Description
name Yes String. max of 64 characters Name of the new IPpool

Request

1
POST https://api.sendgrid.com/v3/ips/pools HTTP/1.1
Request Body
1
2
3
{
  "name": "marketing"
}

Response

1
{"name":"marketing"}

GET

List all IP pools.

Request

1
GET https://api.sendgrid.com/v3/ips/pools HTTP/1.1

Response

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
HTTP/1.1 200
[
  {
    "name": "test1"
  },
  {
    "name": "test2"
  },
  {
    "name": "test3"
  },
  {
    "name": "new_test3"
  }
]

GET

List the IPs in a specified pool.

Request

1
GET https://api.sendgrid.com/v3/ips/pools/:pool_name HTTP/1.1

Response

1
2
3
4
5
6
HTTP/1.1 200 OK 

{
  "ips":["167.89.21.3"],
  "pool_name":"new_test5"
}

PUT

Update an IP pool’s name.

URI Parameter Required Requirements Description
name Yes String. max 64 characters New name of the pool

Request

1
PUT https://api.sendgrid.com/v3/ips/pools/:pool_name HTTP/1.1
Request Body
1
2
3
{
  "name": "marketing"
}

Response

1
2
3
4
5
HTTP/1.1 200 OK 

{
  "name":"new_pool_name"
}

DELETE

Delete an IP pool.

Request

1
DELETE https://api.sendgrid.com/v3/ips/pools/:pool_name HTTP/1.1

Response

1
HTTP/1.1 204 NO CONTENT (OK)