dancecard-email-schemas
Version:
Schemas for objects for Dancecard Email Nurturing System
49 lines (46 loc) • 1.22 kB
JavaScript
let Template = {
"id": "./Template",
"title": "Template",
"description": "A Template for either a page behind or an email.",
"type": "object",
"properties": {
"_id": {
"description": "Unique ID generated by database.",
"type": "string"
},
"template_name": {
"description": "User provided Template ID/Name.",
"type": "string"
},
"template_type": {
"description": 'String: either "Email" or "Page Behind"',
"type": "string",
"enum": ["Email", "Page Behind"]
},
"url": {
"description": "URL where Jinja email template is stored",
"type": "string"
},
"page_behind": {
"description": "Object that denotes the name of the page behind template and its Unique ID generated by database.",
"anyOf": [
{
"$ref": "./Template"
},
{
"type": null
}
]
},
"blocks": {
"description": "List of all blocks that are in this email.",
"type": "array",
"minItems": 0,
"items": {
"$ref": "./TemplateBlock"
}
}
},
"required": ["template_name", "template_type", "url", "page_behind", "blocks"]
}
export { Template }