← Back to listing
POST/api/v1/mail/send

Send mail from a connected mailbox

Sends an email using an active connected mailbox. Intended for automations such as n8n that need to send from the customer's connected mailbox.

Authentication

Send your API key in the x-api-key header.

x-api-keybearer

Request body

required

PublicApiSendMailRequestDto

grantId

string

Optional connected mailbox identifier. Prefer senderEmail so the backend resolves the active mailbox.

senderEmail

string

Email address of the connected mailbox. Must match the configured mailbox.

fromName

string

torequired

array<PublicApiMailAddressDto>

cc

array<PublicApiMailAddressDto>

bcc

array<PublicApiMailAddressDto>

replyTo

array<PublicApiMailAddressDto>

replyToMessageId

string

subjectrequired

string

html

string

HTML email body.

text

string

Plain text fallback body.

metadata

object

Optional metadata for tracing the n8n execution.

Example request

json
{
  "grantId": "",
  "senderEmail": "sender@example.com",
  "fromName": "Example Sender",
  "to": [
    {
      "email": "cliente@example.com",
      "name": "Example Customer"
    }
  ],
  "cc": [
    {
      "email": "cliente@example.com",
      "name": "Example Customer"
    }
  ],
  "bcc": [
    {
      "email": "cliente@example.com",
      "name": "Example Customer"
    }
  ],
  "replyTo": [
    {
      "email": "cliente@example.com",
      "name": "Example Customer"
    }
  ],
  "replyToMessageId": "",
  "subject": "Information about your request",
  "html": "",
  "text": "",
  "metadata": ""
}

Responses

200

PublicApiSendMailResponseDto

statusCoderequired

number

countrequired

number

errorrequired

string

datarequired

PublicApiSendMailResultDto

Example response

json
{
  "statusCode": 200,
  "count": 0,
  "error": null,
  "data": {
    "messageId": null,
    "threadId": null,
    "senderEmail": "",
    "to": [
      {
        "email": "cliente@example.com",
        "name": "Example Customer"
      }
    ]
  }
}
400Invalid request payload or inactive connected mailbox
401Unauthorized - missing or invalid API key or Bearer token
404No active connected mailbox found for the sender
502The connected mail service failed to send the email