API ReferenceTemplates
Preview Email AST
Render a JSON AST email template to HTML without saving. Useful for live preview in the visual editor.
Authorization
apiKey X-API-Key<token>
API key for authentication
In: header
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
curl -X POST "https://samva.app/api/v1/templates/preview-ast" \ -H "Content-Type: application/json" \ -d '{ "ast": { "version": 1 }, "subject": "string" }'{
"html": "string",
"text": "string",
"subject": "string",
"missingVariables": [
"string"
],
"detectedVariables": [
"string"
],
"issues": [
"string"
]
}