Send Transactional Email
Send a transactional email using one of your published email designs. Perfect for password resets, order confirmations, welcome emails, and other triggered communications. You can include dynamic data variables, file attachments, and when adding to your audience, set contact information like names, subscription groups, and other contact data.
Authorizations
Include your Brew API key as a Bearer token in the Authorization header.
Example: Authorization: Bearer bw_api_your_key_here
Headers
Unique identifier to prevent duplicate emails. Use this to safely retry requests without sending duplicate emails. We recommend using UUIDs or another method with sufficient entropy to avoid collisions. Keys expire after 24 hours and should be up to 100 characters.
100
Body
Specify the recipient, email design to use, and any dynamic data. Optionally add the contact to your audience with basic contact information like names and subscription groups.
Contact Matching (when addToAudience is true): You can provide email, userId, or both to identify the contact. When both are provided, Brew searches for a contact matching either identifier. If a contact is found (for example, by email), the other identifier (userId) will be updated on that contact. If no existing contact matches either identifier, a new contact is created with both values.
Request body for sending a transactional email
Response
Email sent successfully
Success response for transactional email sending