@dalmore/api-contracts 1.0.6 → 1.0.7

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.
Files changed (137) hide show
  1. package/dist/contracts/clients/index.d.ts +19 -0
  2. package/index.mjs +4 -1
  3. package/package.json +4 -4
  4. package/src/common/types/account-contact.types.ts +0 -98
  5. package/src/common/types/account-detail.types.ts +0 -27
  6. package/src/common/types/account-integration.types.ts +0 -143
  7. package/src/common/types/account-manager.types.ts +0 -124
  8. package/src/common/types/account.types.ts +0 -296
  9. package/src/common/types/activity.types.ts +0 -274
  10. package/src/common/types/address.spec.ts +0 -203
  11. package/src/common/types/address.types.ts +0 -41
  12. package/src/common/types/aic.types.ts +0 -246
  13. package/src/common/types/aml.types.ts +0 -18
  14. package/src/common/types/api-key-logs.types.ts +0 -66
  15. package/src/common/types/api-keys.types.ts +0 -69
  16. package/src/common/types/asset.types.ts +0 -338
  17. package/src/common/types/auth.types.ts +0 -370
  18. package/src/common/types/batch-jobs.types.ts +0 -151
  19. package/src/common/types/bonus-tier.types.ts +0 -147
  20. package/src/common/types/cart.types.ts +0 -18
  21. package/src/common/types/checklist-items.types.ts +0 -70
  22. package/src/common/types/checklist.types.ts +0 -97
  23. package/src/common/types/common.types.spec.ts +0 -336
  24. package/src/common/types/common.types.ts +0 -1520
  25. package/src/common/types/comply-advantage-api.types.ts +0 -316
  26. package/src/common/types/comply-advantage.types.ts +0 -25
  27. package/src/common/types/contact-us.types.ts +0 -107
  28. package/src/common/types/contract-helpers.ts +0 -205
  29. package/src/common/types/countries.types.ts +0 -375
  30. package/src/common/types/covered-person.types.ts +0 -274
  31. package/src/common/types/dashboard.types.ts +0 -799
  32. package/src/common/types/data-record.types.ts +0 -325
  33. package/src/common/types/data-room.types.ts +0 -242
  34. package/src/common/types/default-theme-config.types.ts +0 -87
  35. package/src/common/types/disbursement-adjustment.types.ts +0 -32
  36. package/src/common/types/disbursement-approval-user.types.ts +0 -100
  37. package/src/common/types/disbursement-review.types.ts +0 -110
  38. package/src/common/types/disbursement-transaction.types.ts +0 -72
  39. package/src/common/types/disbursements.types.ts +0 -310
  40. package/src/common/types/domain-filter.types.ts +0 -55
  41. package/src/common/types/email-theme.types.ts +0 -442
  42. package/src/common/types/entity.types.ts +0 -15
  43. package/src/common/types/error-responses.types.ts +0 -135
  44. package/src/common/types/escrow-account.types.ts +0 -104
  45. package/src/common/types/exchange-api-key.types.ts +0 -121
  46. package/src/common/types/exchange-import.types.ts +0 -36
  47. package/src/common/types/exchange-provider.types.ts +0 -329
  48. package/src/common/types/file.types.ts +0 -461
  49. package/src/common/types/files.types.spec.ts +0 -154
  50. package/src/common/types/health.types.ts +0 -29
  51. package/src/common/types/index.ts +0 -48
  52. package/src/common/types/individuals.types.ts +0 -554
  53. package/src/common/types/investor-account.types.ts +0 -1239
  54. package/src/common/types/investorAccountIdSchema.type.ts +0 -0
  55. package/src/common/types/investors-offering.types.ts +0 -65
  56. package/src/common/types/invite.types.ts +0 -133
  57. package/src/common/types/issuer-bank-account.types.ts +0 -107
  58. package/src/common/types/issuer-offering.types.ts +0 -306
  59. package/src/common/types/issuer-payment-method.types.spec.ts +0 -612
  60. package/src/common/types/issuer-payment-method.types.ts +0 -341
  61. package/src/common/types/issuer.types.ts +0 -312
  62. package/src/common/types/job-item.types.ts +0 -119
  63. package/src/common/types/jobs.types.ts +0 -171
  64. package/src/common/types/kyb.types.ts +0 -53
  65. package/src/common/types/kyc.types.ts +0 -188
  66. package/src/common/types/legal-entity.types.ts +0 -185
  67. package/src/common/types/login-history.types.ts +0 -46
  68. package/src/common/types/mail-template.types.ts +0 -436
  69. package/src/common/types/north-cap-integration.types.ts +0 -190
  70. package/src/common/types/note.types.ts +0 -109
  71. package/src/common/types/notification.types.ts +0 -58
  72. package/src/common/types/notion-api.types.ts +0 -374
  73. package/src/common/types/notion-database.types.ts +0 -125
  74. package/src/common/types/notion-page.types.ts +0 -267
  75. package/src/common/types/offering-reports.types.ts +0 -153
  76. package/src/common/types/offering-submission.types.ts +0 -314
  77. package/src/common/types/offering.types.spec.ts +0 -91
  78. package/src/common/types/offering.types.ts +0 -590
  79. package/src/common/types/page-revision.types.ts +0 -86
  80. package/src/common/types/page.types.ts +0 -436
  81. package/src/common/types/password.type.ts +0 -15
  82. package/src/common/types/payment-methods.types.ts +0 -298
  83. package/src/common/types/phone.spec.ts +0 -76
  84. package/src/common/types/phone.type.ts +0 -27
  85. package/src/common/types/portfolio.types.ts +0 -50
  86. package/src/common/types/privacy-policy-and-tos.types.ts +0 -231
  87. package/src/common/types/queue.types.ts +0 -112
  88. package/src/common/types/registered-reps.types.ts +0 -25
  89. package/src/common/types/rejection-reasons.types.ts +0 -56
  90. package/src/common/types/reminder-config.types.ts +0 -40
  91. package/src/common/types/review.types.ts +0 -133
  92. package/src/common/types/role.types.ts +0 -26
  93. package/src/common/types/secondary-customer.types.ts +0 -66
  94. package/src/common/types/secondary-issuer.types.ts +0 -50
  95. package/src/common/types/secondary-order.types.ts +0 -58
  96. package/src/common/types/secondary-security.types.ts +0 -60
  97. package/src/common/types/secondary-trade.entity.ts +0 -16
  98. package/src/common/types/secondary-trade.types.ts +0 -95
  99. package/src/common/types/secure-request.types.ts +0 -68
  100. package/src/common/types/signer.types.ts +0 -651
  101. package/src/common/types/site-link.types.spec.ts +0 -134
  102. package/src/common/types/site-link.types.ts +0 -166
  103. package/src/common/types/site-settings.types.ts +0 -726
  104. package/src/common/types/site.types.ts +0 -270
  105. package/src/common/types/sms.types.ts +0 -30
  106. package/src/common/types/state-machine.types.ts +0 -177
  107. package/src/common/types/states.types.ts +0 -163
  108. package/src/common/types/subdoc-preview.types.ts +0 -35
  109. package/src/common/types/task.types.ts +0 -258
  110. package/src/common/types/trade-adjustment.type.ts +0 -33
  111. package/src/common/types/trade-line-item.type.ts +0 -132
  112. package/src/common/types/trade.types.ts +0 -929
  113. package/src/common/types/transaction.types.ts +0 -198
  114. package/src/common/types/trusted-contact.types.ts +0 -122
  115. package/src/common/types/typography.types.ts +0 -75
  116. package/src/common/types/user-manual.types.ts +0 -290
  117. package/src/common/types/user-setting.types.ts +0 -133
  118. package/src/common/types/user.types.ts +0 -320
  119. package/src/common/types/webhook.types.ts +0 -588
  120. package/src/common/types/zip.type.ts +0 -36
  121. package/src/contracts/clients/accounts/index.ts +0 -61
  122. package/src/contracts/clients/aic/index.ts +0 -59
  123. package/src/contracts/clients/api-key-logs/index.ts +0 -53
  124. package/src/contracts/clients/api-keys/index.ts +0 -73
  125. package/src/contracts/clients/assets/index.ts +0 -102
  126. package/src/contracts/clients/auth/index.ts +0 -50
  127. package/src/contracts/clients/files/index.ts +0 -166
  128. package/src/contracts/clients/files-public/index.ts +0 -166
  129. package/src/contracts/clients/index.ts +0 -44
  130. package/src/contracts/clients/individuals/index.ts +0 -93
  131. package/src/contracts/clients/investor-accounts/index.ts +0 -93
  132. package/src/contracts/clients/issuers/index.ts +0 -94
  133. package/src/contracts/clients/legal-entities/index.ts +0 -93
  134. package/src/contracts/clients/offerings/index.ts +0 -117
  135. package/src/contracts/clients/secure-requests/index.ts +0 -34
  136. package/src/contracts/clients/sites/index.ts +0 -56
  137. package/src/contracts/clients/trades/index.ts +0 -122
@@ -1,185 +0,0 @@
1
- import { z } from 'zod';
2
- import { IBaseEntity } from './entity.types';
3
- import {
4
- dateSchema,
5
- IPaginationMeta,
6
- KYBStatus,
7
- SanctionsStatus,
8
- SetupStatusType,
9
- } from './common.types';
10
- import { KybZod } from './kyb.types';
11
- import { extendZodWithOpenApi } from '@anatine/zod-openapi';
12
- import { TypeID } from 'typeid-js';
13
- import { AddressSchema } from './address.types';
14
- import { PhoneZodSchema } from './phone.type';
15
- extendZodWithOpenApi(z);
16
-
17
- // importing investorAccountIdSchema directly from './investor-account.types' causes 500 server errors due to circular import
18
- const investorAccountIdSchema = z.string().refine(
19
- (value) => {
20
- try {
21
- const tid = TypeID.fromString(value);
22
- return tid.getType() === 'investor_account';
23
- } catch {
24
- return false;
25
- }
26
- },
27
- {
28
- message:
29
- 'Invalid investor_account ID format. Must be a valid TypeID with "investor_account" prefix.',
30
- },
31
- );
32
-
33
- export const legalEntityIdSchema = z.string().refine(
34
- (value) => {
35
- try {
36
- const tid = TypeID.fromString(value);
37
- return tid.getType() === 'legal_entity';
38
- } catch {
39
- return false;
40
- }
41
- },
42
- {
43
- message:
44
- 'Invalid legal_entity ID format. Must be a valid TypeID with "legal_entity" prefix.',
45
- },
46
- );
47
- export const LegalEntityZod = IBaseEntity.extend({
48
- thirdPartyId: z
49
- .string()
50
- .openapi({ example: 'third_party_legal_entity_123' })
51
- .nullable(),
52
- accountId: z
53
- .string()
54
- .openapi({ example: 'account_01j1xgme5qeqq97gpdztd7e4a6' }),
55
- investorAccountId: z
56
- .string()
57
- .openapi({ example: 'investor_account_01j1xgme5qeqq97gpdztd7e4a7' }),
58
- kybStatus: z
59
- .lazy(() => z.nativeEnum(KYBStatus))
60
- .openapi({ example: 'PENDING' }),
61
- sanctionsStatus: z
62
- .lazy(() => z.nativeEnum(SanctionsStatus))
63
- .openapi({ example: 'PENDING' }),
64
- kybs: z.array(KybZod).optional(),
65
- name: z.string().openapi({ example: 'Acme Corporation' }),
66
- ein: z.string().openapi({ example: '12-3456789' }).nullish(),
67
- companyType: z.string().openapi({ example: 'LLC' }).nullish(),
68
- streetAddress: z.string().openapi({ example: '123 Main St' }).nullish(),
69
- city: z.string().openapi({ example: 'Anytown' }).nullish(),
70
- state: z.string().openapi({ example: 'CA' }).nullable(),
71
- zip: z.string().openapi({ example: '12345' }).nullish(),
72
- country: z.string().openapi({ example: 'USA' }).nullish(),
73
- phone: z.string().openapi({ example: '+12124567890' }).nullish(),
74
- setupStatus: z.nativeEnum(SetupStatusType),
75
- });
76
- export type LegalEntityZod = z.infer<typeof LegalEntityZod>;
77
-
78
- export const IPaginatedLegalEntity = z.object({
79
- items: z.array(LegalEntityZod),
80
- meta: IPaginationMeta,
81
- });
82
- export type IPaginatedLegalEntity = z.infer<typeof IPaginatedLegalEntity>;
83
-
84
- const legalEntitiesInclude = z.enum(['kybs']);
85
-
86
- export const LegalEntityFiltersZod = z.object({
87
- kybStatus: z.nativeEnum(KYBStatus).optional(),
88
- sanctionsStatus: z.nativeEnum(SanctionsStatus).optional(),
89
- });
90
-
91
- /**
92
- * @description Query parameters for including related entities
93
- * @xample in contract us as -> query: z.object({}).merge(UsersIncludeQuery),
94
- */
95
- export const LegalEntitiesIncludeQuery = z.object({
96
- include: z
97
- .string()
98
- .optional()
99
- .transform((str) => (str ? str.split(',') : []))
100
- .refine(
101
- (includes) =>
102
- includes.every((include) =>
103
- legalEntitiesInclude.options.includes(include as any),
104
- ),
105
- {
106
- message: `Invalid include option provided. Valid options are: ${legalEntitiesInclude.options.join(',')}`,
107
- },
108
- )
109
- .openapi({
110
- example: `${legalEntitiesInclude.options.join(',')}`,
111
- }),
112
- });
113
- export interface LegalEntitiesIncludeQuery
114
- extends z.infer<typeof LegalEntitiesIncludeQuery> {}
115
- export const EINSchema = z
116
- .string()
117
- .openapi({ example: '123456789' })
118
- .length(9, 'Ein shall be of 9 characters')
119
- .refine((v) => !isNaN(Number(v)), {
120
- message: `Ein can only consist of numbers`,
121
- })
122
- .optional();
123
-
124
- export const CompanyNameSchema = z
125
- .string()
126
- .openapi({ example: 'Acme Corporation' })
127
- .min(2, 'Name is less than 2 characters ')
128
- .max(50, 'Name is more than 50 characters ');
129
-
130
- export const CompanyTypeSchema = z
131
- .string()
132
- .openapi({ example: 'LLC' })
133
- .min(2, 'companyType is less than 2 characters ')
134
- .max(50, 'companyType is more than 50 characters ');
135
-
136
- export const PostLegalEntitySchema = z
137
- .object({
138
- investorAccountId: investorAccountIdSchema,
139
- name: CompanyNameSchema,
140
- ein: EINSchema,
141
- email: z.string().email().optional(),
142
- companyType: CompanyTypeSchema.optional(),
143
- phone: PhoneZodSchema.openapi({ example: '+12124567890' }).optional(),
144
- dateOfIncorporation: z.lazy(() => dateSchema).optional(),
145
- stateOfIncorporation: z.string().optional(),
146
- })
147
- .and(AddressSchema);
148
-
149
- export type PostLegalEntityType = z.infer<typeof PostLegalEntitySchema>;
150
-
151
- export const UpdateLegalEntitySchema = z
152
- .object({
153
- id: legalEntityIdSchema.optional(),
154
- name: CompanyNameSchema.optional(),
155
- ein: EINSchema,
156
- email: z.string().email().optional(),
157
- companyType: CompanyTypeSchema.optional(),
158
- phone: PhoneZodSchema.openapi({ example: '+12124567890' }).optional(),
159
- dateOfIncorporation: z.lazy(() => dateSchema).optional(),
160
- stateOfIncorporation: z.string().optional(),
161
- })
162
- .and(AddressSchema);
163
-
164
- export type UpdateLegalEntityType = z.infer<typeof UpdateLegalEntitySchema>;
165
-
166
- export const ResponseLegalEntitySchema = z.object({
167
- id: legalEntityIdSchema,
168
- accountId: z.string(),
169
- investorAccountId: z.string(),
170
- name: CompanyNameSchema,
171
- ein: EINSchema.nullish(),
172
- email: z.string().email().nullable(),
173
- companyType: z.string().nullable(),
174
- address: z.string().nullable(),
175
- address2: z.string().nullable(),
176
- city: z.string().nullable(),
177
- state: z.string().nullable(),
178
- zip: z.string().nullable(),
179
- country: z.string().nullable(),
180
- phone: z.string().nullable(),
181
- dateOfIncorporation: z.coerce.date().nullable(),
182
- stateOfIncorporation: z.string().nullable(),
183
- setupStatus: z.nativeEnum(SetupStatusType),
184
- });
185
- export type ResponseLegalEntityType = z.infer<typeof ResponseLegalEntitySchema>;
@@ -1,46 +0,0 @@
1
- import { TypeID } from 'typeid-js';
2
- import { z } from 'zod';
3
- import { IBaseEntity } from './entity.types';
4
- export const loginHistoryIdSchema = z.string().refine(
5
- (value) => {
6
- try {
7
- const tid = TypeID.fromString(value);
8
- return tid.getType() === 'login_history';
9
- } catch {
10
- return false;
11
- }
12
- },
13
- {
14
- message:
15
- 'Invalid login history ID format. Must be a valid TypeID with "login_history" prefix.',
16
- },
17
- );
18
- export const ILoginHistory = IBaseEntity.extend({
19
- id: loginHistoryIdSchema,
20
- ipAddress: z.string().ip().nullable(),
21
- location: z.string().nullable(),
22
- browser: z.string().nullable(),
23
- deviceString: z.string().nullable(),
24
- osVersion: z.string().nullable(),
25
- browserVersion: z.string().nullable(),
26
- os: z.string().nullable(),
27
- userId: z.string().nullable(),
28
- user: z.any().nullable(),
29
- });
30
- export type ILoginHistory = z.infer<typeof ILoginHistory>;
31
-
32
- export const PostLoginHistoryZod = z.object({
33
- ipAddress: z.string().ip().nullable(),
34
- location: z.string().nullable(),
35
- browser: z.string().nullable(),
36
- deviceString: z.string().nullable(),
37
- osVersion: z.string().nullable(),
38
- browserVersion: z.string().nullable(),
39
- os: z.string().nullable(),
40
- });
41
- export type PostLoginHistoryZod = z.infer<typeof PostLoginHistoryZod>;
42
-
43
- export const IListLoginHistories = z.object({
44
- items: z.array(ILoginHistory),
45
- });
46
- export type IListLoginHistories = z.infer<typeof IListLoginHistories>;
@@ -1,436 +0,0 @@
1
- import { z } from 'zod';
2
- import { InvestorAccountType } from './common.types';
3
-
4
- export const IssuerWelcomeEmailTemplateZod = z.object({
5
- issuerName: z.string(),
6
- });
7
- export type IssuerWelcomeEmailTemplateZod = z.infer<
8
- typeof IssuerWelcomeEmailTemplateZod
9
- >;
10
-
11
- export const ResetPasswordEmailTemplateZod = z.object({
12
- name: z.string(),
13
- resetPasswordLink: z.string(),
14
- resetPasswordCode: z.string(),
15
- });
16
- export type ResetPasswordEmailTemplateZod = z.infer<
17
- typeof ResetPasswordEmailTemplateZod
18
- >;
19
-
20
- export const InvitationEmailTemplateZod = z.object({
21
- issuerName: z.string(),
22
- role: z.string(),
23
- invitationLink: z.string(),
24
- });
25
- export type InvitationEmailTemplateZod = z.infer<
26
- typeof InvitationEmailTemplateZod
27
- >;
28
-
29
- export const InvestorWelcomeEmailTemplateZod = z.object({
30
- investorName: z.string(),
31
- issuerName: z.string(),
32
- loginLink: z.string(),
33
- });
34
- export type InvestorWelcomeEmailTemplateZod = z.infer<
35
- typeof InvestorWelcomeEmailTemplateZod
36
- >;
37
-
38
- export const PlacedOrderLineItemsZod = z.object({
39
- name: z.string(),
40
- pricePerShare: z.number(),
41
- numberOfSharesPurchased: z.number(),
42
- totalInvestment: z.number(),
43
- });
44
- export type PlacedOrderLineItemsZod = z.infer<typeof PlacedOrderLineItemsZod>;
45
-
46
- export const OrderPlacedEmailTemplateZod = z.object({
47
- issuerName: z.string(),
48
- investorName: z.string(),
49
- investorAccountType: z.nativeEnum(InvestorAccountType),
50
- lineItems: z.array(PlacedOrderLineItemsZod),
51
- tradeDetailsEndpoint: z.string(),
52
- isWirePayment: z.boolean(),
53
- usAccountHolderName: z.string(),
54
- usBankName: z.string(),
55
- usRoutingNumber: z.string(),
56
- usAccountNumber: z.string(),
57
- reference: z.string(),
58
- swiftId: z.string(),
59
- });
60
- export type OrderPlacedEmailTemplateZod = z.infer<
61
- typeof OrderPlacedEmailTemplateZod
62
- >;
63
-
64
- export const OrderApprovedEmailTemplateZod = OrderPlacedEmailTemplateZod.omit({
65
- lineItems: true,
66
- }).extend({
67
- pricePerShare: z.number(),
68
- numberOfAssetsPurchased: z.number(),
69
- name: z.string(),
70
- totalAmount: z.number(),
71
- isWirePayment: z.boolean(),
72
- usAccountHolderName: z.string(),
73
- usBankName: z.string(),
74
- usRoutingNumber: z.string(),
75
- usAccountNumber: z.string(),
76
- reference: z.string(),
77
- swiftId: z.string(),
78
- });
79
- export type OrderApprovedEmailTemplateZod = z.infer<
80
- typeof OrderApprovedEmailTemplateZod
81
- >;
82
-
83
- export const TaskAssignedEmailTemplateZod = z.object({
84
- userName: z.string(),
85
- taskName: z.string(),
86
- assignedBy: z.string(),
87
- dueDate: z.string(),
88
- taskType: z.string(),
89
- priority: z.string(),
90
- description: z.string(),
91
- completeTaskEndpoint: z.string(),
92
- });
93
- export type TaskAssignedEmailTemplateZod = z.infer<
94
- typeof TaskAssignedEmailTemplateZod
95
- >;
96
- export const ResetPasswordSuccessEmailTemplateZod = z.object({
97
- name: z.string(),
98
- loginLink: z.string(),
99
- });
100
- export type ResetPasswordSuccessEmailTemplateZod = z.infer<
101
- typeof ResetPasswordSuccessEmailTemplateZod
102
- >;
103
-
104
- export const PaymentFailedEmailTemplateZod = z.object({
105
- firstName: z.string(),
106
- tradeDetailsEndpoint: z.string(),
107
- });
108
- export type PaymentFailedEmailTemplateZod = z.infer<
109
- typeof PaymentFailedEmailTemplateZod
110
- >;
111
- export const RetirementInstructionEmailTemplateZod = z.object({
112
- name: z.string(),
113
- instruction: z.string(),
114
- });
115
- export type RetirementInstructionEmailTemplateZod = z.infer<
116
- typeof RetirementInstructionEmailTemplateZod
117
- >;
118
-
119
- export const ContactUsEmailTemplateZod = z.object({
120
- firstName: z.string(),
121
- lastName: z.string(),
122
- email: z.string(),
123
- subject: z.string(),
124
- message: z.string(),
125
- timestamp: z.string(),
126
- });
127
- export type ContactUsEmailTemplateZod = z.infer<
128
- typeof ContactUsEmailTemplateZod
129
- >;
130
-
131
- export const SignatureRequestEmailTemplateZod = z.object({
132
- investorName: z.string(),
133
- requestedBy: z.string(),
134
- requestedByEmail: z.string(),
135
- documentName: z.string(),
136
- expirationDate: z.string(),
137
- signersList: z.array(
138
- z.object({
139
- name: z.string(),
140
- email: z.string(),
141
- }),
142
- ),
143
- });
144
- export type SignatureRequestEmailTemplateZod = z.infer<
145
- typeof SignatureRequestEmailTemplateZod
146
- >;
147
- // TODO: Add EMAIL_VERIFICATION
148
- export const EMAIL_TEMPLATES = {
149
- WELCOME_ISSUER: {
150
- subject: 'Welcome to Dalmore',
151
- path: 'welcome-issuer.mjml',
152
- body: `<html>
153
- <body>
154
- <p>Hello {{issuerName}},</p>
155
-
156
- <p>Welcome to Dalmore! We're thrilled to have you here as you take the next step in raising investments.</p>
157
-
158
- <p>Getting started is simple. Complete setting up your issuer account, submit your offering for review, and once approved, you'll be ready to connect with investors.</p>
159
-
160
- <p>For more details on how Dalmore can support your fundraising efforts, we've attached a brief info guide.</p>
161
-
162
- <p>If you have any questions, feel free to reach out.</p>
163
-
164
- <p>Best,<br>
165
- The Dalmore Team</p>
166
- </body>
167
- </html>`,
168
- },
169
-
170
- WELCOME_INVESTOR: {
171
- subject: 'Start Investing with {{issuerName}} on Dalmore',
172
- path: 'welcome-investor.mjml',
173
- body: `<html>
174
- <body>
175
- <p>Hello {{investorName}},</p>
176
-
177
- <p>{{issuerName}} is now accepting investments on Dalmore. Explore the offering and invest today.</p>
178
-
179
- <p>You can view the offering here:</p>
180
-
181
- <p><a href="{{heroAssetLink}}">View Offering</a></p>
182
-
183
- <p>If you have any questions, we're here to help.</p>
184
-
185
- <p>Best,<br>
186
- The Dalmore Team</p>
187
- </body>
188
- </html>`,
189
- },
190
-
191
- RESET_PASSWORD: {
192
- subject: 'Reset your password',
193
- path: 'reset-password.mjml',
194
- body: `<html>
195
- <body>
196
- <p>Hello {{name}},</p>
197
-
198
- <p>We received a request to reset your password. Click below to set a new one:</p>
199
-
200
- <p>Code: {{resetPasswordCode}}</p>
201
-
202
- <p><a href="{{resetPasswordLink}}">Reset Password</a></p>
203
-
204
- <p>If you didn't request this, please ignore this email.</p>
205
-
206
- <p>Best,<br>
207
- The Dalmore Team</p>
208
- </body>
209
- </html>`,
210
- },
211
-
212
- ISSUER_INVITATION: {
213
- subject: "You've Been Invited to Join an Issuer Account",
214
- path: 'invitation.mjml',
215
- body: `<html>
216
- <body>
217
- <p>Hello,</p>
218
-
219
- <p>You've been invited to join the {{issuerName}}'s account on Dalmore with the role of {{role}}.</p>
220
-
221
- <p>Click below to accept the invitation and access the account:</p>
222
-
223
- <p>{{invitationLink}}</p>
224
-
225
- <p>If you have any questions, feel free to reach out.</p>
226
-
227
- <p>Best,<br>
228
- The Dalmore Team</p>
229
- </body>
230
- </html>`,
231
- },
232
-
233
- COMPLIANCE_INVITATION: {
234
- subject: "You've Been Invited to Join an Compliance Account",
235
- path: 'compliance-invitation.mjml',
236
- body: `<html>
237
- <body>
238
- <p>Hello,</p>
239
-
240
- <p>You've been invited to join the Dalmore Group Compliance Portal with the role of {{role}}.</p>
241
-
242
- <p>Click below to accept the invitation and access the account:</p>
243
-
244
- <p>{{invitationLink}}</p>
245
-
246
- <p>If you have any questions, feel free to reach out.</p>
247
-
248
- <p>Best,<br>
249
- The Dalmore Team</p>
250
- </body>
251
- </html>`,
252
- },
253
-
254
- ORDER_PLACED: {
255
- subject: 'Your Trade Has Been Placed',
256
- path: 'order-placed.mjml',
257
- body: `<html>
258
- <body>
259
- <p>Hello {{investorName}},</p>
260
-
261
- <p>Your trade has been successfully placed with {{issuerName}}. Here are the details:</p>
262
-
263
- <p><b>Investor Account Type:</b> {{investorAccountType}}<br>
264
- <b>Offering Name:</b> {{offeringName}}<br>
265
- <b>Number of Assets Purchased:</b> {{numberOfAssetsPurchased}}<br>
266
- <b>Total Investment Value:</b> {{totalInvestmentAmount}}</p>
267
-
268
- <p>You will receive a confirmation once the order is reviewed.</p>
269
-
270
- <p><a href="{{tradeDetailsEndpoint}}">View Trade Details</a></p>
271
-
272
- <p>Best,<br>
273
- The Dalmore Team</p>
274
- </body>
275
- </html>`,
276
- },
277
-
278
- ORDER_APPROVED: {
279
- subject: 'Your Trade Has Been Approved',
280
- path: 'order-approved.mjml',
281
- body: `<html>
282
- <body>
283
- <p>Hello {{investorName}},</p>
284
-
285
- <p>Your trade with {{issuerName}} has been reviewed and approved. Here are the details:</p>
286
-
287
- <p><b>Investor Account Type:</b> {{investorAccountType}}<br>
288
- <b>Offering Name:</b> {{offeringName}}<br>
289
- <b>Number of Assets Purchased:</b> {{numberOfAssetsPurchased}}<br>
290
- <b>Total Investment Value:</b> {{totalInvestmentAmount}}</p>
291
-
292
- <p>You can view your trade details in your account.</p>
293
-
294
- <p>Best,<br>
295
- The Dalmore Team</p>
296
- </body>
297
- </html>`,
298
- },
299
- TASK_ASSIGNED: {
300
- subject: 'New Task Assigned',
301
- path: 'task-assigned.mjml',
302
- body: `<html>
303
- <body>
304
- <p>Hi, {{userName}}!</p>
305
-
306
- <p>You have a new task assigned to you. Please review the details below:</p>
307
-
308
- <p>Task Name: {{taskName}}<br>
309
- Assigned By: {{assignedBy}}<br>
310
- Due Date: {{dueDate}}<br>
311
- Task Type: {{taskType}}<br>
312
- Priority: {{priority}}<br>
313
- Description: {{description}}</p>
314
-
315
- <p><a href="{{completeTaskEndpoint}}">Complete Task</a></p>
316
- </body>
317
- </html>
318
- `,
319
- },
320
- AML_PENDING: {
321
- subject: 'AML Pending',
322
- path: 'aml-pending.mjml',
323
- body: `<html>
324
- <body>
325
- <p>Hi, {{userName}}!</p>
326
-
327
- <p>Your AML status is pending. Please complete your AML.</p>
328
-
329
- <p>Click below to visit your AML record:</p>
330
-
331
- <p><a href="{{completeAmlEndpoint}}">Visit AML</a></p>
332
- </body>
333
- </html>
334
- `,
335
- },
336
- PAYMENT_FAILED: {
337
- subject: 'Payment Failed',
338
- path: 'payment-failed.mjml',
339
- body: ``,
340
- },
341
- RESET_PASSWORD_SUCCESS: {
342
- subject: 'Password Changed Successfully',
343
- path: 'reset-password-successful.mjml',
344
- body: ``,
345
- },
346
- RETIREMENT_INSTRUCTION: {
347
- subject: 'Retirement Instruction',
348
- path: 'retirement-instruction.mjml',
349
- body: ``,
350
- },
351
- EMAIL_NOTIFICATION: {
352
- subject: '{{subject}}',
353
- path: 'email-notification.mjml',
354
- body: ``,
355
- },
356
- CONTACT_US: {
357
- subject: 'New Contact Message',
358
- path: 'contact-us.mjml',
359
- body: ``,
360
- },
361
- SUBMIT_PAYMENT: {
362
- subject: 'New Task Assigned – Submit Payment',
363
- path: 'submit-payment.mjml',
364
- body: ``,
365
- },
366
- SIGNATURE_REQUEST: {
367
- subject: 'Document Signature Request',
368
- path: 'signature-request.mjml',
369
- body: ``,
370
- },
371
- };
372
- // TODO: Add EMAIL_VERIFICATION
373
- export enum EmailTemplatesType {
374
- WELCOME_ISSUER = 'WELCOME_ISSUER',
375
- WELCOME_INVESTOR = 'WELCOME_INVESTOR',
376
- RESET_PASSWORD = 'RESET_PASSWORD',
377
- RESET_PASSWORD_SUCCESS = 'RESET_PASSWORD_SUCCESS',
378
- ISSUER_INVITATION = 'ISSUER_INVITATION',
379
- COMPLIANCE_INVITATION = 'COMPLIANCE_INVITATION',
380
- EMAIL_NOTIFICATION = 'EMAIL_NOTIFICATION',
381
- ORDER_PLACED = 'ORDER_PLACED',
382
- ORDER_APPROVED = 'ORDER_APPROVED',
383
- TASK_ASSIGNED = 'TASK_ASSIGNED',
384
- PAYMENT_FAILED = 'PAYMENT_FAILED',
385
- UPDATE_PAYMENT = 'UPDATE_PAYMENT',
386
- KYC_VERIFICATION_REQUIRED = 'KYC_VERIFICATION_REQUIRED',
387
- DOCUMENT_SIGNATURE_PENDING = 'DOCUMENT_SIGNATURE_PENDING',
388
- VERIFY_ACCOUNT = 'VERIFY_ACCOUNT',
389
- SIGNATURE_REQUEST = 'SIGNATURE_REQUEST',
390
- SUBMIT_PAYMENT = 'SUBMIT_PAYMENT',
391
- RETIREMENT_INSTRUCTION = 'RETIREMENT_INSTRUCTION',
392
- AML_PENDING = 'AML_PENDING',
393
- CONTACT_US = 'CONTACT_US',
394
- NONE = 'NONE',
395
- }
396
-
397
- export enum EmailAttachmentsType {
398
- USER_MANUAL = 'USER_MANUAL',
399
- BROKER_DEALER = 'BROKER_DEALER',
400
- STREAM = 'STREAM',
401
- STREAMS = 'STREAMS',
402
- OTHER = 'OTHER',
403
- NONE = 'NONE',
404
- }
405
-
406
- export const FooterZod = z.object({
407
- linkedinUrl: z.string().url().nullable(),
408
- twitterUrl: z.string().url().nullable(),
409
- facebookUrl: z.string().url().nullable(),
410
- instagramUrl: z.string().url().nullable(),
411
- mailSupporter: z.string().email().nullable(),
412
- websiteUrl: z.string().url().nullable(),
413
- otherUrls: z.array(z.string().url().nullable()).nullable(),
414
- poweredByImageUrl: z.string().url().nullable(),
415
- contactUsUrl: z.string().url().nullable(),
416
- });
417
- export type FooterZod = z.infer<typeof FooterZod>;
418
-
419
- export const HeaderZod = z.object({
420
- companyName: z.string(),
421
- logoUrl: z.string().nullable(),
422
- });
423
-
424
- export type HeaderZod = z.infer<typeof HeaderZod>;
425
-
426
- export const HeaderAndFooterZod = z.object({
427
- header: HeaderZod,
428
- footer: FooterZod,
429
- });
430
- export type HeaderAndFooterZod = z.infer<typeof HeaderAndFooterZod>;
431
-
432
- export const EmailThemeSettingZod = z.record(z.string(), z.string().nullable());
433
- export type EmailThemeSetting = z.infer<typeof EmailThemeSettingZod>;
434
-
435
- export const EmailThemeSettingsZod = z.array(EmailThemeSettingZod);
436
- export type EmailThemeSettingsZod = z.infer<typeof EmailThemeSettingsZod>;