@defra/forms-model 3.0.540 → 3.0.542

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,7 +17,6 @@ export let AuditEventMessageSource = /*#__PURE__*/function (AuditEventMessageSou
17
17
  }({});
18
18
  export let AuditEventMessageType = /*#__PURE__*/function (AuditEventMessageType) {
19
19
  AuditEventMessageType["FORM_CREATED"] = "FORM_CREATED";
20
- AuditEventMessageType["FORM_PUBLISHED"] = "FORM_PUBLISHED";
21
20
  AuditEventMessageType["FORM_TITLE_UPDATED"] = "FORM_TITLE_UPDATED";
22
21
  AuditEventMessageType["FORM_ORGANISATION_UPDATED"] = "FORM_ORGANISATION_UPDATED";
23
22
  AuditEventMessageType["FORM_TEAM_NAME_UPDATED"] = "FORM_TEAM_NAME_UPDATED";
@@ -1 +1 @@
1
- {"version":3,"file":"enums.js","names":["AuditEventMessageSchemaVersion","AuditEventMessageCategory","AuditEventMessageSource","AuditEventMessageType","FormDefinitionRequestType"],"sources":["../../../../src/form/form-audit/enums.ts"],"sourcesContent":["export enum AuditEventMessageSchemaVersion {\n V1 = 1\n}\n\nexport enum AuditEventMessageCategory {\n FORM = 'FORM',\n ENTITLEMENT = 'ENTITLEMENT',\n AUTHENTICATION = 'AUTHENTICATION'\n}\n\nexport enum AuditEventMessageSource {\n FORMS_MANAGER = 'FORMS_MANAGER',\n FORMS_DESIGNER = 'FORMS_DESIGNER',\n ENTITLEMENT = 'ENTITLEMENT',\n AUTHENTICATION = 'AUTHENTICATION'\n}\n\nexport enum AuditEventMessageType {\n // FORM message types\n FORM_CREATED = 'FORM_CREATED',\n FORM_PUBLISHED = 'FORM_PUBLISHED',\n FORM_TITLE_UPDATED = 'FORM_TITLE_UPDATED',\n FORM_ORGANISATION_UPDATED = 'FORM_ORGANISATION_UPDATED',\n FORM_TEAM_NAME_UPDATED = 'FORM_TEAM_NAME_UPDATED',\n FORM_TEAM_EMAIL_UPDATED = 'FORM_TEAM_EMAIL_UPDATED',\n FORM_SUPPORT_CONTACT_UPDATED = 'FORM_SUPPORT_CONTACT_UPDATED',\n FORM_SUPPORT_PHONE_UPDATED = 'FORM_SUPPORT_PHONE_UPDATED',\n FORM_SUPPORT_EMAIL_UPDATED = 'FORM_SUPPORT_EMAIL_UPDATED',\n FORM_SUPPORT_ONLINE_UPDATED = 'FORM_SUPPORT_ONLINE_UPDATED',\n FORM_PRIVACY_NOTICE_UPDATED = 'FORM_PRIVACY_NOTICE_UPDATED',\n FORM_NOTIFICATION_EMAIL_UPDATED = 'FORM_NOTIFICATION_EMAIL_UPDATED',\n FORM_SUBMISSION_GUIDANCE_UPDATED = 'FORM_SUBMISSION_GUIDANCE_UPDATED',\n FORM_JSON_UPLOADED = 'FORM_JSON_UPLOADED',\n FORM_JSON_DOWNLOADED = 'FORM_JSON_DOWNLOADED',\n FORM_DRAFT_CREATED_FROM_LIVE = 'FORM_DRAFT_CREATED_FROM_LIVE',\n FORM_LIVE_CREATED_FROM_DRAFT = 'FORM_LIVE_CREATED_FROM_DRAFT',\n FORM_DRAFT_DELETED = 'FORM_DRAFT_DELETED',\n FORM_MIGRATED = 'FORM_MIGRATED',\n FORM_UPDATED = 'FORM_UPDATED',\n\n // ENTITLEMENT message types\n ENTITLEMENT_CREATED = 'ENTITLEMENT_CREATED',\n ENTITLEMENT_UPDATED = 'ENTITLEMENT_UPDATED',\n ENTITLEMENT_DELETED = 'ENTITLEMENT_DELETED',\n\n // AUTHENTICATION message types\n AUTHENTICATION_LOGIN = 'AUTHENTICATION_LOGIN',\n AUTHENTICATION_LOGOUT_MANUAL = 'AUTHENTICATION_LOGOUT_MANUAL',\n AUTHENTICATION_LOGOUT_AUTO = 'AUTHENTICATION_LOGOUT_AUTO',\n AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE = 'AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE'\n}\n\nexport enum FormDefinitionRequestType {\n REPLACE_DRAFT = 'REPLACE_DRAFT',\n CREATE_COMPONENT = 'CREATE_COMPONENT',\n UPDATE_COMPONENT = 'UPDATE_COMPONENT',\n DELETE_COMPONENT = 'DELETE_COMPONENT',\n CREATE_CONDITION = 'CREATE_CONDITION',\n UPDATE_CONDITION = 'UPDATE_CONDITION',\n DELETE_CONDITION = 'DELETE_CONDITION',\n REORDER_PAGES = 'REORDER_PAGES',\n REORDER_COMPONENTS = 'REORDER_COMPONENTS',\n CREATE_LIST = 'CREATE_LIST',\n UPDATE_LIST = 'UPDATE_LIST',\n DELETE_LIST = 'DELETE_LIST',\n CREATE_PAGE = 'CREATE_PAGE',\n UPDATE_PAGE_FIELDS = 'UPDATE_PAGE_FIELDS',\n DELETE_PAGE = 'DELETE_PAGE',\n REPOSITION_SUMMARY = 'REPOSITION_SUMMARY'\n}\n"],"mappings":"AAAA,WAAYA,8BAA8B,0BAA9BA,8BAA8B;EAA9BA,8BAA8B,CAA9BA,8BAA8B;EAAA,OAA9BA,8BAA8B;AAAA;AAI1C,WAAYC,yBAAyB,0BAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAA,OAAzBA,yBAAyB;AAAA;AAMrC,WAAYC,uBAAuB,0BAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAA,OAAvBA,uBAAuB;AAAA;AAOnC,WAAYC,qBAAqB,0BAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;AAmCjC,WAAYC,yBAAyB,0BAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAA,OAAzBA,yBAAyB;AAAA","ignoreList":[]}
1
+ {"version":3,"file":"enums.js","names":["AuditEventMessageSchemaVersion","AuditEventMessageCategory","AuditEventMessageSource","AuditEventMessageType","FormDefinitionRequestType"],"sources":["../../../../src/form/form-audit/enums.ts"],"sourcesContent":["export enum AuditEventMessageSchemaVersion {\n V1 = 1\n}\n\nexport enum AuditEventMessageCategory {\n FORM = 'FORM',\n ENTITLEMENT = 'ENTITLEMENT',\n AUTHENTICATION = 'AUTHENTICATION'\n}\n\nexport enum AuditEventMessageSource {\n FORMS_MANAGER = 'FORMS_MANAGER',\n FORMS_DESIGNER = 'FORMS_DESIGNER',\n ENTITLEMENT = 'ENTITLEMENT',\n AUTHENTICATION = 'AUTHENTICATION'\n}\n\nexport enum AuditEventMessageType {\n // FORM message types\n FORM_CREATED = 'FORM_CREATED',\n FORM_TITLE_UPDATED = 'FORM_TITLE_UPDATED',\n FORM_ORGANISATION_UPDATED = 'FORM_ORGANISATION_UPDATED',\n FORM_TEAM_NAME_UPDATED = 'FORM_TEAM_NAME_UPDATED',\n FORM_TEAM_EMAIL_UPDATED = 'FORM_TEAM_EMAIL_UPDATED',\n FORM_SUPPORT_CONTACT_UPDATED = 'FORM_SUPPORT_CONTACT_UPDATED',\n FORM_SUPPORT_PHONE_UPDATED = 'FORM_SUPPORT_PHONE_UPDATED',\n FORM_SUPPORT_EMAIL_UPDATED = 'FORM_SUPPORT_EMAIL_UPDATED',\n FORM_SUPPORT_ONLINE_UPDATED = 'FORM_SUPPORT_ONLINE_UPDATED',\n FORM_PRIVACY_NOTICE_UPDATED = 'FORM_PRIVACY_NOTICE_UPDATED',\n FORM_NOTIFICATION_EMAIL_UPDATED = 'FORM_NOTIFICATION_EMAIL_UPDATED',\n FORM_SUBMISSION_GUIDANCE_UPDATED = 'FORM_SUBMISSION_GUIDANCE_UPDATED',\n FORM_JSON_UPLOADED = 'FORM_JSON_UPLOADED',\n FORM_JSON_DOWNLOADED = 'FORM_JSON_DOWNLOADED',\n FORM_DRAFT_CREATED_FROM_LIVE = 'FORM_DRAFT_CREATED_FROM_LIVE',\n FORM_LIVE_CREATED_FROM_DRAFT = 'FORM_LIVE_CREATED_FROM_DRAFT',\n FORM_DRAFT_DELETED = 'FORM_DRAFT_DELETED',\n FORM_MIGRATED = 'FORM_MIGRATED',\n FORM_UPDATED = 'FORM_UPDATED',\n\n // ENTITLEMENT message types\n ENTITLEMENT_CREATED = 'ENTITLEMENT_CREATED',\n ENTITLEMENT_UPDATED = 'ENTITLEMENT_UPDATED',\n ENTITLEMENT_DELETED = 'ENTITLEMENT_DELETED',\n\n // AUTHENTICATION message types\n AUTHENTICATION_LOGIN = 'AUTHENTICATION_LOGIN',\n AUTHENTICATION_LOGOUT_MANUAL = 'AUTHENTICATION_LOGOUT_MANUAL',\n AUTHENTICATION_LOGOUT_AUTO = 'AUTHENTICATION_LOGOUT_AUTO',\n AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE = 'AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE'\n}\n\nexport enum FormDefinitionRequestType {\n REPLACE_DRAFT = 'REPLACE_DRAFT',\n CREATE_COMPONENT = 'CREATE_COMPONENT',\n UPDATE_COMPONENT = 'UPDATE_COMPONENT',\n DELETE_COMPONENT = 'DELETE_COMPONENT',\n CREATE_CONDITION = 'CREATE_CONDITION',\n UPDATE_CONDITION = 'UPDATE_CONDITION',\n DELETE_CONDITION = 'DELETE_CONDITION',\n REORDER_PAGES = 'REORDER_PAGES',\n REORDER_COMPONENTS = 'REORDER_COMPONENTS',\n CREATE_LIST = 'CREATE_LIST',\n UPDATE_LIST = 'UPDATE_LIST',\n DELETE_LIST = 'DELETE_LIST',\n CREATE_PAGE = 'CREATE_PAGE',\n UPDATE_PAGE_FIELDS = 'UPDATE_PAGE_FIELDS',\n DELETE_PAGE = 'DELETE_PAGE',\n REPOSITION_SUMMARY = 'REPOSITION_SUMMARY'\n}\n"],"mappings":"AAAA,WAAYA,8BAA8B,0BAA9BA,8BAA8B;EAA9BA,8BAA8B,CAA9BA,8BAA8B;EAAA,OAA9BA,8BAA8B;AAAA;AAI1C,WAAYC,yBAAyB,0BAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAA,OAAzBA,yBAAyB;AAAA;AAMrC,WAAYC,uBAAuB,0BAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAvBA,uBAAuB;EAAA,OAAvBA,uBAAuB;AAAA;AAOnC,WAAYC,qBAAqB,0BAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;AAkCjC,WAAYC,yBAAyB,0BAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAzBA,yBAAyB;EAAA,OAAzBA,yBAAyB;AAAA","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","names":[],"sources":["../../../../src/form/form-audit/types.ts"],"sourcesContent":["import {\n type AuditEventMessageCategory,\n type AuditEventMessageSchemaVersion,\n type AuditEventMessageSource,\n type AuditEventMessageType,\n type FormDefinitionRequestType\n} from '~/src/form/form-audit/enums.js'\nimport { type FormMetadataContact } from '~/src/form/form-metadata/types.js'\n\nexport interface FormMessageDataBase {\n formId: string\n slug: string\n payload?: unknown\n}\n\nexport interface ChangesMessageData<T> {\n previous: T\n new: T\n}\n\nexport interface FormCreatedMessageData extends FormMessageDataBase {\n title: string\n organisation: string\n teamName: string\n teamEmail: string\n}\n\nexport interface FormTitleChanges {\n title: string\n}\n\nexport interface FormOrganisationChanges {\n organisation: string\n}\n\nexport interface FormTeamNameChanges {\n teamName: string\n}\n\nexport interface FormTeamEmailChanges {\n teamEmail: string\n}\n\nexport interface FormSupportContactChanges {\n contact?: FormMetadataContact\n}\n\nexport interface FormSupportPhoneChanges {\n phone?: string\n}\n\nexport interface FormSupportEmailChanges {\n address?: string\n responseTime?: string\n}\n\nexport interface FormSupportOnlineChanges {\n url?: string\n text?: string\n}\n\nexport interface FormPrivacyNoticeChanges {\n privacyNoticeUrl?: string\n}\n\nexport interface FormNotificationEmailChanges {\n notificationEmail?: string\n}\n\nexport interface FormSubmissionGuidanceChanges {\n submissionGuidance?: string\n}\n\nexport interface FormUploadedChanges {\n value: string\n}\n\nexport interface FormTitleUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTitleChanges>\n}\n\nexport interface FormOrganisationUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormOrganisationChanges>\n}\n\nexport interface FormTeamNameUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTeamNameChanges>\n}\n\nexport interface FormTeamEmailUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTeamEmailChanges>\n}\n\nexport interface FormSupportContactUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportContactChanges>\n}\n\nexport interface FormSupportPhoneUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportPhoneChanges>\n}\n\nexport interface FormSupportEmailUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportEmailChanges>\n}\n\nexport interface FormSupportOnlineUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportOnlineChanges>\n}\n\nexport interface FormPrivacyNoticeUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormPrivacyNoticeChanges>\n}\n\nexport interface FormNotificationEmailUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormNotificationEmailChanges>\n}\n\nexport interface FormSubmissionGuidanceUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSubmissionGuidanceChanges>\n}\n\nexport interface FormUploadedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormUploadedChanges>\n}\n\nexport interface FormDefinitionS3Meta {\n fileId: string\n filename: string\n s3Key: string\n}\n\nexport interface FormUpdatedMessageData extends FormMessageDataBase {\n requestType: FormDefinitionRequestType\n s3Meta?: FormDefinitionS3Meta\n}\n\nexport type FormMessageChangesData =\n | FormTitleUpdatedMessageData\n | FormOrganisationUpdatedMessageData\n | FormTeamNameUpdatedMessageData\n | FormTeamEmailUpdatedMessageData\n | FormSupportContactUpdatedMessageData\n | FormSupportPhoneUpdatedMessageData\n | FormSupportEmailUpdatedMessageData\n | FormSupportOnlineUpdatedMessageData\n | FormPrivacyNoticeUpdatedMessageData\n | FormNotificationEmailUpdatedMessageData\n | FormSubmissionGuidanceUpdatedMessageData\n | FormUploadedMessageData\n\nexport type FormMessageActivitiesData =\n | FormCreatedMessageData\n | FormMessageDataBase\n\nexport interface EntitlementMessageData {\n userId: string\n displayName: string\n email: string\n roles: string[]\n}\n\nexport interface AuthenticationMessageData {\n userId: string\n displayName: string\n}\n\nexport interface AuditUser {\n id: string\n displayName: string\n}\n\nexport type MessageData =\n | FormMessageChangesData\n | FormMessageActivitiesData\n | FormUpdatedMessageData\n | EntitlementMessageData\n | AuthenticationMessageData\n\nexport interface MessageBase {\n schemaVersion: AuditEventMessageSchemaVersion\n category: AuditEventMessageCategory\n source: AuditEventMessageSource\n type: AuditEventMessageType\n entityId: string\n traceId?: string\n createdAt: Date\n createdBy: AuditUser\n data?: MessageData\n messageCreatedAt: Date\n}\n\nexport interface ManagerMessageBase extends MessageBase {\n source: AuditEventMessageSource.FORMS_MANAGER\n}\nexport interface DesignerMessageBase extends MessageBase {\n source: AuditEventMessageSource.FORMS_DESIGNER\n}\n\nexport interface EntitlementMessageBase extends MessageBase {\n source: AuditEventMessageSource.ENTITLEMENT\n}\n\nexport interface AuthenticationMessageBase extends MessageBase {\n source: AuditEventMessageSource.AUTHENTICATION\n}\n\nexport interface FormCreatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_CREATED\n data: FormCreatedMessageData\n}\n\nexport interface FormTitleUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TITLE_UPDATED\n data: FormTitleUpdatedMessageData\n}\n\nexport interface FormOrganisationUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_ORGANISATION_UPDATED\n data: FormOrganisationUpdatedMessageData\n}\n\nexport interface FormTeamNameUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TEAM_NAME_UPDATED\n data: FormTeamNameUpdatedMessageData\n}\n\nexport interface FormTeamEmailUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TEAM_EMAIL_UPDATED\n data: FormTeamEmailUpdatedMessageData\n}\n\nexport interface FormSupportContactUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_CONTACT_UPDATED\n data: FormSupportContactUpdatedMessageData\n}\n\nexport interface FormSupportPhoneUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_PHONE_UPDATED\n data: FormSupportPhoneUpdatedMessageData\n}\n\nexport interface FormSupportEmailUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_EMAIL_UPDATED\n data: FormSupportEmailUpdatedMessageData\n}\n\nexport interface FormSupportOnlineUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_ONLINE_UPDATED\n data: FormSupportOnlineUpdatedMessageData\n}\n\nexport interface FormPrivacyNoticeUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_PRIVACY_NOTICE_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormPrivacyNoticeUpdatedMessageData\n}\n\nexport interface FormNotificationEmailUpdatedMessage\n extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_NOTIFICATION_EMAIL_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormNotificationEmailUpdatedMessageData\n}\n\nexport interface FormSubmissionGuidanceUpdatedMessage\n extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUBMISSION_GUIDANCE_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormSubmissionGuidanceUpdatedMessageData\n}\n\nexport interface FormUploadedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_JSON_UPLOADED\n data: FormUploadedMessageData\n}\n\nexport interface FormDownloadedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_JSON_DOWNLOADED\n}\n\nexport interface FormPublishedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_PUBLISHED\n}\n\nexport interface FormDraftCreatedFromLiveMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_DRAFT_CREATED_FROM_LIVE\n}\n\nexport interface FormLiveCreatedFromDraftMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_LIVE_CREATED_FROM_DRAFT\n}\n\nexport interface FormDraftDeletedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_DRAFT_DELETED\n}\n\nexport interface FormMigratedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_MIGRATED\n}\n\nexport interface FormUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_UPDATED\n data: FormUpdatedMessageData\n}\n\nexport interface EntitlementCreatedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_CREATED\n data: EntitlementMessageData\n}\n\nexport interface EntitlementUpdatedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_UPDATED\n data: EntitlementMessageData\n}\n\nexport interface EntitlementDeletedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_DELETED\n data: EntitlementMessageData\n}\n\nexport interface AuthenticationLoginMessage extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGIN\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutManualMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_MANUAL\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutAutoMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_AUTO\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutDifferentDeviceMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE\n data: AuthenticationMessageData\n}\n\nexport type AuditMessage =\n | FormCreatedMessage\n | FormTitleUpdatedMessage\n | FormOrganisationUpdatedMessage\n | FormTeamNameUpdatedMessage\n | FormTeamEmailUpdatedMessage\n | FormSupportContactUpdatedMessage\n | FormSupportPhoneUpdatedMessage\n | FormSupportEmailUpdatedMessage\n | FormSupportOnlineUpdatedMessage\n | FormPrivacyNoticeUpdatedMessage\n | FormNotificationEmailUpdatedMessage\n | FormSubmissionGuidanceUpdatedMessage\n | FormUploadedMessage\n | FormDownloadedMessage\n | FormPublishedMessage\n | FormDraftCreatedFromLiveMessage\n | FormLiveCreatedFromDraftMessage\n | FormDraftDeletedMessage\n | FormMigratedMessage\n | FormUpdatedMessage\n | EntitlementCreatedMessage\n | EntitlementUpdatedMessage\n | EntitlementDeletedMessage\n | AuthenticationLoginMessage\n | AuthenticationLogoutManualMessage\n | AuthenticationLogoutAutoMessage\n | AuthenticationLogoutDifferentDeviceMessage\n\nexport interface AuditEvent {\n message: AuditMessage\n}\n\nexport interface AuditMetaBase {\n messageId: string\n recordCreatedAt: Date\n}\n\nexport interface AuditInputMeta extends AuditMetaBase {\n id: string\n}\n\nexport type AuditRecordInput = AuditMessage & AuditMetaBase\n\nexport type AuditRecord = AuditMessage & AuditInputMeta\n\nexport interface MessageBody {\n Message: string\n}\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"file":"types.js","names":[],"sources":["../../../../src/form/form-audit/types.ts"],"sourcesContent":["import {\n type AuditEventMessageCategory,\n type AuditEventMessageSchemaVersion,\n type AuditEventMessageSource,\n type AuditEventMessageType,\n type FormDefinitionRequestType\n} from '~/src/form/form-audit/enums.js'\nimport { type FormMetadataContact } from '~/src/form/form-metadata/types.js'\n\nexport interface FormMessageDataBase {\n formId: string\n slug: string\n payload?: unknown\n}\n\nexport interface ChangesMessageData<T> {\n previous: T\n new: T\n}\n\nexport interface FormCreatedMessageData extends FormMessageDataBase {\n title: string\n organisation: string\n teamName: string\n teamEmail: string\n}\n\nexport interface FormTitleChanges {\n title: string\n}\n\nexport interface FormOrganisationChanges {\n organisation: string\n}\n\nexport interface FormTeamNameChanges {\n teamName: string\n}\n\nexport interface FormTeamEmailChanges {\n teamEmail: string\n}\n\nexport interface FormSupportContactChanges {\n contact?: FormMetadataContact\n}\n\nexport interface FormSupportPhoneChanges {\n phone?: string\n}\n\nexport interface FormSupportEmailChanges {\n address?: string\n responseTime?: string\n}\n\nexport interface FormSupportOnlineChanges {\n url?: string\n text?: string\n}\n\nexport interface FormPrivacyNoticeChanges {\n privacyNoticeUrl?: string\n}\n\nexport interface FormNotificationEmailChanges {\n notificationEmail?: string\n}\n\nexport interface FormSubmissionGuidanceChanges {\n submissionGuidance?: string\n}\n\nexport interface FormUploadedChanges {\n value: string\n}\n\nexport interface FormTitleUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTitleChanges>\n}\n\nexport interface FormOrganisationUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormOrganisationChanges>\n}\n\nexport interface FormTeamNameUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTeamNameChanges>\n}\n\nexport interface FormTeamEmailUpdatedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormTeamEmailChanges>\n}\n\nexport interface FormSupportContactUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportContactChanges>\n}\n\nexport interface FormSupportPhoneUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportPhoneChanges>\n}\n\nexport interface FormSupportEmailUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportEmailChanges>\n}\n\nexport interface FormSupportOnlineUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSupportOnlineChanges>\n}\n\nexport interface FormPrivacyNoticeUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormPrivacyNoticeChanges>\n}\n\nexport interface FormNotificationEmailUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormNotificationEmailChanges>\n}\n\nexport interface FormSubmissionGuidanceUpdatedMessageData\n extends FormMessageDataBase {\n changes: ChangesMessageData<FormSubmissionGuidanceChanges>\n}\n\nexport interface FormUploadedMessageData extends FormMessageDataBase {\n changes: ChangesMessageData<FormUploadedChanges>\n}\n\nexport interface FormDefinitionS3Meta {\n fileId: string\n filename: string\n s3Key: string\n}\n\nexport interface FormUpdatedMessageData extends FormMessageDataBase {\n requestType: FormDefinitionRequestType\n s3Meta?: FormDefinitionS3Meta\n}\n\nexport type FormMessageChangesData =\n | FormTitleUpdatedMessageData\n | FormOrganisationUpdatedMessageData\n | FormTeamNameUpdatedMessageData\n | FormTeamEmailUpdatedMessageData\n | FormSupportContactUpdatedMessageData\n | FormSupportPhoneUpdatedMessageData\n | FormSupportEmailUpdatedMessageData\n | FormSupportOnlineUpdatedMessageData\n | FormPrivacyNoticeUpdatedMessageData\n | FormNotificationEmailUpdatedMessageData\n | FormSubmissionGuidanceUpdatedMessageData\n | FormUploadedMessageData\n\nexport type FormMessageActivitiesData =\n | FormCreatedMessageData\n | FormMessageDataBase\n\nexport interface EntitlementMessageData {\n userId: string\n displayName: string\n email: string\n roles: string[]\n}\n\nexport interface AuthenticationMessageData {\n userId: string\n displayName: string\n}\n\nexport interface AuditUser {\n id: string\n displayName: string\n}\n\nexport type MessageData =\n | FormMessageChangesData\n | FormMessageActivitiesData\n | FormUpdatedMessageData\n | EntitlementMessageData\n | AuthenticationMessageData\n\nexport interface MessageBase {\n schemaVersion: AuditEventMessageSchemaVersion\n category: AuditEventMessageCategory\n source: AuditEventMessageSource\n type: AuditEventMessageType\n entityId: string\n traceId?: string\n createdAt: Date\n createdBy: AuditUser\n data?: MessageData\n messageCreatedAt: Date\n}\n\nexport interface ManagerMessageBase extends MessageBase {\n source: AuditEventMessageSource.FORMS_MANAGER\n}\nexport interface DesignerMessageBase extends MessageBase {\n source: AuditEventMessageSource.FORMS_DESIGNER\n}\n\nexport interface EntitlementMessageBase extends MessageBase {\n source: AuditEventMessageSource.ENTITLEMENT\n}\n\nexport interface AuthenticationMessageBase extends MessageBase {\n source: AuditEventMessageSource.AUTHENTICATION\n}\n\nexport interface FormCreatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_CREATED\n data: FormCreatedMessageData\n}\n\nexport interface FormTitleUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TITLE_UPDATED\n data: FormTitleUpdatedMessageData\n}\n\nexport interface FormOrganisationUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_ORGANISATION_UPDATED\n data: FormOrganisationUpdatedMessageData\n}\n\nexport interface FormTeamNameUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TEAM_NAME_UPDATED\n data: FormTeamNameUpdatedMessageData\n}\n\nexport interface FormTeamEmailUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_TEAM_EMAIL_UPDATED\n data: FormTeamEmailUpdatedMessageData\n}\n\nexport interface FormSupportContactUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_CONTACT_UPDATED\n data: FormSupportContactUpdatedMessageData\n}\n\nexport interface FormSupportPhoneUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_PHONE_UPDATED\n data: FormSupportPhoneUpdatedMessageData\n}\n\nexport interface FormSupportEmailUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_EMAIL_UPDATED\n data: FormSupportEmailUpdatedMessageData\n}\n\nexport interface FormSupportOnlineUpdatedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUPPORT_ONLINE_UPDATED\n data: FormSupportOnlineUpdatedMessageData\n}\n\nexport interface FormPrivacyNoticeUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_PRIVACY_NOTICE_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormPrivacyNoticeUpdatedMessageData\n}\n\nexport interface FormNotificationEmailUpdatedMessage\n extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_NOTIFICATION_EMAIL_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormNotificationEmailUpdatedMessageData\n}\n\nexport interface FormSubmissionGuidanceUpdatedMessage\n extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_SUBMISSION_GUIDANCE_UPDATED\n source: AuditEventMessageSource.FORMS_MANAGER\n data: FormSubmissionGuidanceUpdatedMessageData\n}\n\nexport interface FormUploadedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_JSON_UPLOADED\n data: FormUploadedMessageData\n}\n\nexport interface FormDownloadedMessage extends DesignerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_JSON_DOWNLOADED\n data: FormMessageDataBase\n}\n\nexport interface FormDraftCreatedFromLiveMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_DRAFT_CREATED_FROM_LIVE\n}\n\nexport interface FormLiveCreatedFromDraftMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_LIVE_CREATED_FROM_DRAFT\n}\n\nexport interface FormDraftDeletedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_DRAFT_DELETED\n}\n\nexport interface FormMigratedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_MIGRATED\n}\n\nexport interface FormUpdatedMessage extends ManagerMessageBase {\n category: AuditEventMessageCategory.FORM\n type: AuditEventMessageType.FORM_UPDATED\n data: FormUpdatedMessageData\n}\n\nexport interface EntitlementCreatedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_CREATED\n data: EntitlementMessageData\n}\n\nexport interface EntitlementUpdatedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_UPDATED\n data: EntitlementMessageData\n}\n\nexport interface EntitlementDeletedMessage extends EntitlementMessageBase {\n category: AuditEventMessageCategory.ENTITLEMENT\n type: AuditEventMessageType.ENTITLEMENT_DELETED\n data: EntitlementMessageData\n}\n\nexport interface AuthenticationLoginMessage extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGIN\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutManualMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_MANUAL\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutAutoMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_AUTO\n data: AuthenticationMessageData\n}\n\nexport interface AuthenticationLogoutDifferentDeviceMessage\n extends AuthenticationMessageBase {\n category: AuditEventMessageCategory.AUTHENTICATION\n type: AuditEventMessageType.AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE\n data: AuthenticationMessageData\n}\n\nexport type AuditMessage =\n | FormCreatedMessage\n | FormTitleUpdatedMessage\n | FormOrganisationUpdatedMessage\n | FormTeamNameUpdatedMessage\n | FormTeamEmailUpdatedMessage\n | FormSupportContactUpdatedMessage\n | FormSupportPhoneUpdatedMessage\n | FormSupportEmailUpdatedMessage\n | FormSupportOnlineUpdatedMessage\n | FormPrivacyNoticeUpdatedMessage\n | FormNotificationEmailUpdatedMessage\n | FormSubmissionGuidanceUpdatedMessage\n | FormUploadedMessage\n | FormDownloadedMessage\n | FormDraftCreatedFromLiveMessage\n | FormLiveCreatedFromDraftMessage\n | FormDraftDeletedMessage\n | FormMigratedMessage\n | FormUpdatedMessage\n | EntitlementCreatedMessage\n | EntitlementUpdatedMessage\n | EntitlementDeletedMessage\n | AuthenticationLoginMessage\n | AuthenticationLogoutManualMessage\n | AuthenticationLogoutAutoMessage\n | AuthenticationLogoutDifferentDeviceMessage\n\nexport interface AuditEvent {\n message: AuditMessage\n}\n\nexport interface AuditMetaBase {\n messageId: string\n recordCreatedAt: Date\n}\n\nexport interface AuditInputMeta extends AuditMetaBase {\n id: string\n}\n\nexport type AuditRecordInput = AuditMessage & AuditMetaBase\n\nexport type AuditRecord = AuditMessage & AuditInputMeta\n\nexport interface MessageBody {\n Message: string\n}\n"],"mappings":"","ignoreList":[]}
@@ -0,0 +1,23 @@
1
+ export let SecurityQuestionsEnum = /*#__PURE__*/function (SecurityQuestionsEnum) {
2
+ SecurityQuestionsEnum["MemorablePlace"] = "memorable-place";
3
+ SecurityQuestionsEnum["CharacterName"] = "character-name";
4
+ SecurityQuestionsEnum["AudioRecommendation"] = "audio-recommendation";
5
+ return SecurityQuestionsEnum;
6
+ }({});
7
+ export let SubmissionEventMessageSchemaVersion = /*#__PURE__*/function (SubmissionEventMessageSchemaVersion) {
8
+ SubmissionEventMessageSchemaVersion[SubmissionEventMessageSchemaVersion["V1"] = 1] = "V1";
9
+ return SubmissionEventMessageSchemaVersion;
10
+ }({});
11
+ export let SubmissionEventMessageCategory = /*#__PURE__*/function (SubmissionEventMessageCategory) {
12
+ SubmissionEventMessageCategory["RUNNER"] = "RUNNER";
13
+ return SubmissionEventMessageCategory;
14
+ }({});
15
+ export let SubmissionEventMessageSource = /*#__PURE__*/function (SubmissionEventMessageSource) {
16
+ SubmissionEventMessageSource["FORMS_RUNNER"] = "FORMS_RUNNER";
17
+ return SubmissionEventMessageSource;
18
+ }({});
19
+ export let SubmissionEventMessageType = /*#__PURE__*/function (SubmissionEventMessageType) {
20
+ SubmissionEventMessageType["RUNNER_SAVE_AND_EXIT"] = "RUNNER_SAVE_AND_EXIT";
21
+ return SubmissionEventMessageType;
22
+ }({});
23
+ //# sourceMappingURL=enums.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"enums.js","names":["SecurityQuestionsEnum","SubmissionEventMessageSchemaVersion","SubmissionEventMessageCategory","SubmissionEventMessageSource","SubmissionEventMessageType"],"sources":["../../../../src/form/form-submission/enums.ts"],"sourcesContent":["export enum SecurityQuestionsEnum {\n MemorablePlace = 'memorable-place',\n CharacterName = 'character-name',\n AudioRecommendation = 'audio-recommendation'\n}\n\nexport enum SubmissionEventMessageSchemaVersion {\n V1 = 1\n}\n\nexport enum SubmissionEventMessageCategory {\n RUNNER = 'RUNNER'\n}\n\nexport enum SubmissionEventMessageSource {\n FORMS_RUNNER = 'FORMS_RUNNER'\n}\n\nexport enum SubmissionEventMessageType {\n RUNNER_SAVE_AND_EXIT = 'RUNNER_SAVE_AND_EXIT'\n}\n"],"mappings":"AAAA,WAAYA,qBAAqB,0BAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAArBA,qBAAqB;EAAA,OAArBA,qBAAqB;AAAA;AAMjC,WAAYC,mCAAmC,0BAAnCA,mCAAmC;EAAnCA,mCAAmC,CAAnCA,mCAAmC;EAAA,OAAnCA,mCAAmC;AAAA;AAI/C,WAAYC,8BAA8B,0BAA9BA,8BAA8B;EAA9BA,8BAA8B;EAAA,OAA9BA,8BAA8B;AAAA;AAI1C,WAAYC,4BAA4B,0BAA5BA,4BAA4B;EAA5BA,4BAA4B;EAAA,OAA5BA,4BAA4B;AAAA;AAIxC,WAAYC,0BAA0B,0BAA1BA,0BAA0B;EAA1BA,0BAA0B;EAAA,OAA1BA,0BAA0B;AAAA","ignoreList":[]}
@@ -1,4 +1,5 @@
1
1
  import Joi from 'joi';
2
+ import { SubmissionEventMessageCategory, SubmissionEventMessageSchemaVersion, SubmissionEventMessageSource, SubmissionEventMessageType } from "./enums.js";
2
3
  /**
3
4
  * Joi schema for `SubmitRecord` interface
4
5
  * @see {@link SubmitRecord}
@@ -29,4 +30,24 @@ export const formSubmitPayloadSchema = Joi.object().keys({
29
30
  main: Joi.array().items(formSubmitRecordSchema).required().description('Main (non-repeating) field values from the form'),
30
31
  repeaters: Joi.array().items(formSubmitRecordsetSchema).required().description('Repeatable section values from the form')
31
32
  }).required().description('Complete form submission payload structure with all form data');
33
+ export const saveAndExitMessageData = Joi.object().keys({
34
+ formId: Joi.string().required(),
35
+ email: Joi.string().required(),
36
+ security: {
37
+ question: Joi.string().required(),
38
+ answer: Joi.string().required()
39
+ },
40
+ state: Joi.object().required()
41
+ });
42
+ export const submissionMessageSchema = Joi.object().keys({
43
+ schemaVersion: Joi.string().valid(...Object.values(SubmissionEventMessageSchemaVersion)).required().description('The version of the SubmissionMessage - bumped with breaking changes'),
44
+ category: Joi.string().valid(...Object.values(SubmissionEventMessageCategory)).required().description('The message category - what does the entityId represent?'),
45
+ source: Joi.string().valid(...Object.values(SubmissionEventMessageSource)).required().description('Source of the message - which service?'),
46
+ type: Joi.string().valid(...Object.values(SubmissionEventMessageType)).description('Event type'),
47
+ entityId: Joi.string().required().description('The id of the entity the category relates to'),
48
+ traceId: Joi.string().optional().description('Trace id of the event - to link events across multiple services'),
49
+ createdAt: Joi.date().required().description('The ISO timestamp where the action took place - should be the same as updated_at field in DB'),
50
+ messageCreatedAt: Joi.date().required().description('ISO timestamp when the message was published'),
51
+ data: saveAndExitMessageData
52
+ });
32
53
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["Joi","formSubmitRecordSchema","object","name","string","required","description","title","value","allow","formSubmitRecordsetSchema","array","items","formSubmitPayloadSchema","keys","retrievalKey","sessionId","main","repeaters"],"sources":["../../../../src/form/form-submission/index.ts"],"sourcesContent":["import Joi from 'joi'\n\nimport {\n type SubmitPayload,\n type SubmitRecord,\n type SubmitRecordset\n} from '~/src/form/form-submission/types.js'\n\n/**\n * Joi schema for `SubmitRecord` interface\n * @see {@link SubmitRecord}\n */\nexport const formSubmitRecordSchema = Joi.object<SubmitRecord>({\n name: Joi.string()\n .required()\n .description('Field identifier matching the component name'),\n title: Joi.string()\n .required()\n .description('Human-readable label for the field'),\n value: Joi.string()\n .required()\n .allow('')\n .description('User-submitted value for the field, may be empty')\n}).description('Individual field value in a form submission')\n\n/**\n * Joi schema for `SubmitRecordset` interface\n * @see {@link SubmitRecordset}\n */\nexport const formSubmitRecordsetSchema = Joi.object<SubmitRecordset>({\n name: Joi.string()\n .required()\n .description('Identifier for the repeatable section'),\n title: Joi.string()\n .required()\n .description('Human-readable title for the repeatable section'),\n value: Joi.array<SubmitRecord[]>()\n .items(Joi.array<SubmitRecord>().items(formSubmitRecordSchema).required())\n .required()\n .description(\n 'Array of record arrays, each representing a repeated instance'\n )\n}).description('Collection of repeated field values from a repeatable section')\n\n/**\n * Joi schema for `SubmitPayload` interface\n * @see {@link SubmitPayload}\n */\nexport const formSubmitPayloadSchema = Joi.object<SubmitPayload>()\n .keys({\n retrievalKey: Joi.string()\n .required()\n .description('Unique key to retrieve this submission later'),\n sessionId: Joi.string()\n .required()\n .description('User session identifier for tracking and security'),\n main: Joi.array<SubmitRecord>()\n .items(formSubmitRecordSchema)\n .required()\n .description('Main (non-repeating) field values from the form'),\n repeaters: Joi.array<SubmitRecordset>()\n .items(formSubmitRecordsetSchema)\n .required()\n .description('Repeatable section values from the form')\n })\n .required()\n .description('Complete form submission payload structure with all form data')\n"],"mappings":"AAAA,OAAOA,GAAG,MAAM,KAAK;AAQrB;AACA;AACA;AACA;AACA,OAAO,MAAMC,sBAAsB,GAAGD,GAAG,CAACE,MAAM,CAAe;EAC7DC,IAAI,EAAEH,GAAG,CAACI,MAAM,CAAC,CAAC,CACfC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,8CAA8C,CAAC;EAC9DC,KAAK,EAAEP,GAAG,CAACI,MAAM,CAAC,CAAC,CAChBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,oCAAoC,CAAC;EACpDE,KAAK,EAAER,GAAG,CAACI,MAAM,CAAC,CAAC,CAChBC,QAAQ,CAAC,CAAC,CACVI,KAAK,CAAC,EAAE,CAAC,CACTH,WAAW,CAAC,kDAAkD;AACnE,CAAC,CAAC,CAACA,WAAW,CAAC,6CAA6C,CAAC;;AAE7D;AACA;AACA;AACA;AACA,OAAO,MAAMI,yBAAyB,GAAGV,GAAG,CAACE,MAAM,CAAkB;EACnEC,IAAI,EAAEH,GAAG,CAACI,MAAM,CAAC,CAAC,CACfC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,uCAAuC,CAAC;EACvDC,KAAK,EAAEP,GAAG,CAACI,MAAM,CAAC,CAAC,CAChBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,iDAAiD,CAAC;EACjEE,KAAK,EAAER,GAAG,CAACW,KAAK,CAAiB,CAAC,CAC/BC,KAAK,CAACZ,GAAG,CAACW,KAAK,CAAe,CAAC,CAACC,KAAK,CAACX,sBAAsB,CAAC,CAACI,QAAQ,CAAC,CAAC,CAAC,CACzEA,QAAQ,CAAC,CAAC,CACVC,WAAW,CACV,+DACF;AACJ,CAAC,CAAC,CAACA,WAAW,CAAC,+DAA+D,CAAC;;AAE/E;AACA;AACA;AACA;AACA,OAAO,MAAMO,uBAAuB,GAAGb,GAAG,CAACE,MAAM,CAAgB,CAAC,CAC/DY,IAAI,CAAC;EACJC,YAAY,EAAEf,GAAG,CAACI,MAAM,CAAC,CAAC,CACvBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,8CAA8C,CAAC;EAC9DU,SAAS,EAAEhB,GAAG,CAACI,MAAM,CAAC,CAAC,CACpBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,mDAAmD,CAAC;EACnEW,IAAI,EAAEjB,GAAG,CAACW,KAAK,CAAe,CAAC,CAC5BC,KAAK,CAACX,sBAAsB,CAAC,CAC7BI,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,iDAAiD,CAAC;EACjEY,SAAS,EAAElB,GAAG,CAACW,KAAK,CAAkB,CAAC,CACpCC,KAAK,CAACF,yBAAyB,CAAC,CAChCL,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,yCAAyC;AAC1D,CAAC,CAAC,CACDD,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,+DAA+D,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":["Joi","SubmissionEventMessageCategory","SubmissionEventMessageSchemaVersion","SubmissionEventMessageSource","SubmissionEventMessageType","formSubmitRecordSchema","object","name","string","required","description","title","value","allow","formSubmitRecordsetSchema","array","items","formSubmitPayloadSchema","keys","retrievalKey","sessionId","main","repeaters","saveAndExitMessageData","formId","email","security","question","answer","state","submissionMessageSchema","schemaVersion","valid","Object","values","category","source","type","entityId","traceId","optional","createdAt","date","messageCreatedAt","data"],"sources":["../../../../src/form/form-submission/index.ts"],"sourcesContent":["import Joi from 'joi'\n\nimport {\n SubmissionEventMessageCategory,\n SubmissionEventMessageSchemaVersion,\n SubmissionEventMessageSource,\n SubmissionEventMessageType\n} from '~/src/form/form-submission/enums.js'\nimport {\n type SaveAndExitMessageData,\n type SubmissionMessage,\n type SubmitPayload,\n type SubmitRecord,\n type SubmitRecordset\n} from '~/src/form/form-submission/types.js'\n\n/**\n * Joi schema for `SubmitRecord` interface\n * @see {@link SubmitRecord}\n */\nexport const formSubmitRecordSchema = Joi.object<SubmitRecord>({\n name: Joi.string()\n .required()\n .description('Field identifier matching the component name'),\n title: Joi.string()\n .required()\n .description('Human-readable label for the field'),\n value: Joi.string()\n .required()\n .allow('')\n .description('User-submitted value for the field, may be empty')\n}).description('Individual field value in a form submission')\n\n/**\n * Joi schema for `SubmitRecordset` interface\n * @see {@link SubmitRecordset}\n */\nexport const formSubmitRecordsetSchema = Joi.object<SubmitRecordset>({\n name: Joi.string()\n .required()\n .description('Identifier for the repeatable section'),\n title: Joi.string()\n .required()\n .description('Human-readable title for the repeatable section'),\n value: Joi.array<SubmitRecord[]>()\n .items(Joi.array<SubmitRecord>().items(formSubmitRecordSchema).required())\n .required()\n .description(\n 'Array of record arrays, each representing a repeated instance'\n )\n}).description('Collection of repeated field values from a repeatable section')\n\n/**\n * Joi schema for `SubmitPayload` interface\n * @see {@link SubmitPayload}\n */\nexport const formSubmitPayloadSchema = Joi.object<SubmitPayload>()\n .keys({\n retrievalKey: Joi.string()\n .required()\n .description('Unique key to retrieve this submission later'),\n sessionId: Joi.string()\n .required()\n .description('User session identifier for tracking and security'),\n main: Joi.array<SubmitRecord>()\n .items(formSubmitRecordSchema)\n .required()\n .description('Main (non-repeating) field values from the form'),\n repeaters: Joi.array<SubmitRecordset>()\n .items(formSubmitRecordsetSchema)\n .required()\n .description('Repeatable section values from the form')\n })\n .required()\n .description('Complete form submission payload structure with all form data')\n\nexport const saveAndExitMessageData = Joi.object<SaveAndExitMessageData>().keys(\n {\n formId: Joi.string().required(),\n email: Joi.string().required(),\n security: {\n question: Joi.string().required(),\n answer: Joi.string().required()\n },\n state: Joi.object().required()\n }\n)\n\nexport const submissionMessageSchema = Joi.object<SubmissionMessage>().keys({\n schemaVersion: Joi.string()\n .valid(...Object.values(SubmissionEventMessageSchemaVersion))\n .required()\n .description(\n 'The version of the SubmissionMessage - bumped with breaking changes'\n ),\n category: Joi.string()\n .valid(...Object.values(SubmissionEventMessageCategory))\n .required()\n .description('The message category - what does the entityId represent?'),\n source: Joi.string()\n .valid(...Object.values(SubmissionEventMessageSource))\n .required()\n .description('Source of the message - which service?'),\n type: Joi.string()\n .valid(...Object.values(SubmissionEventMessageType))\n .description('Event type'),\n entityId: Joi.string()\n .required()\n .description('The id of the entity the category relates to'),\n traceId: Joi.string()\n .optional()\n .description(\n 'Trace id of the event - to link events across multiple services'\n ),\n createdAt: Joi.date()\n .required()\n .description(\n 'The ISO timestamp where the action took place - should be the same as updated_at field in DB'\n ),\n messageCreatedAt: Joi.date()\n .required()\n .description('ISO timestamp when the message was published'),\n data: saveAndExitMessageData\n})\n"],"mappings":"AAAA,OAAOA,GAAG,MAAM,KAAK;AAErB,SACEC,8BAA8B,EAC9BC,mCAAmC,EACnCC,4BAA4B,EAC5BC,0BAA0B;AAU5B;AACA;AACA;AACA;AACA,OAAO,MAAMC,sBAAsB,GAAGL,GAAG,CAACM,MAAM,CAAe;EAC7DC,IAAI,EAAEP,GAAG,CAACQ,MAAM,CAAC,CAAC,CACfC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,8CAA8C,CAAC;EAC9DC,KAAK,EAAEX,GAAG,CAACQ,MAAM,CAAC,CAAC,CAChBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,oCA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,GAAG,CAACQ,MAAM,CAAC,CAAC,CACjBwB,KAAK,CAAC,GAAGC,MAAM,CAACC,MAAM,CAAC/B,4BAA4B,CAAC,CAAC,CACrDM,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,wCAAwC,CAAC;EACxD2B,IAAI,EAAErC,GAAG,CAACQ,MAAM,CAAC,CAAC,CACfwB,KAAK,CAAC,GAAGC,MAAM,CAACC,MAAM,CAAC9B,0BAA0B,CAAC,CAAC,CACnDM,WAAW,CAAC,YAAY,CAAC;EAC5B4B,QAAQ,EAAEtC,GAAG,CAACQ,MAAM,CAAC,CAAC,CACnBC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,8CAA8C,CAAC;EAC9D6B,OAAO,EAAEvC,GAAG,CAACQ,MAAM,CAAC,CAAC,CAClBgC,QAAQ,CAAC,CAAC,CACV9B,WAAW,CACV,iEACF,CAAC;EACH+B,SAAS,EAAEzC,GAAG,CAAC0C,IAAI,CAAC,CAAC,CAClBjC,QAAQ,CAAC,CAAC,CACVC,WAAW,CACV,8FACF,CAAC;EACHiC,gBAAgB,EAAE3C,GAAG,CAAC0C,IAAI,CAAC,CAAC,CACzBjC,QAAQ,CAAC,CAAC,CACVC,WAAW,CAAC,8CAA8C,CAAC;EAC9DkC,IAAI,EAAErB;AACR,CAAC,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"types.js","names":[],"sources":["../../../../src/form/form-submission/types.ts"],"sourcesContent":["import {\n formSubmitPayloadSchema,\n formSubmitRecordSchema,\n formSubmitRecordsetSchema\n} from '~/src/form/form-submission/index.js'\n\n/**\n * Interface for an individual submit record\n * @see {@link formSubmitRecordSchema}\n */\nexport interface SubmitRecord {\n /**\n * The field name\n */\n name: string\n\n /**\n * The field title\n */\n title: string\n\n /**\n * The field display value\n */\n value: string\n}\n\n/**\n * Interface for an individual submit recordset (e.g. a repeater question set)\n * @see {@link formSubmitRecordsetSchema}\n */\nexport interface SubmitRecordset {\n /**\n * The name of the recordset\n */\n name: string\n\n /**\n * The title of the recordset\n */\n title: string\n\n /**\n * The record items\n */\n value: SubmitRecord[][]\n}\n\n/**\n * Interface for the submission-api `/submit` payload\n * @see {@link formSubmitPayloadSchema}\n */\nexport interface SubmitPayload {\n /**\n * The retrieval key for files created in the submission\n */\n retrievalKey: string\n\n /**\n * The id of the user session\n */\n sessionId: string\n\n /**\n * The main form anwsers\n */\n main: SubmitRecord[]\n\n /**\n * The repeaters form answers\n */\n repeaters: SubmitRecordset[]\n}\n\n/**\n * Interface for the submission-api `/submit` response payload\n */\nexport interface SubmitResponsePayload {\n message: string\n result: {\n files: {\n main: string\n repeaters: Record<string, string>\n }\n }\n}\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"file":"types.js","names":[],"sources":["../../../../src/form/form-submission/types.ts"],"sourcesContent":["import {\n type SubmissionEventMessageCategory,\n type SubmissionEventMessageSchemaVersion,\n type SubmissionEventMessageSource,\n type SubmissionEventMessageType\n} from '~/src/form/form-submission/enums.js'\nimport {\n formSubmitPayloadSchema,\n formSubmitRecordSchema,\n formSubmitRecordsetSchema\n} from '~/src/form/form-submission/index.js'\n\n/**\n * Interface for an individual submit record\n * @see {@link formSubmitRecordSchema}\n */\nexport interface SubmitRecord {\n /**\n * The field name\n */\n name: string\n\n /**\n * The field title\n */\n title: string\n\n /**\n * The field display value\n */\n value: string\n}\n\n/**\n * Interface for an individual submit recordset (e.g. a repeater question set)\n * @see {@link formSubmitRecordsetSchema}\n */\nexport interface SubmitRecordset {\n /**\n * The name of the recordset\n */\n name: string\n\n /**\n * The title of the recordset\n */\n title: string\n\n /**\n * The record items\n */\n value: SubmitRecord[][]\n}\n\n/**\n * Interface for the submission-api `/submit` payload\n * @see {@link formSubmitPayloadSchema}\n */\nexport interface SubmitPayload {\n /**\n * The retrieval key for files created in the submission\n */\n retrievalKey: string\n\n /**\n * The id of the user session\n */\n sessionId: string\n\n /**\n * The main form anwsers\n */\n main: SubmitRecord[]\n\n /**\n * The repeaters form answers\n */\n repeaters: SubmitRecordset[]\n}\n\n/**\n * Interface for the submission-api `/submit` response payload\n */\nexport interface SubmitResponsePayload {\n message: string\n result: {\n files: {\n main: string\n repeaters: Record<string, string>\n }\n }\n}\n\nexport interface SaveAndExitMessageData {\n formId: string\n email: string\n security: {\n question: string\n answer: string\n }\n state: object\n}\n\nexport type SubmissionMessageData = SaveAndExitMessageData\n\nexport interface SubmissionMessage {\n schemaVersion: SubmissionEventMessageSchemaVersion\n category: SubmissionEventMessageCategory\n source: SubmissionEventMessageSource\n type: SubmissionEventMessageType\n entityId: string\n traceId?: string\n createdAt: Date\n messageCreatedAt: Date\n data: SubmissionMessageData\n}\n\nexport interface SaveAndExitMessage extends SubmissionMessage {\n category: SubmissionEventMessageCategory.RUNNER\n type: SubmissionEventMessageType.RUNNER_SAVE_AND_EXIT\n}\n\nexport type RunnerMessage = SaveAndExitMessage\n"],"mappings":"","ignoreList":[]}
@@ -10,6 +10,7 @@ export * from "./form/form-definition/index.js";
10
10
  export * from "./form/form-definition/types.js";
11
11
  export * from "./form/form-metadata/index.js";
12
12
  export * from "./form/form-submission/index.js";
13
+ export * from "./form/form-submission/enums.js";
13
14
  export * from "./form/utils/index.js";
14
15
  export * from "./form/form-editor/index.js";
15
16
  export * from "./form/form-editor/preview/index.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/index.ts"],"sourcesContent":["export * from '~/src/common/enums.js'\nexport * from '~/src/common/random-id.js'\nexport * from '~/src/common/schema.js'\nexport * from '~/src/common/pagination/index.js'\nexport * from '~/src/common/search/index.js'\nexport * from '~/src/common/sorting/index.js'\nexport * from '~/src/components/index.js'\nexport * from '~/src/conditions/index.js'\nexport * from '~/src/form/form-definition/index.js'\nexport * from '~/src/form/form-definition/types.js'\nexport * from '~/src/form/form-metadata/index.js'\nexport * from '~/src/form/form-submission/index.js'\nexport * from '~/src/form/utils/index.js'\nexport * from '~/src/form/form-editor/index.js'\nexport * from '~/src/form/form-editor/preview/index.js'\nexport * from '~/src/form/form-manager/types.js'\nexport * from '~/src/form/form-manager/errors.js'\nexport * from '~/src/manage/roles.js'\nexport * from '~/src/manage/users.js'\nexport * from '~/src/pages/index.js'\nexport * from '~/src/utils/helpers.js'\nexport * from '~/src/utils/markdown.js'\nexport * from '~/src/form/form-audit/index.js'\nexport * from '~/src/form/form-audit/enums.js'\n\nexport type * from '~/src/common/types.js'\nexport type * from '~/src/common/pagination/types.js'\nexport type * from '~/src/common/search/types.js'\nexport type * from '~/src/common/sorting/types.js'\nexport type * from '~/src/components/types.js'\nexport type * from '~/src/conditions/types.js'\nexport type * from '~/src/form/form-definition/types.js'\nexport type * from '~/src/form/form-metadata/types.js'\nexport type * from '~/src/form/form-submission/types.js'\nexport type * from '~/src/form/form-editor/preview/types.js'\nexport type * from '~/src/form/form-editor/types.js'\nexport type * from '~/src/form/form-editor/macros/types.js'\nexport type * from '~/src/form/form-audit/types.js'\nexport type * from '~/src/manage/types.js'\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/index.ts"],"sourcesContent":["export * from '~/src/common/enums.js'\nexport * from '~/src/common/random-id.js'\nexport * from '~/src/common/schema.js'\nexport * from '~/src/common/pagination/index.js'\nexport * from '~/src/common/search/index.js'\nexport * from '~/src/common/sorting/index.js'\nexport * from '~/src/components/index.js'\nexport * from '~/src/conditions/index.js'\nexport * from '~/src/form/form-definition/index.js'\nexport * from '~/src/form/form-definition/types.js'\nexport * from '~/src/form/form-metadata/index.js'\nexport * from '~/src/form/form-submission/index.js'\nexport * from '~/src/form/form-submission/enums.js'\nexport * from '~/src/form/utils/index.js'\nexport * from '~/src/form/form-editor/index.js'\nexport * from '~/src/form/form-editor/preview/index.js'\nexport * from '~/src/form/form-manager/types.js'\nexport * from '~/src/form/form-manager/errors.js'\nexport * from '~/src/manage/roles.js'\nexport * from '~/src/manage/users.js'\nexport * from '~/src/pages/index.js'\nexport * from '~/src/utils/helpers.js'\nexport * from '~/src/utils/markdown.js'\nexport * from '~/src/form/form-audit/index.js'\nexport * from '~/src/form/form-audit/enums.js'\n\nexport type * from '~/src/common/types.js'\nexport type * from '~/src/common/pagination/types.js'\nexport type * from '~/src/common/search/types.js'\nexport type * from '~/src/common/sorting/types.js'\nexport type * from '~/src/components/types.js'\nexport type * from '~/src/conditions/types.js'\nexport type * from '~/src/form/form-definition/types.js'\nexport type * from '~/src/form/form-metadata/types.js'\nexport type * from '~/src/form/form-submission/types.js'\nexport type * from '~/src/form/form-editor/preview/types.js'\nexport type * from '~/src/form/form-editor/types.js'\nexport type * from '~/src/form/form-editor/macros/types.js'\nexport type * from '~/src/form/form-audit/types.js'\nexport type * from '~/src/manage/types.js'\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
@@ -14,7 +14,6 @@ export declare enum AuditEventMessageSource {
14
14
  }
15
15
  export declare enum AuditEventMessageType {
16
16
  FORM_CREATED = "FORM_CREATED",
17
- FORM_PUBLISHED = "FORM_PUBLISHED",
18
17
  FORM_TITLE_UPDATED = "FORM_TITLE_UPDATED",
19
18
  FORM_ORGANISATION_UPDATED = "FORM_ORGANISATION_UPDATED",
20
19
  FORM_TEAM_NAME_UPDATED = "FORM_TEAM_NAME_UPDATED",
@@ -1 +1 @@
1
- {"version":3,"file":"enums.d.ts","sourceRoot":"","sources":["../../../../src/form/form-audit/enums.ts"],"names":[],"mappings":"AAAA,oBAAY,8BAA8B;IACxC,EAAE,IAAI;CACP;AAED,oBAAY,yBAAyB;IACnC,IAAI,SAAS;IACb,WAAW,gBAAgB;IAC3B,cAAc,mBAAmB;CAClC;AAED,oBAAY,uBAAuB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1C"}
@@ -210,10 +210,7 @@ export interface FormUploadedMessage extends DesignerMessageBase {
210
210
  export interface FormDownloadedMessage extends DesignerMessageBase {
211
211
  category: AuditEventMessageCategory.FORM;
212
212
  type: AuditEventMessageType.FORM_JSON_DOWNLOADED;
213
- }
214
- export interface FormPublishedMessage extends ManagerMessageBase {
215
- category: AuditEventMessageCategory.FORM;
216
- type: AuditEventMessageType.FORM_PUBLISHED;
213
+ data: FormMessageDataBase;
217
214
  }
218
215
  export interface FormDraftCreatedFromLiveMessage extends ManagerMessageBase {
219
216
  category: AuditEventMessageCategory.FORM;
@@ -271,7 +268,7 @@ export interface AuthenticationLogoutDifferentDeviceMessage extends Authenticati
271
268
  type: AuditEventMessageType.AUTHENTICATION_LOGOUT_DIFFERENT_DEVICE;
272
269
  data: AuthenticationMessageData;
273
270
  }
274
- export type AuditMessage = FormCreatedMessage | FormTitleUpdatedMessage | FormOrganisationUpdatedMessage | FormTeamNameUpdatedMessage | FormTeamEmailUpdatedMessage | FormSupportContactUpdatedMessage | FormSupportPhoneUpdatedMessage | FormSupportEmailUpdatedMessage | FormSupportOnlineUpdatedMessage | FormPrivacyNoticeUpdatedMessage | FormNotificationEmailUpdatedMessage | FormSubmissionGuidanceUpdatedMessage | FormUploadedMessage | FormDownloadedMessage | FormPublishedMessage | FormDraftCreatedFromLiveMessage | FormLiveCreatedFromDraftMessage | FormDraftDeletedMessage | FormMigratedMessage | FormUpdatedMessage | EntitlementCreatedMessage | EntitlementUpdatedMessage | EntitlementDeletedMessage | AuthenticationLoginMessage | AuthenticationLogoutManualMessage | AuthenticationLogoutAutoMessage | AuthenticationLogoutDifferentDeviceMessage;
271
+ export type AuditMessage = FormCreatedMessage | FormTitleUpdatedMessage | FormOrganisationUpdatedMessage | FormTeamNameUpdatedMessage | FormTeamEmailUpdatedMessage | FormSupportContactUpdatedMessage | FormSupportPhoneUpdatedMessage | FormSupportEmailUpdatedMessage | FormSupportOnlineUpdatedMessage | FormPrivacyNoticeUpdatedMessage | FormNotificationEmailUpdatedMessage | FormSubmissionGuidanceUpdatedMessage | FormUploadedMessage | FormDownloadedMessage | FormDraftCreatedFromLiveMessage | FormLiveCreatedFromDraftMessage | FormDraftDeletedMessage | FormMigratedMessage | FormUpdatedMessage | EntitlementCreatedMessage | EntitlementUpdatedMessage | EntitlementDeletedMessage | AuthenticationLoginMessage | AuthenticationLogoutManualMessage | AuthenticationLogoutAutoMessage | AuthenticationLogoutDifferentDeviceMessage;
275
272
  export interface AuditEvent {
276
273
  message: AuditMessage;
277
274
  }
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/form/form-audit/types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,yBAAyB,EAC9B,KAAK,8BAA8B,EACnC,KAAK,uBAAuB,EAC5B,KAAK,qBAAqB,EAC1B,KAAK,yBAAyB,EAC/B,MAAM,gCAAgC,CAAA;AACvC,OAAO,EAAE,KAAK,mBAAmB,EAAE,MAAM,mCAAmC,CAAA;AAE5E,MAAM,WAAW,mBAAmB;IAClC,MAAM,EAAE,MAAM,CAAA;IACd,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,kBAAkB,CAAC,CAAC;IACnC,QAAQ,EAAE,CAAC,CAAA;IACX,GAAG,EAAE,CAAC,CAAA;CACP;AAED,MAAM,WAAW,sBAAuB,SAAQ,mBAAmB;IACjE,KAAK,EAAE,MAAM,CAAA;IACb,YAAY,EAAE,MAAM,CAAA;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,SAAS,EAAE,MAAM,CAAA;CAClB;AAED,MAAM,WAAW,gBAAgB;IAC/B,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,WAAW,uBAAuB;IACtC,YAAY,EAAE,MAAM,CAAA;CACrB;AAED,MAAM,WAAW,mBAAmB;IAClC,QAAQ,EAAE,MAAM,CAAA;CACjB;AAED,MAAM,WAAW,oB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ACnD,EAAE,EAAE,MAAM,CAAA;CACX;AAED,MAAM,MAAM,gBAAgB,GAAG,YAAY,GAAG,aAAa,CAAA;AAE3D,MAAM,MAAM,WAAW,GAAG,YAAY,GAAG,cAAc,CAAA;AAEvD,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAA;CAChB"}
@@ -0,0 +1,18 @@
1
+ export declare enum SecurityQuestionsEnum {
2
+ MemorablePlace = "memorable-place",
3
+ CharacterName = "character-name",
4
+ AudioRecommendation = "audio-recommendation"
5
+ }
6
+ export declare enum SubmissionEventMessageSchemaVersion {
7
+ V1 = 1
8
+ }
9
+ export declare enum SubmissionEventMessageCategory {
10
+ RUNNER = "RUNNER"
11
+ }
12
+ export declare enum SubmissionEventMessageSource {
13
+ FORMS_RUNNER = "FORMS_RUNNER"
14
+ }
15
+ export declare enum SubmissionEventMessageType {
16
+ RUNNER_SAVE_AND_EXIT = "RUNNER_SAVE_AND_EXIT"
17
+ }
18
+ //# sourceMappingURL=enums.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"enums.d.ts","sourceRoot":"","sources":["../../../../src/form/form-submission/enums.ts"],"names":[],"mappings":"AAAA,oBAAY,qBAAqB;IAC/B,cAAc,oBAAoB;IAClC,aAAa,mBAAmB;IAChC,mBAAmB,yBAAyB;CAC7C;AAED,oBAAY,mCAAmC;IAC7C,EAAE,IAAI;CACP;AAED,oBAAY,8BAA8B;IACxC,MAAM,WAAW;CAClB;AAED,oBAAY,4BAA4B;IACtC,YAAY,iBAAiB;CAC9B;AAED,oBAAY,0BAA0B;IACpC,oBAAoB,yBAAyB;CAC9C"}
@@ -1,5 +1,5 @@
1
1
  import Joi from 'joi';
2
- import { type SubmitPayload, type SubmitRecord, type SubmitRecordset } from '../../form/form-submission/types.js';
2
+ import { type SaveAndExitMessageData, type SubmissionMessage, type SubmitPayload, type SubmitRecord, type SubmitRecordset } from '../../form/form-submission/types.js';
3
3
  /**
4
4
  * Joi schema for `SubmitRecord` interface
5
5
  * @see {@link SubmitRecord}
@@ -15,4 +15,6 @@ export declare const formSubmitRecordsetSchema: Joi.ObjectSchema<SubmitRecordset
15
15
  * @see {@link SubmitPayload}
16
16
  */
17
17
  export declare const formSubmitPayloadSchema: Joi.ObjectSchema<SubmitPayload>;
18
+ export declare const saveAndExitMessageData: Joi.ObjectSchema<SaveAndExitMessageData>;
19
+ export declare const submissionMessageSchema: Joi.ObjectSchema<SubmissionMessage>;
18
20
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/form/form-submission/index.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,KAAK,CAAA;AAErB,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,eAAe,EACrB,MAAM,qCAAqC,CAAA;AAE5C;;;GAGG;AACH,eAAO,MAAM,sBAAsB,gCAW0B,CAAA;AAE7D;;;GAGG;AACH,eAAO,MAAM,yBAAyB,mCAayC,CAAA;AAE/E;;;GAGG;AACH,eAAO,MAAM,uBAAuB,iCAkB2C,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/form/form-submission/index.ts"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,KAAK,CAAA;AAQrB,OAAO,EACL,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,eAAe,EACrB,MAAM,qCAAqC,CAAA;AAE5C;;;GAGG;AACH,eAAO,MAAM,sBAAsB,gCAW0B,CAAA;AAE7D;;;GAGG;AACH,eAAO,MAAM,yBAAyB,mCAayC,CAAA;AAE/E;;;GAGG;AACH,eAAO,MAAM,uBAAuB,iCAkB2C,CAAA;AAE/E,eAAO,MAAM,sBAAsB,0CAUlC,CAAA;AAED,eAAO,MAAM,uBAAuB,qCAmClC,CAAA"}
@@ -1,3 +1,4 @@
1
+ import { type SubmissionEventMessageCategory, type SubmissionEventMessageSchemaVersion, type SubmissionEventMessageSource, type SubmissionEventMessageType } from '../../form/form-submission/enums.js';
1
2
  /**
2
3
  * Interface for an individual submit record
3
4
  * @see {@link formSubmitRecordSchema}
@@ -68,4 +69,30 @@ export interface SubmitResponsePayload {
68
69
  };
69
70
  };
70
71
  }
72
+ export interface SaveAndExitMessageData {
73
+ formId: string;
74
+ email: string;
75
+ security: {
76
+ question: string;
77
+ answer: string;
78
+ };
79
+ state: object;
80
+ }
81
+ export type SubmissionMessageData = SaveAndExitMessageData;
82
+ export interface SubmissionMessage {
83
+ schemaVersion: SubmissionEventMessageSchemaVersion;
84
+ category: SubmissionEventMessageCategory;
85
+ source: SubmissionEventMessageSource;
86
+ type: SubmissionEventMessageType;
87
+ entityId: string;
88
+ traceId?: string;
89
+ createdAt: Date;
90
+ messageCreatedAt: Date;
91
+ data: SubmissionMessageData;
92
+ }
93
+ export interface SaveAndExitMessage extends SubmissionMessage {
94
+ category: SubmissionEventMessageCategory.RUNNER;
95
+ type: SubmissionEventMessageType.RUNNER_SAVE_AND_EXIT;
96
+ }
97
+ export type RunnerMessage = SaveAndExitMessage;
71
98
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/form/form-submission/types.ts"],"names":[],"mappings":"AAMA;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;IAEb;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;IAEb;;OAEG;IACH,KAAK,EAAE,YAAY,EAAE,EAAE,CAAA;CACxB;AAED;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,YAAY,EAAE,MAAM,CAAA;IAEpB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAA;IAEjB;;OAEG;IACH,IAAI,EAAE,YAAY,EAAE,CAAA;IAEpB;;OAEG;IACH,SAAS,EAAE,eAAe,EAAE,CAAA;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,EAAE;QACN,KAAK,EAAE;YACL,IAAI,EAAE,MAAM,CAAA;YACZ,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;SAClC,CAAA;KACF,CAAA;CACF"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/form/form-submission/types.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,8BAA8B,EACnC,KAAK,mCAAmC,EACxC,KAAK,4BAA4B,EACjC,KAAK,0BAA0B,EAChC,MAAM,qCAAqC,CAAA;AAO5C;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;IAEb;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,KAAK,EAAE,MAAM,CAAA;IAEb;;OAEG;IACH,KAAK,EAAE,YAAY,EAAE,EAAE,CAAA;CACxB;AAED;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,YAAY,EAAE,MAAM,CAAA;IAEpB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAA;IAEjB;;OAEG;IACH,IAAI,EAAE,YAAY,EAAE,CAAA;IAEpB;;OAEG;IACH,SAAS,EAAE,eAAe,EAAE,CAAA;CAC7B;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,OAAO,EAAE,MAAM,CAAA;IACf,MAAM,EAAE;QACN,KAAK,EAAE;YACL,IAAI,EAAE,MAAM,CAAA;YACZ,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;SAClC,CAAA;KACF,CAAA;CACF;AAED,MAAM,WAAW,sBAAsB;IACrC,MAAM,EAAE,MAAM,CAAA;IACd,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE;QACR,QAAQ,EAAE,MAAM,CAAA;QAChB,MAAM,EAAE,MAAM,CAAA;KACf,CAAA;IACD,KAAK,EAAE,MAAM,CAAA;CACd;AAED,MAAM,MAAM,qBAAqB,GAAG,sBAAsB,CAAA;AAE1D,MAAM,WAAW,iBAAiB;IAChC,aAAa,EAAE,mCAAmC,CAAA;IAClD,QAAQ,EAAE,8BAA8B,CAAA;IACxC,MAAM,EAAE,4BAA4B,CAAA;IACpC,IAAI,EAAE,0BAA0B,CAAA;IAChC,QAAQ,EAAE,MAAM,CAAA;IAChB,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,SAAS,EAAE,IAAI,CAAA;IACf,gBAAgB,EAAE,IAAI,CAAA;IACtB,IAAI,EAAE,qBAAqB,CAAA;CAC5B;AAED,MAAM,WAAW,kBAAmB,SAAQ,iBAAiB;IAC3D,QAAQ,EAAE,8BAA8B,CAAC,MAAM,CAAA;IAC/C,IAAI,EAAE,0BAA0B,CAAC,oBAAoB,CAAA;CACtD;AAED,MAAM,MAAM,aAAa,GAAG,kBAAkB,CAAA"}
@@ -10,6 +10,7 @@ export * from './form/form-definition/index.js';
10
10
  export * from './form/form-definition/types.js';
11
11
  export * from './form/form-metadata/index.js';
12
12
  export * from './form/form-submission/index.js';
13
+ export * from './form/form-submission/enums.js';
13
14
  export * from './form/utils/index.js';
14
15
  export * from './form/form-editor/index.js';
15
16
  export * from './form/form-editor/preview/index.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],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;AAChD,cAAc,8BAA8B,CAAA;AAC5C,cAAc,+BAA+B,CAAA;AAC7C,cAAc,2BAA2B,CAAA;AACzC,cAAc,2BAA2B,CAAA;AACzC,cAAc,qCAAqC,CAAA;AACnD,cAAc,qCAAqC,CAAA;AACnD,cAAc,mCAAmC,CAAA;AACjD,cAAc,qCAAqC,CAAA;AACnD,cAAc,qCAAqC,CAAA;AACnD,cAAc,2BAA2B,CAAA;AACzC,cAAc,iCAAiC,CAAA;AAC/C,cAAc,yCAAyC,CAAA;AACvD,cAAc,kCAAkC,CAAA;AAChD,cAAc,mCAAmC,CAAA;AACjD,cAAc,uBAAuB,CAAA;AACrC,cAAc,uBAAuB,CAAA;AACrC,cAAc,sBAAsB,CAAA;AACpC,cAAc,wBAAwB,CAAA;AACtC,cAAc,yBAAyB,CAAA;AACvC,cAAc,gCAAgC,CAAA;AAC9C,cAAc,gCAAgC,CAAA;AAE9C,mBAAmB,uBAAuB,CAAA;AAC1C,mBAAmB,kCAAkC,CAAA;AACrD,mBAAmB,8BAA8B,CAAA;AACjD,mBAAmB,+BAA+B,CAAA;AAClD,mBAAmB,2BAA2B,CAAA;AAC9C,mBAAmB,2BAA2B,CAAA;AAC9C,mBAAmB,qCAAqC,CAAA;AACxD,mBAAmB,mCAAmC,CAAA;AACtD,mBAAmB,qCAAqC,CAAA;AACxD,mBAAmB,yCAAyC,CAAA;AAC5D,mBAAmB,iCAAiC,CAAA;AACpD,mBAAmB,wCAAwC,CAAA;AAC3D,mBAAmB,gCAAgC,CAAA;AACnD,mBAAmB,uBAAuB,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defra/forms-model",
3
- "version": "3.0.540",
3
+ "version": "3.0.542",
4
4
  "description": "A hapi plugin providing the model for Defra forms",
5
5
  "homepage": "https://github.com/DEFRA/forms-designer/tree/main/model#readme",
6
6
  "types": "dist/types/index.d.ts",
@@ -18,7 +18,6 @@ export enum AuditEventMessageSource {
18
18
  export enum AuditEventMessageType {
19
19
  // FORM message types
20
20
  FORM_CREATED = 'FORM_CREATED',
21
- FORM_PUBLISHED = 'FORM_PUBLISHED',
22
21
  FORM_TITLE_UPDATED = 'FORM_TITLE_UPDATED',
23
22
  FORM_ORGANISATION_UPDATED = 'FORM_ORGANISATION_UPDATED',
24
23
  FORM_TEAM_NAME_UPDATED = 'FORM_TEAM_NAME_UPDATED',
@@ -298,11 +298,7 @@ export interface FormUploadedMessage extends DesignerMessageBase {
298
298
  export interface FormDownloadedMessage extends DesignerMessageBase {
299
299
  category: AuditEventMessageCategory.FORM
300
300
  type: AuditEventMessageType.FORM_JSON_DOWNLOADED
301
- }
302
-
303
- export interface FormPublishedMessage extends ManagerMessageBase {
304
- category: AuditEventMessageCategory.FORM
305
- type: AuditEventMessageType.FORM_PUBLISHED
301
+ data: FormMessageDataBase
306
302
  }
307
303
 
308
304
  export interface FormDraftCreatedFromLiveMessage extends ManagerMessageBase {
@@ -391,7 +387,6 @@ export type AuditMessage =
391
387
  | FormSubmissionGuidanceUpdatedMessage
392
388
  | FormUploadedMessage
393
389
  | FormDownloadedMessage
394
- | FormPublishedMessage
395
390
  | FormDraftCreatedFromLiveMessage
396
391
  | FormLiveCreatedFromDraftMessage
397
392
  | FormDraftDeletedMessage
@@ -0,0 +1,21 @@
1
+ export enum SecurityQuestionsEnum {
2
+ MemorablePlace = 'memorable-place',
3
+ CharacterName = 'character-name',
4
+ AudioRecommendation = 'audio-recommendation'
5
+ }
6
+
7
+ export enum SubmissionEventMessageSchemaVersion {
8
+ V1 = 1
9
+ }
10
+
11
+ export enum SubmissionEventMessageCategory {
12
+ RUNNER = 'RUNNER'
13
+ }
14
+
15
+ export enum SubmissionEventMessageSource {
16
+ FORMS_RUNNER = 'FORMS_RUNNER'
17
+ }
18
+
19
+ export enum SubmissionEventMessageType {
20
+ RUNNER_SAVE_AND_EXIT = 'RUNNER_SAVE_AND_EXIT'
21
+ }
@@ -1,6 +1,14 @@
1
1
  import Joi from 'joi'
2
2
 
3
3
  import {
4
+ SubmissionEventMessageCategory,
5
+ SubmissionEventMessageSchemaVersion,
6
+ SubmissionEventMessageSource,
7
+ SubmissionEventMessageType
8
+ } from '~/src/form/form-submission/enums.js'
9
+ import {
10
+ type SaveAndExitMessageData,
11
+ type SubmissionMessage,
4
12
  type SubmitPayload,
5
13
  type SubmitRecord,
6
14
  type SubmitRecordset
@@ -65,3 +73,52 @@ export const formSubmitPayloadSchema = Joi.object<SubmitPayload>()
65
73
  })
66
74
  .required()
67
75
  .description('Complete form submission payload structure with all form data')
76
+
77
+ export const saveAndExitMessageData = Joi.object<SaveAndExitMessageData>().keys(
78
+ {
79
+ formId: Joi.string().required(),
80
+ email: Joi.string().required(),
81
+ security: {
82
+ question: Joi.string().required(),
83
+ answer: Joi.string().required()
84
+ },
85
+ state: Joi.object().required()
86
+ }
87
+ )
88
+
89
+ export const submissionMessageSchema = Joi.object<SubmissionMessage>().keys({
90
+ schemaVersion: Joi.string()
91
+ .valid(...Object.values(SubmissionEventMessageSchemaVersion))
92
+ .required()
93
+ .description(
94
+ 'The version of the SubmissionMessage - bumped with breaking changes'
95
+ ),
96
+ category: Joi.string()
97
+ .valid(...Object.values(SubmissionEventMessageCategory))
98
+ .required()
99
+ .description('The message category - what does the entityId represent?'),
100
+ source: Joi.string()
101
+ .valid(...Object.values(SubmissionEventMessageSource))
102
+ .required()
103
+ .description('Source of the message - which service?'),
104
+ type: Joi.string()
105
+ .valid(...Object.values(SubmissionEventMessageType))
106
+ .description('Event type'),
107
+ entityId: Joi.string()
108
+ .required()
109
+ .description('The id of the entity the category relates to'),
110
+ traceId: Joi.string()
111
+ .optional()
112
+ .description(
113
+ 'Trace id of the event - to link events across multiple services'
114
+ ),
115
+ createdAt: Joi.date()
116
+ .required()
117
+ .description(
118
+ 'The ISO timestamp where the action took place - should be the same as updated_at field in DB'
119
+ ),
120
+ messageCreatedAt: Joi.date()
121
+ .required()
122
+ .description('ISO timestamp when the message was published'),
123
+ data: saveAndExitMessageData
124
+ })
@@ -1,3 +1,9 @@
1
+ import {
2
+ type SubmissionEventMessageCategory,
3
+ type SubmissionEventMessageSchemaVersion,
4
+ type SubmissionEventMessageSource,
5
+ type SubmissionEventMessageType
6
+ } from '~/src/form/form-submission/enums.js'
1
7
  import {
2
8
  formSubmitPayloadSchema,
3
9
  formSubmitRecordSchema,
@@ -84,3 +90,34 @@ export interface SubmitResponsePayload {
84
90
  }
85
91
  }
86
92
  }
93
+
94
+ export interface SaveAndExitMessageData {
95
+ formId: string
96
+ email: string
97
+ security: {
98
+ question: string
99
+ answer: string
100
+ }
101
+ state: object
102
+ }
103
+
104
+ export type SubmissionMessageData = SaveAndExitMessageData
105
+
106
+ export interface SubmissionMessage {
107
+ schemaVersion: SubmissionEventMessageSchemaVersion
108
+ category: SubmissionEventMessageCategory
109
+ source: SubmissionEventMessageSource
110
+ type: SubmissionEventMessageType
111
+ entityId: string
112
+ traceId?: string
113
+ createdAt: Date
114
+ messageCreatedAt: Date
115
+ data: SubmissionMessageData
116
+ }
117
+
118
+ export interface SaveAndExitMessage extends SubmissionMessage {
119
+ category: SubmissionEventMessageCategory.RUNNER
120
+ type: SubmissionEventMessageType.RUNNER_SAVE_AND_EXIT
121
+ }
122
+
123
+ export type RunnerMessage = SaveAndExitMessage
package/src/index.ts CHANGED
@@ -10,6 +10,7 @@ export * from '~/src/form/form-definition/index.js'
10
10
  export * from '~/src/form/form-definition/types.js'
11
11
  export * from '~/src/form/form-metadata/index.js'
12
12
  export * from '~/src/form/form-submission/index.js'
13
+ export * from '~/src/form/form-submission/enums.js'
13
14
  export * from '~/src/form/utils/index.js'
14
15
  export * from '~/src/form/form-editor/index.js'
15
16
  export * from '~/src/form/form-editor/preview/index.js'