import { TemplateExecutor } from 'lodash'; import { UAGTemplateConfig } from './config'; /** * Template names enum for type safety */ export declare enum ResponseTemplate { collectedData = "collectedData", fieldRules = "fieldRules", allFieldsCollected = "allFieldsCollected", getFormFieldsEmpty = "getFormFieldsEmpty", getFormFieldsInfo = "getFormFieldsInfo", fieldCollectedNext = "fieldCollectedNext", submitValidationError = "submitValidationError", formSubmitted = "formSubmitted", listAvailableForms = "listAvailableForms", confirmFormSubmission = "confirmFormSubmission", getOptionalFields = "getOptionalFields", formNotFound = "formNotFound", noSubmissionsFound = "noSubmissionsFound", submissionsFound = "submissionsFound", submissionCount = "submissionCount", submissionSearchError = "submissionSearchError", submissionNotFound = "submissionNotFound", updateNotConfirmed = "updateNotConfirmed", submissionUpdateError = "submissionUpdateError", submissionUpdated = "submissionUpdated", submissionPartialIdAmbiguous = "submissionPartialIdAmbiguous", submissionPartialIdNotFound = "submissionPartialIdNotFound", getFormFields = "getFormFields", getFormFieldsError = "getFormFieldsError", fieldValidationErrors = "fieldValidationErrors", fields = "fields", fieldList = "fieldList", fieldValues = "fieldValues", formData = "formData", getAvailableForms = "getAvailableForms", noFormsAvailable = "noFormsAvailable", uagComponentNotFound = "uagComponentNotFound", agentProcessData = "agentProcessData", fetchExternalData = "fetchExternalData", fetchExternalDataError = "fetchExternalDataError" } export declare class UAGTemplate { config: UAGTemplateConfig; templateCache: Map; constructor(config?: UAGTemplateConfig); /** * Get a template by name * @param templateName The name of the template * @returns The compiled template function */ getTemplate(templateName: ResponseTemplate): TemplateExecutor; /** * Render a template with data * @param templateName The name of the template * @param data The data to render the template with * @returns The rendered template */ renderTemplate(templateName: ResponseTemplate, data?: object): string; }