Navigation

send

On this page

Definition

send

Sends an email message to a specified address.

The send action stage has the following syntax:

{ "service": <mailgun-servicename>, "action": "send", "args": { "from": <string>, "to": <array-of-strings>, "subject": <string>, "text": <string> } }

The send action takes the following arguments:

Argument Type Description
from string The sender’s email address.
to string The recipient’s email address.
subject string The subject of the email.
text string The body of the message.

Example

The following is a pipeline consisting of a send stage:

[
  {
    "service": "my-mailgun-service",
    "action": "send",
    "args": {
      "text": "Mailgun test message body",
      "to": "email@example.com",
      "from": "other-address@example.com",
      "subject": "Test subject"
    }
  }
]