For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Help CenterAPI KeysStatusSign In
GuidesAPI ReferenceChangelog
GuidesAPI ReferenceChangelog
  • Introduction
    • Getting started
  • Email API
      • GETGet the list of email templates
      • DELDelete an inactive email template
      • POSTSend a template to your test list
      • POSTGenerate the rendered preview of transactional template
      • PUTUpdate an email template
      • GETReturns the template information
      • POSTCreate an email template
  • Transactional SMS
  • Transactional WhatsApp
  • Marketing Campaigns
  • Contact Management
  • Events
    • GETGet events
    • POSTCreate an event
    • POSTCreate events in batch
  • Object Management
  • Accounts and Settings
  • Sales CRM
  • Conversations
  • Ecommerce
  • Loyalty
LogoLogo
Help CenterAPI KeysStatusSign In
Email APIEmail templates

Send a template to your test list

POST
https://api.brevo.com/v3/smtp/templates/:templateId/sendTest
POST
/v3/smtp/templates/:templateId/sendTest
1import { BrevoClient } from "@getbrevo/brevo";
2
3async function main() {
4 const client = new BrevoClient({
5 apiKey: "YOUR_API_KEY_HERE",
6 });
7 await client.transactionalEmails.sendTestTemplate(1, {
8 body: {},
9 });
10}
11main();

Send a test email of the specified transactional template to one or more recipients. Provide an array of email addresses in the emailTo field; if left empty, the test mail is sent to your entire test list. You can send a maximum of 50 test emails per day, and all provided email addresses must be valid.

Was this page helpful?
Previous

Generate the rendered preview of transactional template

Next
Built with

Authentication

api-keystring

The API key should be passed in the request headers as api-key for authentication.

Path parameters

templateIdlongRequired
Id of the template

Request

This endpoint expects an object.
emailTolist of stringsOptional

List of the email addresses of the recipients whom you wish to send the test mail. If left empty, the test mail will be sent to your entire test list. You can not send more than 50 test emails per day.

Response

Test email has been sent successfully to all recipients

Errors

400
Bad Request Error
404
Not Found Error