The Email Template Generator produces fully-styled, responsive HTML email content using Google’s Gemini 2.5 Flash model, which acts as an expert HTML email copywriter. You can guide the output with a tone, email type, participants, and a list of key points — or pick one of five built-in preset templates. The returned HTML uses inline CSS only and omitsDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/nayalsaurav/ai360/llms.txt
Use this file to discover all available pages before exploring further.
<html>, <head>, and <body> wrapper tags, so it can be dropped directly into any email-sending pipeline.
Request
keyPoints (a non-empty array) or template (a valid preset name) must be provided. All other fields are optional and act as style hints.
The desired tone of the email. Examples:
formal, friendly, urgent,
professional, casual. Defaults to formal when omitted.The category of email. Examples:
business, marketing, transactional,
announcement. Defaults to business when omitted.Who the email is addressed to (e.g.
"a prospective client", "John").
Defaults to "a client" when omitted.The sender’s name or role (e.g.
"Alice from Acme Support"). Defaults to
"a professional" when omitted.The sending organisation’s name, used in the header and signature. Defaults
to
"an organization" when omitted.An array of bullet points or topics the email body should address. Either
this field (non-empty) or
template must be present.A preset template name. One of:
Either this field or
| Value | Description |
|---|---|
invoice | Payment reminder with billing details, amount due, due date, and payment link. |
login | Login verification / OTP email with verification code, expiry, and security note. |
account_creation | Welcome email confirming sign-up and introducing platform features. |
newsletter | Newsletter with recent updates, product highlights, and social links. |
password_reset | Password-reset email with a secure link, expiry, and safety tips. |
keyPoints (non-empty) must be present.Response
A successful request returns HTTP 200 with the following body:Always
true on a successful generation.Responsive HTML email content with inline CSS. Does not include
<html>, <head>, or <body> wrapper tags — only the inner email
content section.Error Responses
| Status | Body | Cause |
|---|---|---|
400 | { "error": "Please provide key points or select a template." } | Both keyPoints and template are absent or keyPoints is an empty array. |
500 | { "error": "Internal server error", "message": "<detail>" } | Gemini API call failed, returned no HTML, or another unexpected error occurred. |
The generated HTML is intended to be placed inside an email body container by
your sending provider (SendGrid, Resend, SES, etc.). Do not wrap it in
additional
<html> or <body> tags.