generate_email
Create a brand-aware email template from a natural language prompt, returning layout instructions and expert guidance for producing MJML, ready for compilation into final HTML.
Instructions
Generate a professional email template from a natural language prompt. Returns expert system prompts, brand context, layout instructions, and a user instruction for the AI to produce MJML. After generating MJML, call compile_mjml to get the final HTML.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"prompt": "<prompt>"
},
"name": "generate_email"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | No | Email type. Auto-detected from prompt if not specified. | |
| style | No | Layout style preference (e.g., "minimalist", "hero", "grid"). Picks a matching variant. | |
| prompt | Yes | Description of the email to generate (e.g., "Create a welcome email for new subscribers") | |
| brand_id | No | Brand profile ID to use. Uses the most recently updated brand if not specified. |