Send Mailer Endpoint

Send emails to users from your workspace.

Headers

Body Parameter

Example Call

curl --location 'http://localhost:3000/api/v1/mailer' \
--header 'x-auth-token: 1C9ajI4zUSlsefEchqaBesENo9Hw7Qa-Vh9x3VrS1iQ' \
--header 'x-user-id: rbAXPnMktTFbNpwtJ' \
--header 'Content-Type: application/json' \
--data-raw '{
    "from":"test.funke@test.com",
    "subject":"Welcome to the Test Newsletter",
    "body":"Thank you for subscribing to the Test Newsletter. If this was not you feelfree to unsubscribe by hitting the following button [unsubscribe]"

}'

Example Result

Success

{
    "success": true
}

Errors

The following errors can occur upon the endpoint.

  • Authorization: Requires an authentication token for the request to be made.

  • Invalid From Address: The from parameter was be a valid email address.

{
    "status": "error",
    "message": "You must be logged in to do this."
}

Change Log

Last updated

Rocket.Chat versions receive support for six months after release.