Code Block | ||
---|---|---|
| ||
POST /es/api/v1/mailer/send Content-Type: application/json { "from_email": "[email protected]", "to_email": "user@example["[email protected]", "recipient2@mail.com"], "subject": "Hello", "data_url": "http://example.com/", "username": "John" } |
Code Block |
---|
"Email sent successfully" |
Code Block |
---|
{ "detail": [ { "loc": ["body", "to_email"], "msg": "Field required", "type": "value_error.missing" } ] } |
If you intend to use Gmail as the SMTP server for this mailer, be sure to have the email (and Google) account ready for it.
Because if you configure the Mailer section with an email and it's correct password, this issue is going to appear:
This is because Google enforces the usage of Application passwords when allowing access to an account instead of the Account Password.
To enable this Application password you need to follow these steps: