Skip to main content

Send a Test Email

Send a one-off test email of a campaign to a single address.

A test email lets you preview a campaign in a real inbox while you are still building it. The campaign's current subject, body, and sender are rendered and sent to the address you provide, with placeholder contact data — personalization merge tags show sample values (such as a name like John Doe) rather than a real contact's details.

A test is a preview only. It does not start the real send, does not reach the campaign's audience, does not record recipients, and does not change the campaign's status. You can send a test from a campaign in any status. A test is still a real outbound email, so if the send is rejected the call returns 409 TEST_SEND_FAILED.

Because it is a real outbound email, your account must be allowed to send. If it is not, the call returns 403 PLAN_INACTIVE and no test email goes out. See Active plan required.

Testability​

A campaign can be tested once it has the three things needed to render the email: a subject, a body (content), and a sender identity (from_identity). If any are missing, the request returns 422 CAMPAIGN_NOT_TESTABLE, and details.missing lists which are absent — a subset of subject, content, and sender_identity.

This is a smaller set than the readiness a real send requires: a test does not need an audience or a from_name.

Missing keyHow to satisfy
subjectSet subject on the campaign.
contentSet the email body with the content field. See Campaign body.
sender_identitySet from_identity to a sender identity.

The sender identity must also be ready to send from. A campaign whose sender is not returns 409 SENDER_NOT_SENDABLE — check is_sendable on the identity, and see Sending readiness.

Rate Limit​

Test sends are limited to 20 per hour and 100 per day per account, counted across every campaign and automation test. Exceeding either limit returns 429 TEST_MESSAGE_RATE_LIMITED.

Request​

POST /campaigns/{uuid}/test

Path Parameters​

ParameterTypeDescription
uuidstringCampaign's UUID

Request Body​

ParameterTypeRequiredDescription
emailstringYesThe single address that receives the test email. A missing or invalid address returns 422 VALIDATION_ERROR.
languagestringNoAn ISO 639-1 language code (two letters) to preview a specific translation. Omit to use the campaign's own language. A value that is not a valid code returns 422 VALIDATION_ERROR.

To send a test to several inboxes, call this endpoint once per address.

Example Requests​

curl -X POST "https://email.easy.tools/api/v1/campaigns/c0578a15-1b1d-41e4-8dd3-caa3ac7ccf47/test" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"email": "you@example.com"
}'

To preview a specific translation, include language:

curl -X POST "https://email.easy.tools/api/v1/campaigns/c0578a15-1b1d-41e4-8dd3-caa3ac7ccf47/test" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
-d '{
"email": "you@example.com",
"language": "en"
}'

Response​

Success Response (204 No Content)​

On success the API returns 204 No Content with an empty body. The test email is sent to the address you provided.

Error Responses​

Forbidden Error (403 — Plan Inactive)​

The account is not allowed to send. No test email goes out and the campaign is unchanged. See Active plan required.

{
"error": {
"code": "PLAN_INACTIVE",
"message": "Sending is not allowed for this account."
}
}

Not Found Error (404)​

The campaign UUID is unknown or malformed.

{
"error": {
"code": "RESOURCE_NOT_FOUND",
"message": "Campaign with UUID 'c0578a15-1b1d-41e4-8dd3-caa3ac7ccf47' not found"
}
}

Validation Error (422 Unprocessable Entity)​

email is missing or invalid, or language is not a valid ISO 639-1 code.

{
"error": {
"code": "VALIDATION_ERROR",
"message": "The given data was invalid",
"details": {
"email": ["The email field is required."]
}
}
}

Validation Error (422 — Not Testable)​

The campaign is missing one or more of the fields a test needs to render. details.missing lists which of subject, content, and sender_identity are absent. See Testability.

{
"error": {
"code": "CAMPAIGN_NOT_TESTABLE",
"message": "Campaign is not complete enough to send a test",
"details": {
"missing": ["subject", "content"]
}
}
}

Conflict Error (409 — Sender Not Sendable)​

The campaign's sender identity is not ready to send from. See Testability.

{
"error": {
"code": "SENDER_NOT_SENDABLE",
"message": "The sender identity of this campaign is not enabled for sending."
}
}

Conflict Error (409 — Test Send Failed)​

The test email could not be delivered — for example because a sending quota was exhausted. Retry later.

{
"error": {
"code": "TEST_SEND_FAILED",
"message": "The test email could not be sent. Please try again later."
}
}

Rate Limit Error (429 Too Many Requests)​

The account exceeded 20 test sends per hour or 100 per day. See Rate Limit.

{
"error": {
"code": "TEST_MESSAGE_RATE_LIMITED",
"message": "Too many test messages have been sent. Please try again later."
}
}

Service Unavailable Error (503)​

The account's plan could not be verified. No test email goes out and the campaign is unchanged. Retry the request. See Active plan required.

{
"error": {
"code": "SERVICE_UNAVAILABLE",
"message": "The request could not be completed. Try again shortly."
}
}