grm-shared-library 1.1.211 → 1.1.213
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.
- package/README.md +51 -0
- package/dist/cjs/kafka/dtos/account-deletion/account-deletion-request-payload.dto.js +6 -0
- package/dist/cjs/kafka/dtos/account-deletion/account-deletion-request-payload.dto.js.map +1 -1
- package/dist/cjs/kafka/dtos/otp/create-otp-payload.dto.js +6 -0
- package/dist/cjs/kafka/dtos/otp/create-otp-payload.dto.js.map +1 -1
- package/dist/cjs/kafka/dtos/password/password-reset-payload.dto.js +6 -0
- package/dist/cjs/kafka/dtos/password/password-reset-payload.dto.js.map +1 -1
- package/dist/cjs/kafka/dtos/user/create-user-registered-payload.dto.js +6 -0
- package/dist/cjs/kafka/dtos/user/create-user-registered-payload.dto.js.map +1 -1
- package/dist/cjs/modules/notification/constants/notification-sender.const.js +30 -0
- package/dist/cjs/modules/notification/constants/notification-sender.const.js.map +1 -0
- package/dist/cjs/modules/notification/dtos/billing-notification.dto.js +213 -0
- package/dist/cjs/modules/notification/dtos/billing-notification.dto.js.map +1 -0
- package/dist/cjs/modules/notification/dtos/organization-notification-settings.dto.js +354 -0
- package/dist/cjs/modules/notification/dtos/organization-notification-settings.dto.js.map +1 -0
- package/dist/cjs/modules/notification/enums/billing-notification.enum.js +33 -0
- package/dist/cjs/modules/notification/enums/billing-notification.enum.js.map +1 -0
- package/dist/cjs/modules/notification/enums/email-sender-verification.enum.js +33 -0
- package/dist/cjs/modules/notification/enums/email-sender-verification.enum.js.map +1 -0
- package/dist/cjs/modules/notification/enums/notification-branding-source.enum.js +22 -0
- package/dist/cjs/modules/notification/enums/notification-branding-source.enum.js.map +1 -0
- package/dist/cjs/modules/notification/enums/notification-sender-source.enum.js +15 -0
- package/dist/cjs/modules/notification/enums/notification-sender-source.enum.js.map +1 -0
- package/dist/cjs/modules/notification/enums/notification-sender-status.enum.js +24 -0
- package/dist/cjs/modules/notification/enums/notification-sender-status.enum.js.map +1 -0
- package/dist/cjs/modules/notification/enums/sms-provider-name.enum.js +5 -0
- package/dist/cjs/modules/notification/enums/sms-provider-name.enum.js.map +1 -1
- package/dist/cjs/modules/notification/enums/sms-sender-type.enum.js +22 -0
- package/dist/cjs/modules/notification/enums/sms-sender-type.enum.js.map +1 -0
- package/dist/cjs/modules/notification/index.js +14 -0
- package/dist/cjs/modules/notification/index.js.map +1 -1
- package/dist/cjs/modules/notification/interfaces/billing-notification-result.js +3 -0
- package/dist/cjs/modules/notification/interfaces/billing-notification-result.js.map +1 -0
- package/dist/cjs/modules/notification/interfaces/organization-notification-settings.js +3 -0
- package/dist/cjs/modules/notification/interfaces/organization-notification-settings.js.map +1 -0
- package/dist/cjs/modules/notification/utils/notification-sender.util.js +67 -0
- package/dist/cjs/modules/notification/utils/notification-sender.util.js.map +1 -0
- package/dist/cjs/modules/permission/data/permissions.data.js +8 -0
- package/dist/cjs/modules/permission/data/permissions.data.js.map +1 -1
- package/dist/cjs/modules/permission/enums/permission-actions.enum.js +15 -0
- package/dist/cjs/modules/permission/enums/permission-actions.enum.js.map +1 -1
- package/dist/cjs/modules/permission/enums/permissions-module.enum.js +1 -0
- package/dist/cjs/modules/permission/enums/permissions-module.enum.js.map +1 -1
- package/dist/cjs/modules/role/data/roles.data.js +8 -0
- package/dist/cjs/modules/role/data/roles.data.js.map +1 -1
- package/dist/esm/kafka/dtos/account-deletion/account-deletion-request-payload.dto.js +7 -1
- package/dist/esm/kafka/dtos/account-deletion/account-deletion-request-payload.dto.js.map +1 -1
- package/dist/esm/kafka/dtos/otp/create-otp-payload.dto.js +7 -1
- package/dist/esm/kafka/dtos/otp/create-otp-payload.dto.js.map +1 -1
- package/dist/esm/kafka/dtos/password/password-reset-payload.dto.js +7 -1
- package/dist/esm/kafka/dtos/password/password-reset-payload.dto.js.map +1 -1
- package/dist/esm/kafka/dtos/user/create-user-registered-payload.dto.js +7 -1
- package/dist/esm/kafka/dtos/user/create-user-registered-payload.dto.js.map +1 -1
- package/dist/esm/modules/notification/constants/notification-sender.const.js +27 -0
- package/dist/esm/modules/notification/constants/notification-sender.const.js.map +1 -0
- package/dist/esm/modules/notification/dtos/billing-notification.dto.js +205 -0
- package/dist/esm/modules/notification/dtos/billing-notification.dto.js.map +1 -0
- package/dist/esm/modules/notification/dtos/organization-notification-settings.dto.js +343 -0
- package/dist/esm/modules/notification/dtos/organization-notification-settings.dto.js.map +1 -0
- package/dist/esm/modules/notification/enums/billing-notification.enum.js +30 -0
- package/dist/esm/modules/notification/enums/billing-notification.enum.js.map +1 -0
- package/dist/esm/modules/notification/enums/email-sender-verification.enum.js +30 -0
- package/dist/esm/modules/notification/enums/email-sender-verification.enum.js.map +1 -0
- package/dist/esm/modules/notification/enums/notification-branding-source.enum.js +19 -0
- package/dist/esm/modules/notification/enums/notification-branding-source.enum.js.map +1 -0
- package/dist/esm/modules/notification/enums/notification-sender-source.enum.js +12 -0
- package/dist/esm/modules/notification/enums/notification-sender-source.enum.js.map +1 -0
- package/dist/esm/modules/notification/enums/notification-sender-status.enum.js +21 -0
- package/dist/esm/modules/notification/enums/notification-sender-status.enum.js.map +1 -0
- package/dist/esm/modules/notification/enums/sms-provider-name.enum.js +5 -0
- package/dist/esm/modules/notification/enums/sms-provider-name.enum.js.map +1 -1
- package/dist/esm/modules/notification/enums/sms-sender-type.enum.js +19 -0
- package/dist/esm/modules/notification/enums/sms-sender-type.enum.js.map +1 -0
- package/dist/esm/modules/notification/index.js +14 -0
- package/dist/esm/modules/notification/index.js.map +1 -1
- package/dist/esm/modules/notification/interfaces/billing-notification-result.js +2 -0
- package/dist/esm/modules/notification/interfaces/billing-notification-result.js.map +1 -0
- package/dist/esm/modules/notification/interfaces/organization-notification-settings.js +2 -0
- package/dist/esm/modules/notification/interfaces/organization-notification-settings.js.map +1 -0
- package/dist/esm/modules/notification/utils/notification-sender.util.js +60 -0
- package/dist/esm/modules/notification/utils/notification-sender.util.js.map +1 -0
- package/dist/esm/modules/permission/data/permissions.data.js +8 -0
- package/dist/esm/modules/permission/data/permissions.data.js.map +1 -1
- package/dist/esm/modules/permission/enums/permission-actions.enum.js +15 -0
- package/dist/esm/modules/permission/enums/permission-actions.enum.js.map +1 -1
- package/dist/esm/modules/permission/enums/permissions-module.enum.js +1 -0
- package/dist/esm/modules/permission/enums/permissions-module.enum.js.map +1 -1
- package/dist/esm/modules/role/data/roles.data.js +8 -0
- package/dist/esm/modules/role/data/roles.data.js.map +1 -1
- package/dist/types/kafka/dtos/account-deletion/account-deletion-request-payload.dto.d.ts +6 -0
- package/dist/types/kafka/dtos/otp/create-otp-payload.dto.d.ts +6 -0
- package/dist/types/kafka/dtos/password/password-reset-payload.dto.d.ts +6 -0
- package/dist/types/kafka/dtos/user/create-user-registered-payload.dto.d.ts +6 -0
- package/dist/types/modules/notification/constants/notification-sender.const.d.ts +16 -0
- package/dist/types/modules/notification/dtos/billing-notification.dto.d.ts +56 -0
- package/dist/types/modules/notification/dtos/organization-notification-settings.dto.d.ts +64 -0
- package/dist/types/modules/notification/enums/billing-notification.enum.d.ts +27 -0
- package/dist/types/modules/notification/enums/email-sender-verification.enum.d.ts +27 -0
- package/dist/types/modules/notification/enums/notification-branding-source.enum.d.ts +17 -0
- package/dist/types/modules/notification/enums/notification-sender-source.enum.d.ts +10 -0
- package/dist/types/modules/notification/enums/notification-sender-status.enum.d.ts +19 -0
- package/dist/types/modules/notification/enums/sms-provider-name.enum.d.ts +6 -1
- package/dist/types/modules/notification/enums/sms-sender-type.enum.d.ts +17 -0
- package/dist/types/modules/notification/index.d.ts +12 -0
- package/dist/types/modules/notification/interfaces/billing-notification-result.d.ts +35 -0
- package/dist/types/modules/notification/interfaces/email-send-request.d.ts +6 -0
- package/dist/types/modules/notification/interfaces/email-send-result.d.ts +7 -0
- package/dist/types/modules/notification/interfaces/organization-notification-settings.d.ts +163 -0
- package/dist/types/modules/notification/interfaces/provider-attempt.d.ts +5 -0
- package/dist/types/modules/notification/interfaces/sms-send-result.d.ts +7 -0
- package/dist/types/modules/notification/utils/notification-sender.util.d.ts +25 -0
- package/dist/types/modules/permission/enums/permission-actions.enum.d.ts +4 -1
- package/dist/types/modules/permission/enums/permissions-module.enum.d.ts +2 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -146,6 +146,39 @@ filtering) are delivered in later phases and should build on top of these types.
|
|
|
146
146
|
npm test # compiles src/modules/country and runs the country/currency suite
|
|
147
147
|
```
|
|
148
148
|
|
|
149
|
+
## Organization notification settings
|
|
150
|
+
|
|
151
|
+
Clarion is multi-tenant, so what a customer sees in a notification belongs to the
|
|
152
|
+
**organization** that serves them. `modules/notification` carries the contract for
|
|
153
|
+
that, shared by clarion-notification (owner), the gateway (proxy) and
|
|
154
|
+
clarion-authentication (emitter):
|
|
155
|
+
|
|
156
|
+
- **`organizationId` is the key.** The four auth event payloads (`CreateOTPPayloadDto`,
|
|
157
|
+
`CreateUserRegisteredPayloadDto`, `PasswordResetPayloadDto`,
|
|
158
|
+
`AccountDeletionRequestPayloadDto`) gained an optional `organizationId`, and
|
|
159
|
+
`EmailSendRequest` / `SmsSendRequest` carry one. `appId` stays on every payload, but
|
|
160
|
+
only as the fallback for an emitter that has not been upgraded. The notification
|
|
161
|
+
service validates with `whitelist: true`, so it must be on a version that declares
|
|
162
|
+
the field or the field is stripped before anything reads it.
|
|
163
|
+
- **Branding resolves field by field** - `NotificationBrandingSource`: the
|
|
164
|
+
organization's profile, then its record in clarion-organization, then the legacy
|
|
165
|
+
per-app defaults, then the platform. `UpsertOrganizationNotificationBrandingDto`
|
|
166
|
+
turns `""` into `null`, and null means *inherit again*, not *blank*.
|
|
167
|
+
- **Email senders are verified per provider** (`EmailSenderProviderVerification`). A
|
|
168
|
+
provider only sends from an address it has `VERIFIED`; otherwise that provider uses
|
|
169
|
+
the platform sender and keeps the organization's display name and reply-to.
|
|
170
|
+
- **SMS senders are requested, then approved** (`NotificationSenderStatus`). Only
|
|
171
|
+
`ACTIVE` senders are used; everything else falls back to the country-aware default.
|
|
172
|
+
`validateSmsSenderId(type, value)` is the one definition of a valid sender.
|
|
173
|
+
- **Providers describe themselves** (`SmsProviderDescriptor`), like tracking providers
|
|
174
|
+
do. `SmsProviderName` only reserves a code; the catalogue says what is usable.
|
|
175
|
+
- Every send result records `sender` and `senderSource`
|
|
176
|
+
(`ORGANIZATION` | `PLATFORM_DEFAULT`), so "why was this Upesy-branded?" is a query.
|
|
177
|
+
|
|
178
|
+
Values that end up inside email CSS or headers are validated as such: colours are
|
|
179
|
+
`#RRGGBB` only, logos are `https` only, and a sender display name may not contain a
|
|
180
|
+
line break. `notification-sender.spec.ts` pins each of those.
|
|
181
|
+
|
|
149
182
|
## Roles and permissions
|
|
150
183
|
|
|
151
184
|
This package is the authority on both. clarion-authentication seeds them into its
|
|
@@ -194,6 +227,24 @@ all twelve (everybody who could administer tracking before the split still can);
|
|
|
194
227
|
`Organization:User` - the five `read` actions; `Control-Centre:User` and `Responder` -
|
|
195
228
|
position and history; `Mobile-User` - **none**.
|
|
196
229
|
|
|
230
|
+
### The Notification permission module
|
|
231
|
+
|
|
232
|
+
An organization's notification settings (clarion-notification) decide what its
|
|
233
|
+
**customers** see: how emails are branded, the address they come from, and the sender
|
|
234
|
+
ID its SMS arrive under. They have actions of their own rather than reusing
|
|
235
|
+
`update:organization`, because a wrong logo or sender goes out on every OTP and alert.
|
|
236
|
+
|
|
237
|
+
| Action | Covers |
|
|
238
|
+
|---|---|
|
|
239
|
+
| `read:notification-settings` | Reading the settings, the effective (resolved) branding and the SMS provider catalogue. |
|
|
240
|
+
| `manage:notification-settings` | Saving branding; adding, verifying and removing email senders; **requesting** SMS senders; sending a test email. |
|
|
241
|
+
| `approve:notification-sender` | Moving an SMS sender to `ACTIVE` / `SUSPENDED` / `REJECTED`. |
|
|
242
|
+
|
|
243
|
+
Owner and Admin hold the first two. **No role holds `approve:notification-sender`** -
|
|
244
|
+
only Super-Admin (`*`) passes it, and `roles.spec.ts` pins that. Activating a sender
|
|
245
|
+
asserts that it is registered with the provider and the telco; an organization able to
|
|
246
|
+
approve its own could send SMS under any name it typed.
|
|
247
|
+
|
|
197
248
|
### Adding a role: every step fails silently on its own
|
|
198
249
|
|
|
199
250
|
1. **Here** - the `Roles` value, a scope list, and a `ROLES_DATA` entry. `roles.spec.ts`
|
|
@@ -22,6 +22,12 @@ __decorate([
|
|
|
22
22
|
(0, class_validator_1.IsNotEmpty)(),
|
|
23
23
|
__metadata("design:type", String)
|
|
24
24
|
], AccountDeletionRequestPayloadDto.prototype, "appId", void 0);
|
|
25
|
+
__decorate([
|
|
26
|
+
(0, class_validator_1.IsInt)(),
|
|
27
|
+
(0, class_validator_1.IsPositive)(),
|
|
28
|
+
(0, class_validator_1.IsOptional)(),
|
|
29
|
+
__metadata("design:type", Number)
|
|
30
|
+
], AccountDeletionRequestPayloadDto.prototype, "organizationId", void 0);
|
|
25
31
|
__decorate([
|
|
26
32
|
(0, class_validator_1.IsNumber)(),
|
|
27
33
|
(0, class_validator_1.IsNotEmpty)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account-deletion-request-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/account-deletion/account-deletion-request-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"account-deletion-request-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/account-deletion/account-deletion-request-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA0I;AAC1I,yDAA8C;AAC9C,wDAA0D;AAC1D,uGAA6F;AAE7F,MAAa,gCAAgC;CA4C5C;AA5CD,4EA4CC;AAzCG;IAFC,IAAA,wBAAM,EAAC,wBAAa,CAAC;IACrB,IAAA,4BAAU,GAAE;;+DACS;AAUtB;IAHC,IAAA,uBAAK,GAAE;IACP,IAAA,4BAAU,GAAE;IACZ,IAAA,4BAAU,GAAE;;wEACW;AAIxB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;gEACG;AAIhB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;8DACC;AAId;IAFC,IAAA,yBAAO,GAAE;IACT,IAAA,4BAAU,GAAE;;+DACE;AAIf;IAFC,IAAA,wBAAM,EAAC,gDAAmB,CAAC;IAC3B,IAAA,4BAAU,GAAE;;gEACgB;AAM7B;IAJC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;IACZ,IAAA,2BAAS,EAAC,GAAG,CAAC;IACd,IAAA,6BAAS,EAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC;;4EAC/B;AAI5B;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;mEACM;AAInB;IAFC,IAAA,8BAAY,GAAE;IACd,IAAA,4BAAU,GAAE;;mEACM"}
|
|
@@ -21,6 +21,12 @@ __decorate([
|
|
|
21
21
|
(0, class_validator_1.IsNotEmpty)(),
|
|
22
22
|
__metadata("design:type", String)
|
|
23
23
|
], CreateOTPPayloadDto.prototype, "appId", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsInt)(),
|
|
26
|
+
(0, class_validator_1.IsPositive)(),
|
|
27
|
+
(0, class_validator_1.IsOptional)(),
|
|
28
|
+
__metadata("design:type", Number)
|
|
29
|
+
], CreateOTPPayloadDto.prototype, "organizationId", void 0);
|
|
24
30
|
__decorate([
|
|
25
31
|
(0, class_validator_1.IsString)(),
|
|
26
32
|
(0, class_validator_1.IsNotEmpty)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-otp-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/otp/create-otp-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"create-otp-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/otp/create-otp-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAwI;AACxI,uEAAmE;AACnE,wDAA0D;AAE1D,MAAa,mBAAmB;CA0D/B;AA1DD,kDA0DC;AAvDG;IAFC,IAAA,wBAAM,EAAC,wBAAa,CAAC;IACrB,IAAA,4BAAU,GAAE;;kDACS;AAUtB;IAHC,IAAA,uBAAK,GAAE;IACP,IAAA,4BAAU,GAAE;IACZ,IAAA,4BAAU,GAAE;;2DACW;AAIxB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;iDACC;AAId;IAFC,IAAA,yBAAO,GAAE;IACT,IAAA,4BAAU,GAAE;;kDACE;AAIf;IAFC,IAAA,+BAAa,GAAE;IACf,IAAA,4BAAU,GAAE;;wDACQ;AAIrB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;iDACC;AAId;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;8DACc;AAI3B;IAFC,IAAA,wBAAM,GAAE;IACR,IAAA,4BAAU,GAAE;8BACgB,IAAI;uEAAC;AAIlC;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;gDACA;AAIb;IAFC,IAAA,wBAAM,GAAE;IACR,IAAA,4BAAU,GAAE;8BACE,IAAI;yDAAC;AAIpB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;qEACqB;AAIlC;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;mDACM;AAInB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;uDACoB"}
|
|
@@ -21,6 +21,12 @@ __decorate([
|
|
|
21
21
|
(0, class_validator_1.IsNotEmpty)(),
|
|
22
22
|
__metadata("design:type", String)
|
|
23
23
|
], PasswordResetPayloadDto.prototype, "appId", void 0);
|
|
24
|
+
__decorate([
|
|
25
|
+
(0, class_validator_1.IsInt)(),
|
|
26
|
+
(0, class_validator_1.IsPositive)(),
|
|
27
|
+
(0, class_validator_1.IsOptional)(),
|
|
28
|
+
__metadata("design:type", Number)
|
|
29
|
+
], PasswordResetPayloadDto.prototype, "organizationId", void 0);
|
|
24
30
|
__decorate([
|
|
25
31
|
(0, class_validator_1.IsString)(),
|
|
26
32
|
(0, class_validator_1.IsNotEmpty)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"password-reset-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/password/password-reset-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"password-reset-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/password/password-reset-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAA6G;AAC7G,yDAA8C;AAC9C,wDAA0D;AAE1D,MAAa,uBAAuB;CAgCnC;AAhCD,0DAgCC;AA7BG;IAFC,IAAA,wBAAM,EAAC,wBAAa,CAAC;IACrB,IAAA,4BAAU,GAAE;;sDACS;AAUtB;IAHC,IAAA,uBAAK,GAAE;IACP,IAAA,4BAAU,GAAE;IACZ,IAAA,4BAAU,GAAE;;+DACW;AAIxB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;qDACC;AAId;IAFC,IAAA,yBAAO,GAAE;IACT,IAAA,4BAAU,GAAE;;sDACE;AAKf;IAHC,IAAA,4BAAU,GAAE;IACZ,IAAA,sBAAI,GAAE;IACN,IAAA,6BAAS,EAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC;;0DACxC;AAKnB;IAHC,IAAA,4BAAU,GAAE;IACZ,IAAA,0BAAQ,GAAE;IACV,IAAA,6BAAS,EAAC,CAAC,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC,KAAK,KAAK,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC;;wDAC1C"}
|
|
@@ -25,6 +25,12 @@ __decorate([
|
|
|
25
25
|
(0, class_validator_1.IsNotEmpty)(),
|
|
26
26
|
__metadata("design:type", String)
|
|
27
27
|
], CreateUserRegisteredPayloadDto.prototype, "appId", void 0);
|
|
28
|
+
__decorate([
|
|
29
|
+
(0, class_validator_1.IsInt)(),
|
|
30
|
+
(0, class_validator_1.IsPositive)(),
|
|
31
|
+
(0, class_validator_1.IsOptional)(),
|
|
32
|
+
__metadata("design:type", Number)
|
|
33
|
+
], CreateUserRegisteredPayloadDto.prototype, "organizationId", void 0);
|
|
28
34
|
__decorate([
|
|
29
35
|
(0, class_validator_1.IsString)(),
|
|
30
36
|
(0, class_validator_1.IsNotEmpty)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"create-user-registered-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/user/create-user-registered-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"create-user-registered-payload.dto.js","sourceRoot":"","sources":["../../../../../src/kafka/dtos/user/create-user-registered-payload.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAkJ;AAClJ,wDAA0D;AAE1D,MAAa,8BAA8B;CAsC1C;AAtCD,wEAsCC;AAnCG;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;0DACD;AAIZ;IAFC,IAAA,wBAAM,EAAC,wBAAa,CAAC;IACrB,IAAA,4BAAU,GAAE;;6DACS;AAUtB;IAHC,IAAA,uBAAK,GAAE;IACP,IAAA,4BAAU,GAAE;IACZ,IAAA,4BAAU,GAAE;;sEACW;AAIxB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;4DACC;AAId;IAFC,IAAA,yBAAO,GAAE;IACT,IAAA,4BAAU,GAAE;;6DACE;AAIf;IAFC,IAAA,+BAAa,GAAE;IACf,IAAA,4BAAU,GAAE;;mEACQ;AAIrB;IAFC,IAAA,wBAAM,GAAE;IACR,IAAA,4BAAU,GAAE;8BACD,IAAI;iEAAC;AAIjB;IAFC,IAAA,0BAAQ,GAAE;IACV,IAAA,4BAAU,GAAE;;kEACoB"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MAX_SMS_SENDERS_PER_ORGANIZATION = exports.MAX_EMAIL_SENDERS_PER_ORGANIZATION = exports.SMS_SENDER_ID_HINTS = exports.SMS_SENDER_ID_PATTERNS = exports.BRAND_COLOUR_PATTERN = void 0;
|
|
4
|
+
const sms_sender_type_enum_1 = require("../enums/sms-sender-type.enum");
|
|
5
|
+
/** `#RRGGBB`. The only colour format accepted, because it is inlined into email CSS. */
|
|
6
|
+
exports.BRAND_COLOUR_PATTERN = /^#[0-9a-fA-F]{6}$/;
|
|
7
|
+
/**
|
|
8
|
+
* What a sender value must look like, per type.
|
|
9
|
+
*
|
|
10
|
+
* ALPHANUMERIC follows the GSM rule every supported provider enforces: 3-11
|
|
11
|
+
* characters, at least one letter (an all-digit "name" is a number, and telcos
|
|
12
|
+
* reject it as spoofing).
|
|
13
|
+
*/
|
|
14
|
+
exports.SMS_SENDER_ID_PATTERNS = Object.freeze({
|
|
15
|
+
[sms_sender_type_enum_1.SmsSenderType.ALPHANUMERIC]: /^(?=.*[A-Za-z])[A-Za-z0-9 _.&-]{3,11}$/,
|
|
16
|
+
[sms_sender_type_enum_1.SmsSenderType.PHONE_NUMBER]: /^\+[1-9]\d{6,14}$/,
|
|
17
|
+
[sms_sender_type_enum_1.SmsSenderType.SHORT_CODE]: /^\d{3,8}$/,
|
|
18
|
+
[sms_sender_type_enum_1.SmsSenderType.MESSAGING_SERVICE]: /^MG[0-9a-fA-F]{32}$/,
|
|
19
|
+
});
|
|
20
|
+
/** Human-readable form of {@link SMS_SENDER_ID_PATTERNS}, for validation messages and form hints. */
|
|
21
|
+
exports.SMS_SENDER_ID_HINTS = Object.freeze({
|
|
22
|
+
[sms_sender_type_enum_1.SmsSenderType.ALPHANUMERIC]: '3-11 characters (letters, digits, space, _ . & -) with at least one letter, e.g. G4S',
|
|
23
|
+
[sms_sender_type_enum_1.SmsSenderType.PHONE_NUMBER]: 'an E.164 number, e.g. +254711000000',
|
|
24
|
+
[sms_sender_type_enum_1.SmsSenderType.SHORT_CODE]: '3-8 digits, e.g. 22384',
|
|
25
|
+
[sms_sender_type_enum_1.SmsSenderType.MESSAGING_SERVICE]: 'a Twilio Messaging Service SID (MG followed by 32 hex characters)',
|
|
26
|
+
});
|
|
27
|
+
/** Upper bounds that keep one organization from turning its settings into a list to page through. */
|
|
28
|
+
exports.MAX_EMAIL_SENDERS_PER_ORGANIZATION = 10;
|
|
29
|
+
exports.MAX_SMS_SENDERS_PER_ORGANIZATION = 30;
|
|
30
|
+
//# sourceMappingURL=notification-sender.const.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"notification-sender.const.js","sourceRoot":"","sources":["../../../../../src/modules/notification/constants/notification-sender.const.ts"],"names":[],"mappings":";;;AAAA,wEAA8D;AAE9D,wFAAwF;AAC3E,QAAA,oBAAoB,GAAG,mBAAmB,CAAC;AAExD;;;;;;GAMG;AACU,QAAA,sBAAsB,GAA4C,MAAM,CAAC,MAAM,CAAC;IACzF,CAAC,oCAAa,CAAC,YAAY,CAAC,EAAE,wCAAwC;IACtE,CAAC,oCAAa,CAAC,YAAY,CAAC,EAAE,mBAAmB;IACjD,CAAC,oCAAa,CAAC,UAAU,CAAC,EAAE,WAAW;IACvC,CAAC,oCAAa,CAAC,iBAAiB,CAAC,EAAE,qBAAqB;CAC3D,CAAC,CAAC;AAEH,qGAAqG;AACxF,QAAA,mBAAmB,GAA4C,MAAM,CAAC,MAAM,CAAC;IACtF,CAAC,oCAAa,CAAC,YAAY,CAAC,EAAE,sFAAsF;IACpH,CAAC,oCAAa,CAAC,YAAY,CAAC,EAAE,qCAAqC;IACnE,CAAC,oCAAa,CAAC,UAAU,CAAC,EAAE,wBAAwB;IACpD,CAAC,oCAAa,CAAC,iBAAiB,CAAC,EAAE,mEAAmE;CACzG,CAAC,CAAC;AAEH,qGAAqG;AACxF,QAAA,kCAAkC,GAAG,EAAE,CAAC;AACxC,QAAA,gCAAgC,GAAG,EAAE,CAAC"}
|
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __metadata = (this && this.__metadata) || function (k, v) {
|
|
9
|
+
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
10
|
+
};
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.BillingSmsNotificationDto = exports.BillingPushNotificationDto = exports.BillingEmailNotificationDto = exports.BillingEmailAttachmentDto = exports.BillingDocumentReferenceDto = void 0;
|
|
13
|
+
const swagger_1 = require("@nestjs/swagger");
|
|
14
|
+
const class_transformer_1 = require("class-transformer");
|
|
15
|
+
const class_validator_1 = require("class-validator");
|
|
16
|
+
const billing_notification_enum_1 = require("../enums/billing-notification.enum");
|
|
17
|
+
/**
|
|
18
|
+
* clarion-billing -> clarion-notification, over HTTP.
|
|
19
|
+
*
|
|
20
|
+
* Most billing notifications travel as Kafka events. These three routes exist for
|
|
21
|
+
* the cases where billing wants to know, synchronously, whether the message left:
|
|
22
|
+
* `POST /billing/notifications/email | push | sms`.
|
|
23
|
+
*
|
|
24
|
+
* Every limit here is a guard on a route that turns a request into outbound
|
|
25
|
+
* traffic on somebody's behalf, not a tuning choice.
|
|
26
|
+
*/
|
|
27
|
+
/** No line breaks: the value is placed in a header (Subject) or a filename. */
|
|
28
|
+
const SINGLE_LINE = /^[^\r\n]*$/;
|
|
29
|
+
/** A bare file name - no directory part, so it can never be read as a path. */
|
|
30
|
+
const FILE_NAME = /^[^\\/\r\n\0]+$/;
|
|
31
|
+
const HTTPS_ONLY = { protocols: ['https'], require_protocol: true };
|
|
32
|
+
const toArray = ({ value }) => (value === undefined || value === null || Array.isArray(value) ? value : [value]);
|
|
33
|
+
class BillingDocumentReferenceDto {
|
|
34
|
+
}
|
|
35
|
+
exports.BillingDocumentReferenceDto = BillingDocumentReferenceDto;
|
|
36
|
+
__decorate([
|
|
37
|
+
(0, swagger_1.ApiProperty)({ description: 'The clarion-dms document id.' }),
|
|
38
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
39
|
+
(0, class_validator_1.IsInt)(),
|
|
40
|
+
(0, class_validator_1.IsPositive)(),
|
|
41
|
+
__metadata("design:type", Number)
|
|
42
|
+
], BillingDocumentReferenceDto.prototype, "documentId", void 0);
|
|
43
|
+
__decorate([
|
|
44
|
+
(0, swagger_1.ApiProperty)({ enum: billing_notification_enum_1.BillingDocumentType }),
|
|
45
|
+
(0, class_validator_1.IsEnum)(billing_notification_enum_1.BillingDocumentType),
|
|
46
|
+
__metadata("design:type", String)
|
|
47
|
+
], BillingDocumentReferenceDto.prototype, "documentType", void 0);
|
|
48
|
+
__decorate([
|
|
49
|
+
(0, swagger_1.ApiPropertyOptional)({ example: 'INV-2026-000123.pdf' }),
|
|
50
|
+
(0, class_validator_1.IsString)(),
|
|
51
|
+
(0, class_validator_1.MaxLength)(150),
|
|
52
|
+
(0, class_validator_1.Matches)(FILE_NAME, { message: 'fileName must be a bare file name' }),
|
|
53
|
+
(0, class_validator_1.IsOptional)(),
|
|
54
|
+
__metadata("design:type", String)
|
|
55
|
+
], BillingDocumentReferenceDto.prototype, "fileName", void 0);
|
|
56
|
+
__decorate([
|
|
57
|
+
(0, swagger_1.ApiPropertyOptional)({
|
|
58
|
+
description: 'A pre-signed URL for the document. WITH it the PDF is fetched and attached; WITHOUT it the document ' +
|
|
59
|
+
'is only named in the email. Billing documents are private and their signed URLs expire within the hour, ' +
|
|
60
|
+
'so the URL is never placed in the email itself.',
|
|
61
|
+
}),
|
|
62
|
+
(0, class_validator_1.IsUrl)(HTTPS_ONLY),
|
|
63
|
+
(0, class_validator_1.MaxLength)(2048),
|
|
64
|
+
(0, class_validator_1.IsOptional)(),
|
|
65
|
+
__metadata("design:type", String)
|
|
66
|
+
], BillingDocumentReferenceDto.prototype, "signedUrl", void 0);
|
|
67
|
+
/** @deprecated Raw attachments. Prefer `documents`. */
|
|
68
|
+
class BillingEmailAttachmentDto {
|
|
69
|
+
}
|
|
70
|
+
exports.BillingEmailAttachmentDto = BillingEmailAttachmentDto;
|
|
71
|
+
__decorate([
|
|
72
|
+
(0, swagger_1.ApiProperty)(),
|
|
73
|
+
(0, class_validator_1.IsString)(),
|
|
74
|
+
(0, class_validator_1.MaxLength)(150),
|
|
75
|
+
(0, class_validator_1.Matches)(FILE_NAME, { message: 'filename must be a bare file name' }),
|
|
76
|
+
__metadata("design:type", String)
|
|
77
|
+
], BillingEmailAttachmentDto.prototype, "filename", void 0);
|
|
78
|
+
__decorate([
|
|
79
|
+
(0, swagger_1.ApiPropertyOptional)(),
|
|
80
|
+
(0, class_validator_1.IsUrl)(HTTPS_ONLY),
|
|
81
|
+
(0, class_validator_1.MaxLength)(2048),
|
|
82
|
+
(0, class_validator_1.IsOptional)(),
|
|
83
|
+
__metadata("design:type", String)
|
|
84
|
+
], BillingEmailAttachmentDto.prototype, "url", void 0);
|
|
85
|
+
__decorate([
|
|
86
|
+
(0, swagger_1.ApiPropertyOptional)({ description: 'Base64. About 10 MB of file at most.' }),
|
|
87
|
+
(0, class_validator_1.IsBase64)(),
|
|
88
|
+
(0, class_validator_1.MaxLength)(14000000),
|
|
89
|
+
(0, class_validator_1.IsOptional)(),
|
|
90
|
+
__metadata("design:type", String)
|
|
91
|
+
], BillingEmailAttachmentDto.prototype, "content", void 0);
|
|
92
|
+
class BillingEmailNotificationDto {
|
|
93
|
+
}
|
|
94
|
+
exports.BillingEmailNotificationDto = BillingEmailNotificationDto;
|
|
95
|
+
__decorate([
|
|
96
|
+
(0, swagger_1.ApiProperty)({ type: [String], description: 'One address or several. Each recipient gets an individual email.' }),
|
|
97
|
+
(0, class_transformer_1.Transform)(toArray),
|
|
98
|
+
(0, class_validator_1.IsArray)(),
|
|
99
|
+
(0, class_validator_1.ArrayMinSize)(1),
|
|
100
|
+
(0, class_validator_1.ArrayMaxSize)(50),
|
|
101
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
102
|
+
(0, class_validator_1.IsEmail)({}, { each: true }),
|
|
103
|
+
__metadata("design:type", Array)
|
|
104
|
+
], BillingEmailNotificationDto.prototype, "to", void 0);
|
|
105
|
+
__decorate([
|
|
106
|
+
(0, swagger_1.ApiProperty)(),
|
|
107
|
+
(0, class_validator_1.IsString)(),
|
|
108
|
+
(0, class_validator_1.MinLength)(1),
|
|
109
|
+
(0, class_validator_1.MaxLength)(200),
|
|
110
|
+
(0, class_validator_1.Matches)(SINGLE_LINE, { message: 'subject may not contain line breaks' }),
|
|
111
|
+
__metadata("design:type", String)
|
|
112
|
+
], BillingEmailNotificationDto.prototype, "subject", void 0);
|
|
113
|
+
__decorate([
|
|
114
|
+
(0, swagger_1.ApiProperty)({ enum: billing_notification_enum_1.BillingEmailTemplate }),
|
|
115
|
+
(0, class_validator_1.IsEnum)(billing_notification_enum_1.BillingEmailTemplate),
|
|
116
|
+
__metadata("design:type", String)
|
|
117
|
+
], BillingEmailNotificationDto.prototype, "template", void 0);
|
|
118
|
+
__decorate([
|
|
119
|
+
(0, swagger_1.ApiPropertyOptional)({
|
|
120
|
+
description: 'The organization the email is sent on behalf of: decides the branding and the From address.',
|
|
121
|
+
}),
|
|
122
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
123
|
+
(0, class_validator_1.IsInt)(),
|
|
124
|
+
(0, class_validator_1.IsPositive)(),
|
|
125
|
+
(0, class_validator_1.IsOptional)(),
|
|
126
|
+
__metadata("design:type", Number)
|
|
127
|
+
], BillingEmailNotificationDto.prototype, "organizationId", void 0);
|
|
128
|
+
__decorate([
|
|
129
|
+
(0, swagger_1.ApiProperty)({ description: 'See BillingEmailTemplateData.' }),
|
|
130
|
+
(0, class_validator_1.IsObject)(),
|
|
131
|
+
__metadata("design:type", Object)
|
|
132
|
+
], BillingEmailNotificationDto.prototype, "data", void 0);
|
|
133
|
+
__decorate([
|
|
134
|
+
(0, swagger_1.ApiPropertyOptional)({ type: [BillingDocumentReferenceDto] }),
|
|
135
|
+
(0, class_validator_1.IsArray)(),
|
|
136
|
+
(0, class_validator_1.ArrayMaxSize)(10),
|
|
137
|
+
(0, class_validator_1.ValidateNested)({ each: true }),
|
|
138
|
+
(0, class_transformer_1.Type)(() => BillingDocumentReferenceDto),
|
|
139
|
+
(0, class_validator_1.IsOptional)(),
|
|
140
|
+
__metadata("design:type", Array)
|
|
141
|
+
], BillingEmailNotificationDto.prototype, "documents", void 0);
|
|
142
|
+
__decorate([
|
|
143
|
+
(0, swagger_1.ApiPropertyOptional)({ type: [BillingEmailAttachmentDto], deprecated: true }),
|
|
144
|
+
(0, class_validator_1.IsArray)(),
|
|
145
|
+
(0, class_validator_1.ArrayMaxSize)(10),
|
|
146
|
+
(0, class_validator_1.ValidateNested)({ each: true }),
|
|
147
|
+
(0, class_transformer_1.Type)(() => BillingEmailAttachmentDto),
|
|
148
|
+
(0, class_validator_1.IsOptional)(),
|
|
149
|
+
__metadata("design:type", Array)
|
|
150
|
+
], BillingEmailNotificationDto.prototype, "attachments", void 0);
|
|
151
|
+
class BillingPushNotificationDto {
|
|
152
|
+
}
|
|
153
|
+
exports.BillingPushNotificationDto = BillingPushNotificationDto;
|
|
154
|
+
__decorate([
|
|
155
|
+
(0, swagger_1.ApiProperty)({ type: [Number] }),
|
|
156
|
+
(0, class_validator_1.IsArray)(),
|
|
157
|
+
(0, class_validator_1.ArrayMinSize)(1),
|
|
158
|
+
(0, class_validator_1.ArrayMaxSize)(500),
|
|
159
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
160
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
161
|
+
(0, class_validator_1.IsInt)({ each: true }),
|
|
162
|
+
(0, class_validator_1.IsPositive)({ each: true }),
|
|
163
|
+
__metadata("design:type", Array)
|
|
164
|
+
], BillingPushNotificationDto.prototype, "userIds", void 0);
|
|
165
|
+
__decorate([
|
|
166
|
+
(0, swagger_1.ApiProperty)(),
|
|
167
|
+
(0, class_validator_1.IsString)(),
|
|
168
|
+
(0, class_validator_1.MinLength)(1),
|
|
169
|
+
(0, class_validator_1.MaxLength)(120),
|
|
170
|
+
__metadata("design:type", String)
|
|
171
|
+
], BillingPushNotificationDto.prototype, "title", void 0);
|
|
172
|
+
__decorate([
|
|
173
|
+
(0, swagger_1.ApiProperty)(),
|
|
174
|
+
(0, class_validator_1.IsString)(),
|
|
175
|
+
(0, class_validator_1.MinLength)(1),
|
|
176
|
+
(0, class_validator_1.MaxLength)(500),
|
|
177
|
+
__metadata("design:type", String)
|
|
178
|
+
], BillingPushNotificationDto.prototype, "body", void 0);
|
|
179
|
+
__decorate([
|
|
180
|
+
(0, swagger_1.ApiPropertyOptional)({ description: 'Delivered to the app as FCM data; non-string values are JSON-encoded.' }),
|
|
181
|
+
(0, class_validator_1.IsObject)(),
|
|
182
|
+
(0, class_validator_1.IsOptional)(),
|
|
183
|
+
__metadata("design:type", Object)
|
|
184
|
+
], BillingPushNotificationDto.prototype, "data", void 0);
|
|
185
|
+
class BillingSmsNotificationDto {
|
|
186
|
+
}
|
|
187
|
+
exports.BillingSmsNotificationDto = BillingSmsNotificationDto;
|
|
188
|
+
__decorate([
|
|
189
|
+
(0, swagger_1.ApiProperty)({ type: [String], description: 'E.164, or local numbers of a supported country.' }),
|
|
190
|
+
(0, class_validator_1.IsArray)(),
|
|
191
|
+
(0, class_validator_1.ArrayMinSize)(1),
|
|
192
|
+
(0, class_validator_1.ArrayMaxSize)(100),
|
|
193
|
+
(0, class_validator_1.ArrayUnique)(),
|
|
194
|
+
(0, class_validator_1.IsString)({ each: true }),
|
|
195
|
+
(0, class_validator_1.MaxLength)(20, { each: true }),
|
|
196
|
+
__metadata("design:type", Array)
|
|
197
|
+
], BillingSmsNotificationDto.prototype, "phoneNumbers", void 0);
|
|
198
|
+
__decorate([
|
|
199
|
+
(0, swagger_1.ApiProperty)({ description: 'At most 1000 characters (about six SMS segments).' }),
|
|
200
|
+
(0, class_validator_1.IsString)(),
|
|
201
|
+
(0, class_validator_1.MinLength)(1),
|
|
202
|
+
(0, class_validator_1.MaxLength)(1000),
|
|
203
|
+
__metadata("design:type", String)
|
|
204
|
+
], BillingSmsNotificationDto.prototype, "message", void 0);
|
|
205
|
+
__decorate([
|
|
206
|
+
(0, swagger_1.ApiPropertyOptional)({ description: 'Decides the sender ID the SMS arrives under.' }),
|
|
207
|
+
(0, class_transformer_1.Type)(() => Number),
|
|
208
|
+
(0, class_validator_1.IsInt)(),
|
|
209
|
+
(0, class_validator_1.IsPositive)(),
|
|
210
|
+
(0, class_validator_1.IsOptional)(),
|
|
211
|
+
__metadata("design:type", Number)
|
|
212
|
+
], BillingSmsNotificationDto.prototype, "organizationId", void 0);
|
|
213
|
+
//# sourceMappingURL=billing-notification.dto.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"billing-notification.dto.js","sourceRoot":"","sources":["../../../../../src/modules/notification/dtos/billing-notification.dto.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAAmE;AACnE,yDAAoD;AACpD,q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