Menu

Settings - Inbound Parse

Twilio SendGrid’s Inbound Parse Webhook allows you to receive emails as multipart/form-data at a URL of your choosing. SendGrid will grab the content, attachments, and the headers from any email it receives for your specified hostname.

See "Setting up the Inbound Parse Webhook" for help configuring the Webhook. You can also manage the Inbound Parse Webhook in the Twilio SendGrid App.

To begin processing email using SendGrid's Inbound Parse Webhook, you will have to setup MX Records, choose the hostname (or receiving domain) that will be receiving the emails you want to parse, and define the URL where you want to POST your parsed emails. If you do not have access to your domain's DNS records, you must work with someone in your organization who does.

Retrieve a specific parse setting

Retrieve a specific parse setting

GET /user/webhooks/parse/settings/{hostname}

This endpoint allows you to retrieve a specific inbound parse setting by hostname.

You can retrieve all your Inbound Parse settings and their associated host names with the "Retrieve all parse settings" endpoint.

Authentication

  • API Key

Headers

Authorization
string
default: Bearer <<YOUR_API_KEY_HERE>>
required
on-behalf-of
string
default: The subuser's username. This header generates the API call as if the subuser account was making the call.

Path Parameters

hostname
string

The hostname associated with the inbound parse setting that you would like to retrieve.

required

Responses

object
url
string

The public URL where you would like SendGrid to POST the data parsed from your email. Any emails sent with the given hostname provided (whose MX records have been updated to point to SendGrid) will be parsed and POSTed to this URL.

hostname
string

A specific and unique domain or subdomain that you have created to use exclusively to parse your incoming email. For example, parse.yourdomain.com.

spam_check
boolean

Indicates if you would like SendGrid to check the content parsed from your emails for spam before POSTing them to your domain.

send_raw
boolean

Indicates if you would like SendGrid to post the original MIME-type content of your parsed email. When this parameter is set to true, SendGrid will send a JSON payload of the content of your email.

{
  "url": "http://email.myhostname.com",
  "hostname": "myhostname.com",
  "spam_check": false,
  "send_raw": true
}
object
errors
array[object]
message
string

the error message

field
string

the field that generated the error

help
object

helper text or docs for troubleshooting

id
string
{
  "errors": [
    {
      "field": "field_name",
      "message": "error message"
    }
  ]
}
object
errors
array[object]
message
string

the error message

field
string

the field that generated the error

help
object

helper text or docs for troubleshooting

id
string
{
  "errors": [
    {
      "field": "field_name",
      "message": "error message"
    }
  ]
}
object
errors
array[object]
message
string

the error message

field
string

the field that generated the error

help
object

helper text or docs for troubleshooting

id
string
{
  "errors": [
    {
      "field": "field_name",
      "message": "error message"
    }
  ]
}
object
errors
array[object]
message
string

Need some help?

We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the SendGrid tag on Stack Overflow.