Skip to main content

IBaseTemplate

Base interface for all message templates in the system.

Defines common properties and functionality shared between email templates and document templates, including content management, localization, data integration, and metadata tracking.

interface IBaseTemplate {
id: String!
contents: [LocalizedTemplateContent!]
names: [LocalizedString!]!
content: String
customQuery: String
queryVariables: String
createdAt: DateTime!
lastModifiedAt: DateTime!
createdBy: Int
lastModifiedBy: Int
}

Fields

IBaseTemplate.id ● String! non-null scalar

Unique identifier for the message template.

Used to reference and manage specific templates throughout the messaging system for emails, documents, and notifications.

IBaseTemplate.contents ● [LocalizedTemplateContent!] list object

Handlebars template content for each supported language.

The actual template markup using Handlebars syntax for dynamic content generation, stored per language for localization support.

IBaseTemplate.names ● [LocalizedString!]! non-null object

Localized template names for different languages.

Human-readable names for the template in various languages, used for template identification and management in multilingual environments.

IBaseTemplate.content ● String scalar

Compiled template content for rendering.

The processed template content ready for variable substitution and message generation, derived from the localized contents based on the target language.

IBaseTemplate.customQuery ● String scalar

GraphQL query for additional data enrichment.

Custom query executed before template rendering to fetch supplementary data not included in the original event payload, enabling rich template content.

IBaseTemplate.queryVariables ● String scalar

Variables for custom GraphQL query execution.

JSON object containing variables used in the custom query, supports Handlebars expressions for dynamic variable generation based on event data.

IBaseTemplate.createdAt ● DateTime! non-null scalar

Template creation timestamp.

Date and time when this template was initially created in the system, used for auditing and template lifecycle management.

IBaseTemplate.lastModifiedAt ● DateTime! non-null scalar

Template last modification timestamp.

Date and time when any template content or configuration was last updated, used for change tracking and version control.

IBaseTemplate.createdBy ● Int scalar

Template creator user identifier.

ID of the user who originally created this template, used for ownership tracking and access control.

IBaseTemplate.lastModifiedBy ● Int scalar

Template last editor user identifier.

ID of the user who most recently modified this template, used for change attribution and audit trails.

Returned By

template query

Member Of

TemplateResponse object

Implemented By

DocumentTemplate object ● EmailTemplate object