Early access: these pages are being written and reviewed. Facts in the header boxes come straight from the product.
Receive an inbound email (provider webhook)
POST
/api/v1/email/inbound
const url = 'https://api.pitch2sale.com/api/v1/email/inbound';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"From":"hello@example.com","To":"example","Subject":"","HtmlBody":"","TextBody":"","Headers":[],"MessageID":"example","Attachments":[]}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://api.pitch2sale.com/api/v1/email/inbound \ --header 'Content-Type: application/json' \ --data '{ "From": "hello@example.com", "To": "example", "Subject": "", "HtmlBody": "", "TextBody": "", "Headers": [], "MessageID": "example", "Attachments": [] }'Public, HMAC-signed by the inbound email provider (Postmark format). The organization is resolved from the recipient address.
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
From
required
string format: email
To
required
string
Subject
string
HtmlBody
string
TextBody
string
Headers
Array<object>
object
Name
required
string
Value
required
string
MessageID
string
Attachments
Array<object>
object
Name
required
string
Content
required
string
ContentType
string
ContentLength
number
Responses
Section titled “Responses”OK
Validation failed
Media typeapplication/json
object
error
required
string
code
string
message
string
details
Array<object>
object
field
required
string
message
required
string
code
required
string
Examplegenerated
{ "error": "example", "code": "example", "message": "example", "details": [ { "field": "example", "message": "example", "code": "example" } ]}Rate limit exceeded
Media typeapplication/json
object
error
required
string
code
string
message
string
details
Array<object>
object
field
required
string
message
required
string
code
required
string
Examplegenerated
{ "error": "example", "code": "example", "message": "example", "details": [ { "field": "example", "message": "example", "code": "example" } ]}