curl --request POST \
--url http://localhost:3001/api/v1/mail/inbound \
--header 'Content-Type: application/json' \
--cookie nut-session= \
--data '
{
"type": "email.received",
"data": {
"email_id": "<string>",
"created_at": "<string>",
"from": "<string>",
"to": [
"<string>"
],
"cc": [
"<string>"
],
"bcc": [
"<string>"
],
"subject": "<string>",
"message_id": "<string>",
"body": "<string>",
"text": "<string>",
"html": "<string>",
"attachments": [
{
"id": "<string>",
"filename": "<string>",
"content_type": "<string>",
"content_disposition": "<string>",
"content_id": "<string>"
}
]
},
"created_at": "2023-11-07T05:31:56Z"
}
'{
"success": true,
"data": {
"message": {
"id": "<string>",
"emailId": "<string>",
"from": "Acme <hello@acme.com>",
"to": [
"<string>"
],
"subject": "<string>",
"folder": "inbox",
"cc": [
"<string>"
],
"bcc": [
"<string>"
],
"messageId": "<string>",
"attachments": [
{
"id": "<string>",
"filename": "<string>",
"contentType": "<string>",
"contentDisposition": "<string>",
"contentId": "<string>"
}
],
"receivedAt": "2023-11-07T05:31:56Z",
"content": "<string>"
}
}
}Webhook endpoint for receiving inbound emails from Resend.
Expects the Resend email.received webhook payload format.
curl --request POST \
--url http://localhost:3001/api/v1/mail/inbound \
--header 'Content-Type: application/json' \
--cookie nut-session= \
--data '
{
"type": "email.received",
"data": {
"email_id": "<string>",
"created_at": "<string>",
"from": "<string>",
"to": [
"<string>"
],
"cc": [
"<string>"
],
"bcc": [
"<string>"
],
"subject": "<string>",
"message_id": "<string>",
"body": "<string>",
"text": "<string>",
"html": "<string>",
"attachments": [
{
"id": "<string>",
"filename": "<string>",
"content_type": "<string>",
"content_disposition": "<string>",
"content_id": "<string>"
}
]
},
"created_at": "2023-11-07T05:31:56Z"
}
'{
"success": true,
"data": {
"message": {
"id": "<string>",
"emailId": "<string>",
"from": "Acme <hello@acme.com>",
"to": [
"<string>"
],
"subject": "<string>",
"folder": "inbox",
"cc": [
"<string>"
],
"bcc": [
"<string>"
],
"messageId": "<string>",
"attachments": [
{
"id": "<string>",
"filename": "<string>",
"contentType": "<string>",
"contentDisposition": "<string>",
"contentId": "<string>"
}
],
"receivedAt": "2023-11-07T05:31:56Z",
"content": "<string>"
}
}
}Session cookie authentication