There are several causes for blocked emails: for example, your mail server IP address is on an ISP blacklist, or blocked by an ISP, or if the receiving server flags the message content.

List all blocks [GET]

URI Parameter Required Requirements Description
start_time No timestamp Refers start of the time range in unix timestamp when a blocked email was created (inclusive).
Example: 1443651141
end_time No timestamp Refers end of the time range in unix timestamp when a blocked email was created (inclusive).
Example: 1443651154
limit No integer Limit the number of results to be displayed per page.
Example: 10
offset No integer Paging offset. The point in the list to begin displaying results.
Example: 0

Request

1
GET https://api.sendgrid.com/v3/suppression/blocks?start_time={start_time}&end_time={end_time}&limit=10&offset=0 HTTP/1.1

Response

1
HTTP/1.1 200
There are two options for deleting blocked emails:

1. You can delete all blocked emails by setting "delete_all" to true in the request body.
2. You can delete some blocked emails by specifying the email addresses in an array in the request body.

Delete blocks [DELETE]

Request

1
DELETE https://api.sendgrid.com/v3/suppression/blocks HTTP/1.1
Request Body
1
2
3
{
  "delete_all": true
}

Response

1
HTTP/1.1 204

Request

1
DELETE https://api.sendgrid.com/v3/suppression/blocks HTTP/1.1
Request Body
1
2
3
4
5
6
{
  "emails": [
    "email1@test.com",
    "email2@test.com"
  ]
}

Response

1
HTTP/1.1 204

Get a specific block [GET]

URI Parameter Required Requirements Description
email Yes string Email address of blocked email entry.
Example: spam1@test.com

Request

1
GET https://api.sendgrid.com/v3/suppression/blocks/{email} HTTP/1.1

Response

1
2
3
4
5
6
7
8
9
HTTP/1.1 200
[
  {
    "created": 1443651154,
    "email": "user1@example.com",
    "reason": "error dialing remote address: dial tcp 10.57.152.165:25: no route to host",
    "status": "4.0.0"
  }
]

Delete a specific block [DELETE]

URI Parameter Required Requirements Description
email Yes string Email address of blocked email entry.
Example: spam1@test.com

Request

1
DELETE https://api.sendgrid.com/v3/suppression/blocks/{email} HTTP/1.1

Response

1
HTTP/1.1 204