From 572a4c3eacbc09139e185161eca0e283c3f50030 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Tue, 12 Sep 2023 16:48:04 +0300 Subject: [PATCH 01/10] feat: Add Custom SMS provider --- .../images/providers/dark/custom-sms.svg | 1 + .../images/providers/light/custom-sms.svg | 1 + .../src/consts/providers/channels/sms.ts | 9 + .../credentials/provider-credentials.ts | 27 + .../src/consts/providers/provider.enum.ts | 1 + novu.code-workspace | 4 + packages/application-generic/package.json | 3 +- .../sms/handlers/custom-sms.handler.ts | 18 + .../src/factories/sms/handlers/index.ts | 1 + .../src/factories/sms/sms.factory.ts | 2 + pnpm-lock.yaml | 822 +++++++++--------- providers/custom-sms/.czrc | 3 + providers/custom-sms/.eslintrc.json | 3 + providers/custom-sms/.gitignore | 9 + providers/custom-sms/README.md | 9 + providers/custom-sms/jest.config.js | 5 + providers/custom-sms/package.json | 82 ++ providers/custom-sms/src/index.ts | 1 + .../src/lib/custom-sms.provider.spec.ts | 3 + .../custom-sms/src/lib/custom-sms.provider.ts | 47 + providers/custom-sms/tsconfig.json | 10 + providers/custom-sms/tsconfig.module.json | 9 + 22 files changed, 665 insertions(+), 405 deletions(-) create mode 100644 apps/web/public/static/images/providers/dark/custom-sms.svg create mode 100644 apps/web/public/static/images/providers/light/custom-sms.svg create mode 100644 packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts create mode 100644 providers/custom-sms/.czrc create mode 100644 providers/custom-sms/.eslintrc.json create mode 100644 providers/custom-sms/.gitignore create mode 100644 providers/custom-sms/README.md create mode 100644 providers/custom-sms/jest.config.js create mode 100644 providers/custom-sms/package.json create mode 100644 providers/custom-sms/src/index.ts create mode 100644 providers/custom-sms/src/lib/custom-sms.provider.spec.ts create mode 100644 providers/custom-sms/src/lib/custom-sms.provider.ts create mode 100644 providers/custom-sms/tsconfig.json create mode 100644 providers/custom-sms/tsconfig.module.json diff --git a/apps/web/public/static/images/providers/dark/custom-sms.svg b/apps/web/public/static/images/providers/dark/custom-sms.svg new file mode 100644 index 00000000000..87e11a06f5d --- /dev/null +++ b/apps/web/public/static/images/providers/dark/custom-sms.svg @@ -0,0 +1 @@ + diff --git a/apps/web/public/static/images/providers/light/custom-sms.svg b/apps/web/public/static/images/providers/light/custom-sms.svg new file mode 100644 index 00000000000..f22ac13d527 --- /dev/null +++ b/apps/web/public/static/images/providers/light/custom-sms.svg @@ -0,0 +1 @@ + diff --git a/libs/shared/src/consts/providers/channels/sms.ts b/libs/shared/src/consts/providers/channels/sms.ts index 58d47781434..fc61af82e5d 100644 --- a/libs/shared/src/consts/providers/channels/sms.ts +++ b/libs/shared/src/consts/providers/channels/sms.ts @@ -18,6 +18,7 @@ import { termiiConfig, africasTalkingConfig, sendchampConfig, + customSmsConfig, } from '../credentials'; import { SmsProviderIdEnum } from '../provider.enum'; @@ -179,4 +180,12 @@ export const smsProviders: IProviderConfig[] = [ docReference: 'https://sendchamp.readme.io/reference/api-structure', logoFileName: { light: 'sendchamp.svg', dark: 'sendchamp.svg' }, }, + { + id: SmsProviderIdEnum.CustomSms, + displayName: `Custom SMS`, + channel: ChannelTypeEnum.SMS, + credentials: customSmsConfig, + docReference: '', + logoFileName: { light: 'custom-sms.svg', dark: 'custom-sms.svg' }, + }, ]; diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index 7df6a940ace..658fc6d96f7 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -740,3 +740,30 @@ export const sendchampConfig: IConfigCredentials[] = [ }, ...smsConfigBase, ]; + +export const customSmsConfig: IConfigCredentials[] = [ + { + key: CredentialsKeyEnum.BaseUrl, + displayName: 'Base URL', + type: 'string', + required: true, + }, + { + key: CredentialsKeyEnum.ApiKey, + displayName: 'API Key', + type: 'string', + required: true, + }, + { + key: CredentialsKeyEnum.SecretKey, + displayName: 'Secret Key', + type: 'string', + required: false, + }, + { + key: CredentialsKeyEnum.From, + displayName: 'From', + type: 'string', + required: false, + }, +]; diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index 2c763afc11d..a24dce05f87 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -71,6 +71,7 @@ export enum SmsProviderIdEnum { AfricasTalking = 'africas-talking', Novu = 'novu-sms', Sendchamp = 'sendchamp', + CustomSms = 'custom-sms', } export enum ChatProviderIdEnum { diff --git a/novu.code-workspace b/novu.code-workspace index 02266d66a9f..403696c7217 100644 --- a/novu.code-workspace +++ b/novu.code-workspace @@ -179,6 +179,10 @@ { "name": "🔔 @novu/maqsam", "path": "providers/maqsam" + }, + { + "name": "🔔 @novu/custom-sms", + "path": "providers/custom-sms" } ], "settings": { diff --git a/packages/application-generic/package.json b/packages/application-generic/package.json index 7629b5c35d8..a8f57d5b5a2 100644 --- a/packages/application-generic/package.json +++ b/packages/application-generic/package.json @@ -35,10 +35,10 @@ "peerDependencies": { "@nestjs/common": ">=10", "@nestjs/core": ">=10", + "@nestjs/jwt": "^10.1.0", "@nestjs/swagger": ">=6", "@nestjs/terminus": ">=10", "@nestjs/testing": ">=10", - "@nestjs/jwt": "^10.1.0", "newrelic": "^9", "reflect-metadata": "^0.1.13" }, @@ -51,6 +51,7 @@ "@novu/apns": "^0.19.0", "@novu/burst-sms": "^0.19.0", "@novu/clickatell": "^0.19.0", + "@novu/custom-sms": "^0.19.0", "@novu/dal": "^0.19.0", "@novu/discord": "^0.19.0", "@novu/email-webhook": "^0.19.0", diff --git a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts new file mode 100644 index 00000000000..e0b0d5c6388 --- /dev/null +++ b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts @@ -0,0 +1,18 @@ +import { CustomSmsProvider } from '@novu/custom-sms'; +import { ChannelTypeEnum, ICredentials } from '@novu/shared'; +import { BaseSmsHandler } from './base.handler'; + +export class CustomSmsHandler extends BaseSmsHandler { + constructor() { + super('custom-sms', ChannelTypeEnum.SMS); + } + + buildProvider(credentials: ICredentials) { + this.provider = new CustomSmsProvider({ + baseUrl: credentials.baseUrl, + apiKey: credentials.apiKey, + secretKey: credentials.secretKey, + from: credentials.from, + }); + } +} diff --git a/packages/application-generic/src/factories/sms/handlers/index.ts b/packages/application-generic/src/factories/sms/handlers/index.ts index bcf0d2a6a6f..e5fb2232b78 100644 --- a/packages/application-generic/src/factories/sms/handlers/index.ts +++ b/packages/application-generic/src/factories/sms/handlers/index.ts @@ -16,3 +16,4 @@ export * from './sms-central.handler'; export * from './africas-talking.handler'; export * from './sendchamp.handler'; export * from './novu.handler'; +export * from './custom-sms.handler'; diff --git a/packages/application-generic/src/factories/sms/sms.factory.ts b/packages/application-generic/src/factories/sms/sms.factory.ts index 18cb55416be..111336a461e 100644 --- a/packages/application-generic/src/factories/sms/sms.factory.ts +++ b/packages/application-generic/src/factories/sms/sms.factory.ts @@ -19,6 +19,7 @@ import { AfricasTalkingSmsHandler, SendchampSmsHandler, NovuSmsHandler, + CustomSmsHandler, } from './handlers'; export class SmsFactory implements ISmsFactory { @@ -41,6 +42,7 @@ export class SmsFactory implements ISmsFactory { new AfricasTalkingSmsHandler(), new SendchampSmsHandler(), new NovuSmsHandler(), + new CustomSmsHandler(), ]; getHandler(integration: IntegrationEntity) { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 36604f72a1a..dc9d78b8cac 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -394,7 +394,7 @@ importers: nodemon: 2.0.22 prettier: 2.8.7 sinon: 9.2.4 - ts-jest: 27.1.5_cnngzrja2umb46xxazlucyx2qu + ts-jest: 27.1.5_4aafjbpmnrfjtrzkyohogv4jce ts-loader: 9.4.2_rggdtlzfqxxwxudp3onsqdyocm ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna tsconfig-paths: 4.1.2 @@ -1152,84 +1152,6 @@ importers: stylelint-scss: 4.6.0_stylelint@15.10.1 typescript: 4.9.5 - enterprise/packages/auth: - specifiers: - '@nestjs/common': '>=9.3.x' - '@nestjs/jwt': '>=9' - '@nestjs/passport': 9.0.3 - '@novu/application-generic': ^0.19.0 - '@novu/dal': ^0.19.0 - '@novu/shared': ^0.19.0 - '@types/chai': ^4.2.11 - '@types/mocha': ^8.0.1 - '@types/node': ^14.6.0 - '@types/sinon': ^9.0.0 - chai: ^4.2.0 - cross-env: ^7.0.3 - mocha: ^8.1.1 - nodemon: ^2.0.3 - passport: 0.6.0 - passport-google-oauth: ^2.0.0 - passport-oauth2: ^1.6.1 - sinon: ^9.2.4 - ts-node: ~10.9.1 - typescript: 4.9.5 - dependencies: - '@nestjs/common': 10.2.2_atc7tu2sld2m3nk4hmwkqn6qde - '@nestjs/jwt': 10.1.0_@nestjs+common@10.2.2 - '@nestjs/passport': 9.0.3_kn4ljbedllcoqpuu4ifhphsdsu - '@novu/application-generic': link:../../../packages/application-generic - '@novu/dal': link:../../../libs/dal - '@novu/shared': link:../../../libs/shared - passport: 0.6.0 - passport-google-oauth: 2.0.0 - passport-oauth2: 1.7.0 - devDependencies: - '@types/chai': 4.3.4 - '@types/mocha': 8.2.3 - '@types/node': 14.18.42 - '@types/sinon': 9.0.11 - chai: 4.3.7 - cross-env: 7.0.3 - mocha: 8.4.0 - nodemon: 2.0.22 - sinon: 9.2.4 - ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna - typescript: 4.9.5 - - enterprise/packages/digest-schedule: - specifiers: - '@novu/shared': ^0.19.0 - '@types/chai': ^4.2.11 - '@types/mocha': ^8.0.1 - '@types/node': ^14.6.0 - '@types/sinon': ^9.0.0 - chai: ^4.2.0 - cross-env: ^7.0.3 - date-fns: ^2.29.2 - mocha: ^8.1.1 - nodemon: ^2.0.3 - rrule: ^2.7.2 - sinon: ^9.2.4 - ts-node: ~10.9.1 - typescript: 4.9.5 - dependencies: - '@novu/shared': link:../../../libs/shared - date-fns: 2.29.3 - rrule: 2.7.2 - devDependencies: - '@types/chai': 4.3.4 - '@types/mocha': 8.2.3 - '@types/node': 14.18.42 - '@types/sinon': 9.0.11 - chai: 4.3.7 - cross-env: 7.0.3 - mocha: 8.4.0 - nodemon: 2.0.22 - sinon: 9.2.4 - ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna - typescript: 4.9.5 - libs/dal: specifiers: '@aws-sdk/client-s3': ^3.382.0 @@ -1487,6 +1409,7 @@ importers: '@novu/apns': ^0.19.0 '@novu/burst-sms': ^0.19.0 '@novu/clickatell': ^0.19.0 + '@novu/custom-sms': ^0.19.0 '@novu/dal': ^0.19.0 '@novu/discord': ^0.19.0 '@novu/email-webhook': ^0.19.0 @@ -1578,6 +1501,7 @@ importers: '@novu/apns': link:../../providers/apns '@novu/burst-sms': link:../../providers/burst-sms '@novu/clickatell': link:../../providers/clickatell + '@novu/custom-sms': link:../../providers/custom-sms '@novu/dal': link:../../libs/dal '@novu/discord': link:../../providers/discord '@novu/email-webhook': link:../../providers/email-webhook @@ -2231,6 +2155,37 @@ importers: typedoc: 0.24.6_typescript@4.9.5 typescript: 4.9.5 + providers/custom-sms: + specifiers: + '@istanbuljs/nyc-config-typescript': ~1.0.1 + '@novu/stateless': 0.16.3 + '@types/jest': ~27.5.2 + axios: ^1.5.0 + cspell: ~6.19.2 + jest: ~27.5.1 + npm-run-all: ^4.1.5 + nyc: ~15.1.0 + prettier: ~2.8.0 + rimraf: ~3.0.2 + ts-jest: ~27.1.5 + ts-node: ~10.9.1 + typescript: 4.9.5 + dependencies: + '@novu/stateless': 0.16.3 + axios: 1.5.0 + devDependencies: + '@istanbuljs/nyc-config-typescript': 1.0.2_nyc@15.1.0 + '@types/jest': 27.5.2 + cspell: 6.19.2 + jest: 27.5.1_ts-node@10.9.1 + npm-run-all: 4.1.5 + nyc: 15.1.0 + prettier: 2.8.7 + rimraf: 3.0.2 + ts-jest: 27.1.5_tdguimvmawsauzyxxfukpkg77i + ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna + typescript: 4.9.5 + providers/discord: specifiers: '@istanbuljs/nyc-config-typescript': ^1.0.1 @@ -6331,13 +6286,13 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/generator': 7.21.4 - '@babel/helper-module-transforms': 7.21.2 - '@babel/helpers': 7.21.0 - '@babel/parser': 7.21.4 - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/generator': 7.22.10 + '@babel/helper-module-transforms': 7.22.9_@babel+core@7.12.9 + '@babel/helpers': 7.22.11 + '@babel/parser': 7.22.14 + '@babel/template': 7.22.5 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 convert-source-map: 1.9.0 debug: 4.3.4 gensync: 1.0.0-beta.2 @@ -6378,14 +6333,14 @@ packages: dependencies: '@ampproject/remapping': 2.2.1 '@babel/code-frame': 7.22.13 - '@babel/generator': 7.21.4 + '@babel/generator': 7.22.10 '@babel/helper-compilation-targets': 7.21.4_@babel+core@7.20.12 '@babel/helper-module-transforms': 7.21.2 '@babel/helpers': 7.21.0 '@babel/parser': 7.21.4 '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 convert-source-map: 1.9.0 debug: 4.3.4 gensync: 1.0.0-beta.2 @@ -6456,7 +6411,7 @@ packages: resolution: {integrity: sha512-AEmuXHdcD3A52HHXxaTmYlb8q/xMEhoRP67B3T4Oq7lbmSoqroMZzjnGj3+i1io3pdnF8iBYVu4Ilj+c4hBxYg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 '@jridgewell/gen-mapping': 0.3.3 jsesc: 2.5.2 dev: true @@ -6465,7 +6420,7 @@ packages: resolution: {integrity: sha512-NieM3pVIYW2SwGzKoqfPrQsf4xGs9M9AIG3ThppsSRmO+m7eQhmI6amajKMUeIO37wFfsvnvcxQFx6x6iqxDnA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 '@jridgewell/gen-mapping': 0.3.3 '@jridgewell/trace-mapping': 0.3.19 jsesc: 2.5.2 @@ -6483,7 +6438,7 @@ packages: resolution: {integrity: sha512-duORpUiYrEpzKIop6iNbjnwKLAKnJ47csTyRACyEmWj0QdUrm5aqNJGHSSEQSUAvNW0ojX0dOmK9dZduvkfeXA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-annotate-as-pure/7.22.5: resolution: {integrity: sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==} @@ -6496,7 +6451,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/helper-explode-assignable-expression': 7.18.6 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-compilation-targets/7.21.4_@babel+core@7.19.3: resolution: {integrity: sha512-Fa0tTuOXZ1iL8IeDFUWCzjZcn+sJGd9RZdH9esYVjEejGmzf+FFYQpMi/kZUk2kPy/q1H3/GPw7np8qar/stfg==} @@ -6648,16 +6603,16 @@ packages: '@babel/helper-annotate-as-pure': 7.18.6 regexpu-core: 5.3.2 - /@babel/helper-define-polyfill-provider/0.1.5_@babel+core@7.21.4: + /@babel/helper-define-polyfill-provider/0.1.5_@babel+core@7.22.11: resolution: {integrity: sha512-nXuzCSwlJ/WKr8qxzW816gwyT6VZgiJG17zR40fou70yfAcqjoNyTLl/DQ+FExw5Hx5KNqshmN8Ldl/r2N7cTg==} peerDependencies: '@babel/core': ^7.4.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-compilation-targets': 7.21.4_@babel+core@7.21.4 - '@babel/helper-module-imports': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 - '@babel/traverse': 7.21.4 + '@babel/core': 7.22.11 + '@babel/helper-compilation-targets': 7.22.10 + '@babel/helper-module-imports': 7.22.5 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/traverse': 7.22.11 debug: 4.3.4 lodash.debounce: 4.0.8 resolve: 1.22.2 @@ -6671,7 +6626,7 @@ packages: '@babel/core': ^7.4.0-0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-compilation-targets': 7.21.4_@babel+core@7.20.12 + '@babel/helper-compilation-targets': 7.22.10 '@babel/helper-plugin-utils': 7.20.2 debug: 4.3.4 lodash.debounce: 4.0.8 @@ -6687,7 +6642,7 @@ packages: '@babel/core': ^7.4.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-compilation-targets': 7.21.4_@babel+core@7.21.4 + '@babel/helper-compilation-targets': 7.22.10 '@babel/helper-plugin-utils': 7.20.2 debug: 4.3.4 lodash.debounce: 4.0.8 @@ -6702,7 +6657,7 @@ packages: '@babel/core': ^7.4.0-0 dependencies: '@babel/core': 7.22.11 - '@babel/helper-compilation-targets': 7.21.4_@babel+core@7.22.11 + '@babel/helper-compilation-targets': 7.22.10 '@babel/helper-plugin-utils': 7.20.2 debug: 4.3.4 lodash.debounce: 4.0.8 @@ -6723,14 +6678,14 @@ packages: resolution: {integrity: sha512-eyAYAsQmB80jNfg4baAtLeWAQHfHFiR483rzFK+BhETlGZaQC9bsfrugfXDCbRHLQbIA7U5NxhhOxN7p/dWIcg==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-function-name/7.21.0: resolution: {integrity: sha512-HfK1aMRanKHpxemaY2gqBmL04iAPOPRj7DxtNbiDOrJK+gdwkiNRVpCpUJYbUT+aZyemKN8brqTOxzCaG6ExRg==} engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.20.7 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-function-name/7.22.5: resolution: {integrity: sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==} @@ -6743,7 +6698,7 @@ packages: resolution: {integrity: sha512-UlJQPkFqFULIcyW5sbzgbkxn2FKRgwWiRexcuaR8RNJRy8+LLveqPjwZV/bwrLZCN0eUHD/x8D0heK1ozuoo6Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-hoist-variables/7.22.5: resolution: {integrity: sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==} @@ -6755,7 +6710,7 @@ packages: resolution: {integrity: sha512-Muu8cdZwNN6mRRNG6lAYErJ5X3bRevgYR2O8wN0yn7jJSnGDu6eG59RfT29JHxGUovyfrh6Pj0XzmR7drNVL3Q==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-module-imports/7.21.4: resolution: {integrity: sha512-orajc5T2PsRYUN3ZryCEFeMDYwyw09c/pZeaQEZPH0MpKzSvn3e0uXsDBu3k03VI+9DBiRo+l22BfKTpKwa/Wg==} @@ -6779,11 +6734,51 @@ packages: '@babel/helper-split-export-declaration': 7.18.6 '@babel/helper-validator-identifier': 7.19.1 '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color + /@babel/helper-module-transforms/7.22.9_@babel+core@7.12.9: + resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.12.9 + '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-module-imports': 7.22.5 + '@babel/helper-simple-access': 7.22.5 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/helper-validator-identifier': 7.22.5 + + /@babel/helper-module-transforms/7.22.9_@babel+core@7.20.12: + resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.20.12 + '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-module-imports': 7.22.5 + '@babel/helper-simple-access': 7.22.5 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/helper-validator-identifier': 7.22.5 + dev: true + + /@babel/helper-module-transforms/7.22.9_@babel+core@7.21.4: + resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.21.4 + '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-module-imports': 7.22.5 + '@babel/helper-simple-access': 7.22.5 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/helper-validator-identifier': 7.22.5 + /@babel/helper-module-transforms/7.22.9_@babel+core@7.22.11: resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} engines: {node: '>=6.9.0'} @@ -6801,7 +6796,7 @@ packages: resolution: {integrity: sha512-HP59oD9/fEHQkdcbgFCnbmgH5vIQTJbxh2yf+CdM89/glUNnuzr87Q8GIjGEnOktTROemO0Pe0iPAYbqZuOUiA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-plugin-utils/7.10.4: resolution: {integrity: sha512-O4KCvQA6lLiMU9l2eawBPMf1xPP8xPfB3iEQw150hOVTqj/rfXz0ThTb4HEzqQfs2Bmo5Ay8BzxfzVtBrr9dVg==} @@ -6824,7 +6819,7 @@ packages: '@babel/helper-annotate-as-pure': 7.18.6 '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-wrap-function': 7.20.5 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color dev: true @@ -6839,7 +6834,7 @@ packages: '@babel/helper-annotate-as-pure': 7.18.6 '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-wrap-function': 7.20.5 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color @@ -6853,7 +6848,7 @@ packages: '@babel/helper-annotate-as-pure': 7.18.6 '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-wrap-function': 7.20.5 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color @@ -6865,8 +6860,8 @@ packages: '@babel/helper-member-expression-to-functions': 7.21.0 '@babel/helper-optimise-call-expression': 7.18.6 '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color @@ -6874,7 +6869,7 @@ packages: resolution: {integrity: sha512-+0woI/WPq59IrqDYbVGfshjT5Dmk/nnbdpcF8SnMhhXObpTq2KNBdLFRFrkVdbDOyUmHBCxzm5FHV1rACIkIbA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-simple-access/7.22.5: resolution: {integrity: sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==} @@ -6892,7 +6887,7 @@ packages: resolution: {integrity: sha512-bde1etTx6ZyTmobl9LLMMQsaizFVZrquTEHOqKeQESMKo4PlObf+8+JA25ZsIpZhT/WEd39+vOdLXAFG/nELpA==} engines: {node: '>=6.9.0'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/helper-split-export-declaration/7.22.6: resolution: {integrity: sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==} @@ -6929,9 +6924,9 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/helper-function-name': 7.21.0 - '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/template': 7.22.5 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color @@ -6940,8 +6935,8 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/template': 7.20.7 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 transitivePeerDependencies: - supports-color @@ -6975,17 +6970,8 @@ packages: resolution: {integrity: sha512-alVJj7k7zIxqBZ7BTRhz0IqJFxW1VJbm6N8JbcYhQ186df9ZBPbZBmWSqAMXwHGsCJdYks7z/voa3ibiS5bCIw==} engines: {node: '>=6.0.0'} hasBin: true - dependencies: - '@babel/types': 7.21.4 - - /@babel/parser/7.22.13: - resolution: {integrity: sha512-3l6+4YOvc9wx7VlCSw4yQfcBo01ECA8TicQfbnCPuCEpRQrf+gTUyGdxNw+pyTUyywp6JRD1w0YQs9TpBXYlkw==} - engines: {node: '>=6.0.0'} - hasBin: true dependencies: '@babel/types': 7.22.11 - dev: false - optional: true /@babel/parser/7.22.14: resolution: {integrity: sha512-1KucTHgOvaw/LzCVrEOAyXkr9rQlp0A1HiHRYnSUE9dmb8PvPW7o5sscg+5169r54n3vGlbx6GevTE/Iw/P3AQ==} @@ -7191,6 +7177,21 @@ packages: transitivePeerDependencies: - supports-color + /@babel/plugin-proposal-decorators/7.21.0_@babel+core@7.22.11: + resolution: {integrity: sha512-MfgX49uRrFUTL/HvWtmx3zmpyzMMr4MTj3d527MLlr/4RTT9G/ytFFP7qet2uM2Ve03b+BkpWUpK+lRXnQ+v9w==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + '@babel/helper-create-class-features-plugin': 7.21.4_@babel+core@7.22.11 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-replace-supers': 7.20.7 + '@babel/helper-split-export-declaration': 7.22.6 + '@babel/plugin-syntax-decorators': 7.21.0_@babel+core@7.22.11 + transitivePeerDependencies: + - supports-color + /@babel/plugin-proposal-dynamic-import/7.18.6_@babel+core@7.20.12: resolution: {integrity: sha512-1auuwmK+Rz13SJj36R+jqFPMJWyKEDd7lLSdOj4oJK0UTgGueSAtkrCvz9ewmgyU/P941Rv2fQwZJN8s6QruXw==} engines: {node: '>=6.9.0'} @@ -7222,15 +7223,15 @@ packages: '@babel/helper-plugin-utils': 7.20.2 '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.22.11 - /@babel/plugin-proposal-export-default-from/7.18.10_@babel+core@7.21.4: + /@babel/plugin-proposal-export-default-from/7.18.10_@babel+core@7.22.11: resolution: {integrity: sha512-5H2N3R2aQFxkV4PIBUR/i7PUSwgTZjouJKzI8eKswfIjT0PhvzkPn0t0wIS5zn6maQuvtT0t1oHtMUz61LOuow==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 - '@babel/plugin-syntax-export-default-from': 7.18.6_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.22.5 + '@babel/plugin-syntax-export-default-from': 7.18.6_@babel+core@7.22.11 /@babel/plugin-proposal-export-namespace-from/7.18.9_@babel+core@7.20.12: resolution: {integrity: sha512-k1NtHyOMvlDDFeb9G5PhUXuGj8m/wiwojgQVEhJ/fsVsMCpLyOP4h0uGEjYJKrRI+EVPlb5Jk+Gt9P97lOGwtA==} @@ -7393,7 +7394,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.12.9 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.22.5 '@babel/plugin-syntax-object-rest-spread': 7.8.3_@babel+core@7.12.9 '@babel/plugin-transform-parameters': 7.21.3_@babel+core@7.12.9 @@ -7644,7 +7645,15 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-syntax-bigint/7.8.3_@babel+core@7.22.11: + resolution: {integrity: sha512-wnTnFlG+YxQm3vDxpGE57Pj0srRU4sHE/mDkt1qv2YJJSeUAec2ma4WLUnUPeKjyrfntVwe/N6dCXpU+zL3Npg==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-syntax-class-properties/7.12.13_@babel+core@7.20.12: resolution: {integrity: sha512-fm4idjKla0YahUNgFNLCB0qySdsoPiZP3iQE3rky0mBUtMZ23yDJ9SJdg6dXTSDnulOVqiF3Hgr9nbXvXTQZYA==} @@ -7708,6 +7717,15 @@ packages: '@babel/core': 7.21.4 '@babel/helper-plugin-utils': 7.20.2 + /@babel/plugin-syntax-decorators/7.21.0_@babel+core@7.22.11: + resolution: {integrity: sha512-tIoPpGBR8UuM4++ccWN3gifhVvQu7ZizuR1fklhRJrd5ewgbkUS+0KVFeWWxELtn18NTLoW32XV7zyOgIAiz+w==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.20.2 + /@babel/plugin-syntax-dynamic-import/7.8.3_@babel+core@7.20.12: resolution: {integrity: sha512-5gdGbFon+PszYzqs83S3E5mpi7/y/8M9eC90MRTZfduQOYW76ig6SOSPNe41IG5LoP3FGBn2N0RjVDSQiS94kQ==} peerDependencies: @@ -7733,14 +7751,14 @@ packages: '@babel/core': 7.22.11 '@babel/helper-plugin-utils': 7.20.2 - /@babel/plugin-syntax-export-default-from/7.18.6_@babel+core@7.21.4: + /@babel/plugin-syntax-export-default-from/7.18.6_@babel+core@7.22.11: resolution: {integrity: sha512-Kr//z3ujSVNx6E9z9ih5xXXMqK07VVTuqPmqGe6Mss/zW5XPeLZeSDZoP9ab/hT4wPKqAgjl2PnhPrcpk8Seew==} engines: {node: '>=6.9.0'} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-syntax-export-namespace-from/7.8.3_@babel+core@7.20.12: resolution: {integrity: sha512-MXf5laXo6c1IbEbegDmzGPwGNTsHZmEy6QGznu5Sh2UCWvueywb2ee+CCE4zQiZstxU9BMoQO9i6zUFSY0Kj0Q==} @@ -7829,7 +7847,15 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.22.5 + + /@babel/plugin-syntax-import-meta/7.10.4_@babel+core@7.22.11: + resolution: {integrity: sha512-Yqfm+XDx0+Prh3VSeEQCPU81yC+JWZ2pDPFSS4ZdpfZhp4MkFMaDC1UqseovEKwSUpnIL7+vK+Clp7bfh0iD7g==} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-syntax-json-strings/7.8.3_@babel+core@7.20.12: resolution: {integrity: sha512-lY6kdGpWHvjoe2vk4WrAapEuBR69EMxZl+RoGRhrFGNYVK8mOPAW8VfbT/ZgrFbXlDNiiaxQnAtgVCZ6jv30EA==} @@ -7862,7 +7888,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.12.9 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-syntax-jsx/7.21.4_@babel+core@7.21.4: resolution: {integrity: sha512-5hewiLct5OKyh6PLKEYaFclcqtIgCb6bmELouxjF6up5q3Sov7rOayW4RwhbaBL0dit8rA80GNfY+UuDp2mBbQ==} @@ -8112,7 +8138,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-plugin-utils': 7.20.2 + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-syntax-typescript/7.21.4_@babel+core@7.22.11: resolution: {integrity: sha512-xz0D39NvhQn4t4RNsHmDnnsaQizIlUkdtYvLs8La1BlfjQ6JEwxkJGeqJMW2tAXx+q6H+WFuUTXNdYVpEya0YA==} @@ -8121,8 +8147,7 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.22.11 - '@babel/helper-plugin-utils': 7.20.2 - dev: true + '@babel/helper-plugin-utils': 7.22.5 /@babel/plugin-transform-arrow-functions/7.20.7_@babel+core@7.20.12: resolution: {integrity: sha512-3poA5E7dzDomxj9WXWwuD6A5F3kc7VXwIJO+E+J8qtDtS+pXPAhrgEyh+9GBwBgPq1Z+bB+/JD60lp5jsN7JPQ==} @@ -8638,11 +8663,9 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-module-transforms': 7.22.9_@babel+core@7.20.12 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-simple-access': 7.20.2 - transitivePeerDependencies: - - supports-color dev: true /@babel/plugin-transform-modules-commonjs/7.21.2_@babel+core@7.21.4: @@ -8652,11 +8675,9 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-module-transforms': 7.22.9_@babel+core@7.21.4 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-simple-access': 7.20.2 - transitivePeerDependencies: - - supports-color /@babel/plugin-transform-modules-commonjs/7.21.2_@babel+core@7.22.11: resolution: {integrity: sha512-Cln+Yy04Gxua7iPdj6nOV96smLGjpElir5YwzF0LBPKoPlLDNJePNlrGGaybAJkd0zKRnOVXOgizSqPYMNYkzA==} @@ -8678,12 +8699,10 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-hoist-variables': 7.18.6 - '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-hoist-variables': 7.22.5 + '@babel/helper-module-transforms': 7.22.9_@babel+core@7.20.12 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-validator-identifier': 7.19.1 - transitivePeerDependencies: - - supports-color dev: true /@babel/plugin-transform-modules-systemjs/7.20.11_@babel+core@7.21.4: @@ -8693,12 +8712,10 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-hoist-variables': 7.18.6 - '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-hoist-variables': 7.22.5 + '@babel/helper-module-transforms': 7.22.9_@babel+core@7.21.4 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-validator-identifier': 7.19.1 - transitivePeerDependencies: - - supports-color /@babel/plugin-transform-modules-systemjs/7.20.11_@babel+core@7.22.11: resolution: {integrity: sha512-vVu5g9BPQKSFEmvt2TA4Da5N+QVS66EX21d8uoOihC+OCpUoGvzVsXeqFdtAEfVa5BILAeFt+U7yVmLbQnAJmw==} @@ -8956,7 +8973,6 @@ packages: dependencies: '@babel/core': 7.22.11 '@babel/plugin-transform-react-jsx': 7.21.0_@babel+core@7.22.11 - dev: true /@babel/plugin-transform-react-jsx/7.21.0_@babel+core@7.21.4: resolution: {integrity: sha512-6OAWljMvQrZjR2DaNhVfRz6dkCAVV+ymcLUmaf8bccGOHn2v5rHJK3tTpij0BuhdYWP4LLaqj5lwcdlpAAPuvg==} @@ -9016,7 +9032,6 @@ packages: '@babel/core': 7.22.11 '@babel/helper-annotate-as-pure': 7.18.6 '@babel/helper-plugin-utils': 7.20.2 - dev: true /@babel/plugin-transform-regenerator/7.20.5_@babel+core@7.20.12: resolution: {integrity: sha512-kW/oO7HPBtntbsahzQ0qSE3tFvkFwnbozz3NWFhLGqH75vLEg+sCGngLlhVkePlCs3Jv0dBBHDzCHxNiFAQKCQ==} @@ -9125,7 +9140,6 @@ packages: semver: 6.3.0 transitivePeerDependencies: - supports-color - dev: false /@babel/plugin-transform-shorthand-properties/7.18.6_@babel+core@7.20.12: resolution: {integrity: sha512-eCLXXJqv8okzg86ywZJbRn19YJHU4XUa55oz2wbHhaQVn/MM+XhukiT7SYqp/7o00dg52Rj51Ny+Ecw4oyoygw==} @@ -9297,7 +9311,6 @@ packages: '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.22.11 transitivePeerDependencies: - supports-color - dev: true /@babel/plugin-transform-unicode-escapes/7.18.10_@babel+core@7.20.12: resolution: {integrity: sha512-kKAdAI+YzPgGY/ftStBFXTI1LZFju38rYThnfMykS+IXy8BVx+res7s2fxf1l8I35DV2T97ezo6+SGrXz6B3iQ==} @@ -9442,7 +9455,7 @@ packages: '@babel/plugin-transform-unicode-escapes': 7.18.10_@babel+core@7.20.12 '@babel/plugin-transform-unicode-regex': 7.18.6_@babel+core@7.20.12 '@babel/preset-modules': 0.1.5_@babel+core@7.20.12 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 babel-plugin-polyfill-corejs2: 0.3.3_@babel+core@7.20.12 babel-plugin-polyfill-corejs3: 0.6.0_@babel+core@7.20.12 babel-plugin-polyfill-regenerator: 0.4.1_@babel+core@7.20.12 @@ -9698,7 +9711,6 @@ packages: '@babel/plugin-transform-react-jsx': 7.21.0_@babel+core@7.22.11 '@babel/plugin-transform-react-jsx-development': 7.18.6_@babel+core@7.22.11 '@babel/plugin-transform-react-pure-annotations': 7.18.6_@babel+core@7.22.11 - dev: true /@babel/preset-typescript/7.21.4_@babel+core@7.21.4: resolution: {integrity: sha512-sMLNWY37TCdRH/bJ6ZeeOH1nPuanED7Ai9Y/vH31IPqalioJ6ZNFUWONsakhv4r4n+I6gm5lmoE0olkgib/j/A==} @@ -9729,7 +9741,6 @@ packages: '@babel/plugin-transform-typescript': 7.21.3_@babel+core@7.22.11 transitivePeerDependencies: - supports-color - dev: true /@babel/register/7.21.0_@babel+core@7.21.4: resolution: {integrity: sha512-9nKsPmYDi5DidAqJaQooxIhsLJiNMkGr8ypQ8Uic7cIox7UCDsM7HuUGxdGT7mSDTYbqzIdsOWzfBton/YJrMw==} @@ -9743,6 +9754,20 @@ packages: make-dir: 2.1.0 pirates: 4.0.5 source-map-support: 0.5.21 + dev: true + + /@babel/register/7.21.0_@babel+core@7.22.11: + resolution: {integrity: sha512-9nKsPmYDi5DidAqJaQooxIhsLJiNMkGr8ypQ8Uic7cIox7UCDsM7HuUGxdGT7mSDTYbqzIdsOWzfBton/YJrMw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + clone-deep: 4.0.1 + find-cache-dir: 2.1.0 + make-dir: 2.1.0 + pirates: 4.0.5 + source-map-support: 0.5.21 /@babel/regjsgen/0.8.0: resolution: {integrity: sha512-x/rqGMdzj+fWZvCOYForTghzbtqPDZ5gPwaoNGHdgDfF2QA/XZbCBp4Moo5scrkAMPhB7z26XM/AaHuIJdgauA==} @@ -9785,7 +9810,7 @@ packages: dependencies: '@babel/code-frame': 7.22.13 '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@babel/template/7.22.5: resolution: {integrity: sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==} @@ -9800,13 +9825,13 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/generator': 7.21.4 + '@babel/generator': 7.22.10 '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-function-name': 7.21.0 '@babel/helper-hoist-variables': 7.18.6 '@babel/helper-split-export-declaration': 7.18.6 - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/parser': 7.22.14 + '@babel/types': 7.22.11 debug: 4.3.4 globals: 11.12.0 transitivePeerDependencies: @@ -9817,13 +9842,13 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/code-frame': 7.22.13 - '@babel/generator': 7.21.4 + '@babel/generator': 7.22.10 '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-function-name': 7.21.0 '@babel/helper-hoist-variables': 7.18.6 '@babel/helper-split-export-declaration': 7.18.6 - '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/parser': 7.22.14 + '@babel/types': 7.22.11 debug: 4.3.4_supports-color@5.5.0 globals: 11.12.0 transitivePeerDependencies: @@ -11297,7 +11322,7 @@ packages: react-dom: ^16.8.4 || ^17.0.0 dependencies: '@babel/parser': 7.21.4 - '@babel/traverse': 7.21.4 + '@babel/traverse': 7.22.11 '@docusaurus/logger': 2.3.1 '@docusaurus/utils': 2.3.1_@docusaurus+types@2.3.1 '@mdx-js/mdx': 1.6.22 @@ -11332,7 +11357,7 @@ packages: react-dom: ^16.8.4 || ^17.0.0 dependencies: '@babel/parser': 7.21.4 - '@babel/traverse': 7.21.4 + '@babel/traverse': 7.22.11 '@docusaurus/logger': 2.3.1 '@docusaurus/utils': 2.3.1 '@mdx-js/mdx': 1.6.22 @@ -13971,7 +13996,7 @@ packages: resolution: {integrity: sha512-E9JjhUgNzvuQ+vVAL21vlyfy12gP0GhazGgJC4h6qUt1jSdUXGWJ1wfu/X7Sd8etSgxV4ovT1pb9v5D6QW4XgA==} engines: {node: '>= 10.14.2'} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/types': 26.6.2 babel-plugin-istanbul: 6.1.1 chalk: 4.1.2 @@ -13993,7 +14018,7 @@ packages: resolution: {integrity: sha512-ipON6WtYgl/1329g5AIJVbUuEh0wZVbdpGwC99Jw4LwuoBNS95MVphU6zOeD9pDkon+LLbFL7lOQRapbB8SCHw==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/types': 27.5.1 babel-plugin-istanbul: 6.1.1 chalk: 4.1.2 @@ -14015,7 +14040,7 @@ packages: resolution: {integrity: sha512-8vbeZWqLJOvHaDfeMuoHITGKSz5qWc9u04lnWrQE3VyuSw604PzQM824ZeX9XSjUCeDiE3GuxZe5UKa8J61NQw==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/types': 29.5.0 '@jridgewell/trace-mapping': 0.3.19 babel-plugin-istanbul: 6.1.1 @@ -15230,26 +15255,6 @@ packages: - webpack-cli dev: true - /@nestjs/common/10.2.2_atc7tu2sld2m3nk4hmwkqn6qde: - resolution: {integrity: sha512-TCOJK2K4FDT3GxFfURjngnjBewS/hizKNFSLBXtX4TTQm0dVQOtESnnVdP14sEiPM6suuWlrGnXW9UDqItGWiQ==} - peerDependencies: - class-transformer: '*' - class-validator: '*' - reflect-metadata: ^0.1.12 - rxjs: ^7.1.0 - peerDependenciesMeta: - class-transformer: - optional: true - class-validator: - optional: true - dependencies: - iterare: 1.2.1 - reflect-metadata: 0.1.13 - rxjs: 7.8.1 - tslib: 2.6.2 - uid: 2.0.2 - dev: false - /@nestjs/common/10.2.2_j3td4gnlgk75ora6o6suo62byy: resolution: {integrity: sha512-TCOJK2K4FDT3GxFfURjngnjBewS/hizKNFSLBXtX4TTQm0dVQOtESnnVdP14sEiPM6suuWlrGnXW9UDqItGWiQ==} peerDependencies: @@ -15477,16 +15482,6 @@ packages: passport: 0.6.0 dev: false - /@nestjs/passport/9.0.3_kn4ljbedllcoqpuu4ifhphsdsu: - resolution: {integrity: sha512-HplSJaimEAz1IOZEu+pdJHHJhQyBOPAYWXYHfAPQvRqWtw4FJF1VXl1Qtk9dcXQX1eKytDtH+qBzNQc19GWNEg==} - peerDependencies: - '@nestjs/common': ^8.0.0 || ^9.0.0 - passport: ^0.4.0 || ^0.5.0 || ^0.6.0 - dependencies: - '@nestjs/common': 10.2.2_atc7tu2sld2m3nk4hmwkqn6qde - passport: 0.6.0 - dev: false - /@nestjs/platform-express/10.2.2_h33h3l6i5mruhsbo3bha6vy2fi: resolution: {integrity: sha512-g5AeXgPQrVm62JOl9FXk0w3Tq1tD4f6ouGikLYs/Aahy0q/Z2HNP9NjXZYpqcjHrpafPYnc3bfBuUwedKW1oHg==} peerDependencies: @@ -15861,6 +15856,15 @@ packages: lodash.merge: 4.6.2 dev: false + /@novu/stateless/0.16.3: + resolution: {integrity: sha512-9wrqUluSaR9rCdDp4oUWFBwsk6OSM4P+yMaEtFGHrGmSPMcspnvXQaQoARKakuUpCXFvQlPPJq5+yaicv4o/hA==} + engines: {node: '>=10'} + dependencies: + handlebars: 4.7.7 + lodash.get: 4.4.2 + lodash.merge: 4.6.2 + dev: false + /@novu/stateless/0.7.2: resolution: {integrity: sha512-hZPVjtdckROXF4WpcpUJGigA+7Nfz1mM5dIHwuDfh6MZ6cRGOgjQVq2TKhiOjHcu2umcKORem4cuyz47KoSA5w==} engines: {node: '>=10'} @@ -16264,19 +16268,19 @@ packages: /@nrwl/js/15.9.4_4gv7sflzg672lecw4yrl35xmly: resolution: {integrity: sha512-DMJ7qFf/nN5w1WZyxm9JaAPsdfAD+bjLJ8MKA6rtoHcMB3t/BtCZ8lsnsYRUJXFGwuY6aj71bQXQ6F+QQOJY4Q==} dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-runtime': 7.21.4_@babel+core@7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 - '@babel/preset-typescript': 7.21.4_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-runtime': 7.21.4_@babel+core@7.22.11 + '@babel/preset-env': 7.21.4_@babel+core@7.22.11 + '@babel/preset-typescript': 7.21.4_@babel+core@7.22.11 '@babel/runtime': 7.21.0 '@nrwl/devkit': 15.9.4_nx@15.9.2 '@nrwl/workspace': 15.9.4_@swc+core@1.3.49 '@phenomnomnominal/tsquery': 4.1.1_typescript@4.9.5 - babel-plugin-const-enum: 1.2.0_@babel+core@7.21.4 + babel-plugin-const-enum: 1.2.0_@babel+core@7.22.11 babel-plugin-macros: 2.8.0 - babel-plugin-transform-typescript-metadata: 0.3.2_@babel+core@7.21.4 + babel-plugin-transform-typescript-metadata: 0.3.2_@babel+core@7.22.11 chalk: 4.1.2 fast-glob: 3.2.7 fs-extra: 11.1.0 @@ -17833,7 +17837,7 @@ packages: engines: {node: '>=14'} dev: false - /@rollup/plugin-babel/5.3.1_b6cdhqm2xsfe2bpl424qdsl4ei: + /@rollup/plugin-babel/5.3.1_lnssqozl4dgplk3xebfs3yicbq: resolution: {integrity: sha512-WFfdLWU/xVWKeRQnKmIAQULUI7Il0gZnBIH/ZFO069wYIfPu+8zrfp/KMW0atmELoRDq8FbiP3VCss9MhCut7Q==} engines: {node: '>= 10.0.0'} peerDependencies: @@ -17844,7 +17848,7 @@ packages: '@types/babel__core': optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@babel/helper-module-imports': 7.21.4 '@rollup/pluginutils': 3.1.0_rollup@2.79.1 rollup: 2.79.1 @@ -20560,7 +20564,7 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@storybook/addons': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/api': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/channel-postmessage': 6.5.16 @@ -20580,7 +20584,7 @@ packages: '@types/node': 14.18.42 '@types/webpack': 4.41.33 autoprefixer: 9.8.8 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce case-sensitive-paths-webpack-plugin: 2.4.0 core-js: 3.30.0 css-loader: 3.6.0_webpack@4.46.0 @@ -20629,7 +20633,7 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@storybook/addons': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/api': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/channel-postmessage': 6.5.16 @@ -20649,7 +20653,7 @@ packages: '@types/node': 14.18.42 '@types/webpack': 4.41.33 autoprefixer: 9.8.8 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce case-sensitive-paths-webpack-plugin: 2.4.0 core-js: 3.30.0 css-loader: 3.6.0_webpack@4.46.0 @@ -20952,35 +20956,35 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-proposal-export-default-from': 7.18.10_@babel+core@7.21.4 - '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-object-rest-spread': 7.20.7_@babel+core@7.21.4 - '@babel/plugin-proposal-optional-chaining': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-proposal-private-methods': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-private-property-in-object': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.21.4 - '@babel/plugin-transform-arrow-functions': 7.20.7_@babel+core@7.21.4 - '@babel/plugin-transform-block-scoping': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-classes': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-destructuring': 7.21.3_@babel+core@7.21.4 - '@babel/plugin-transform-for-of': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-parameters': 7.21.3_@babel+core@7.21.4 - '@babel/plugin-transform-shorthand-properties': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-transform-spread': 7.20.7_@babel+core@7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 - '@babel/preset-react': 7.18.6_@babel+core@7.21.4 - '@babel/preset-typescript': 7.21.4_@babel+core@7.21.4 - '@babel/register': 7.21.0_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-proposal-export-default-from': 7.18.10_@babel+core@7.22.11 + '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-object-rest-spread': 7.20.7_@babel+core@7.22.11 + '@babel/plugin-proposal-optional-chaining': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-proposal-private-methods': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-private-property-in-object': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-transform-arrow-functions': 7.20.7_@babel+core@7.22.11 + '@babel/plugin-transform-block-scoping': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-classes': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-destructuring': 7.21.3_@babel+core@7.22.11 + '@babel/plugin-transform-for-of': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-parameters': 7.21.3_@babel+core@7.22.11 + '@babel/plugin-transform-shorthand-properties': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-transform-spread': 7.20.7_@babel+core@7.22.11 + '@babel/preset-env': 7.21.4_@babel+core@7.22.11 + '@babel/preset-react': 7.18.6_@babel+core@7.22.11 + '@babel/preset-typescript': 7.21.4_@babel+core@7.22.11 + '@babel/register': 7.21.0_@babel+core@7.22.11 '@storybook/node-logger': 6.5.16 '@storybook/semver': 7.3.2 '@types/node': 14.18.42 '@types/pretty-hrtime': 1.0.1 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce babel-plugin-macros: 3.1.0 - babel-plugin-polyfill-corejs3: 0.1.7_@babel+core@7.21.4 + babel-plugin-polyfill-corejs3: 0.1.7_@babel+core@7.22.11 chalk: 4.1.2 core-js: 3.30.0 express: 4.18.2 @@ -21023,35 +21027,35 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-proposal-export-default-from': 7.18.10_@babel+core@7.21.4 - '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-object-rest-spread': 7.20.7_@babel+core@7.21.4 - '@babel/plugin-proposal-optional-chaining': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-proposal-private-methods': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-proposal-private-property-in-object': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.21.4 - '@babel/plugin-transform-arrow-functions': 7.20.7_@babel+core@7.21.4 - '@babel/plugin-transform-block-scoping': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-classes': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-destructuring': 7.21.3_@babel+core@7.21.4 - '@babel/plugin-transform-for-of': 7.21.0_@babel+core@7.21.4 - '@babel/plugin-transform-parameters': 7.21.3_@babel+core@7.21.4 - '@babel/plugin-transform-shorthand-properties': 7.18.6_@babel+core@7.21.4 - '@babel/plugin-transform-spread': 7.20.7_@babel+core@7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 - '@babel/preset-react': 7.18.6_@babel+core@7.21.4 - '@babel/preset-typescript': 7.21.4_@babel+core@7.21.4 - '@babel/register': 7.21.0_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/plugin-proposal-class-properties': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-decorators': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-proposal-export-default-from': 7.18.10_@babel+core@7.22.11 + '@babel/plugin-proposal-nullish-coalescing-operator': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-object-rest-spread': 7.20.7_@babel+core@7.22.11 + '@babel/plugin-proposal-optional-chaining': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-proposal-private-methods': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-proposal-private-property-in-object': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-syntax-dynamic-import': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-transform-arrow-functions': 7.20.7_@babel+core@7.22.11 + '@babel/plugin-transform-block-scoping': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-classes': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-destructuring': 7.21.3_@babel+core@7.22.11 + '@babel/plugin-transform-for-of': 7.21.0_@babel+core@7.22.11 + '@babel/plugin-transform-parameters': 7.21.3_@babel+core@7.22.11 + '@babel/plugin-transform-shorthand-properties': 7.18.6_@babel+core@7.22.11 + '@babel/plugin-transform-spread': 7.20.7_@babel+core@7.22.11 + '@babel/preset-env': 7.21.4_@babel+core@7.22.11 + '@babel/preset-react': 7.18.6_@babel+core@7.22.11 + '@babel/preset-typescript': 7.21.4_@babel+core@7.22.11 + '@babel/register': 7.21.0_@babel+core@7.22.11 '@storybook/node-logger': 6.5.16 '@storybook/semver': 7.3.2 '@types/node': 14.18.42 '@types/pretty-hrtime': 1.0.1 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce babel-plugin-macros: 3.1.0 - babel-plugin-polyfill-corejs3: 0.1.7_@babel+core@7.21.4 + babel-plugin-polyfill-corejs3: 0.1.7_@babel+core@7.22.11 chalk: 4.1.2 core-js: 3.30.0 express: 4.18.2 @@ -21326,15 +21330,15 @@ packages: '@storybook/mdx2-csf': optional: true dependencies: - '@babel/core': 7.21.4 - '@babel/generator': 7.21.4 - '@babel/parser': 7.21.4 - '@babel/plugin-transform-react-jsx': 7.21.0_@babel+core@7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/core': 7.22.11 + '@babel/generator': 7.22.10 + '@babel/parser': 7.22.14 + '@babel/plugin-transform-react-jsx': 7.21.0_@babel+core@7.22.11 + '@babel/preset-env': 7.21.4_@babel+core@7.22.11 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 '@storybook/csf': 0.0.2--canary.4566f4d.1 - '@storybook/mdx1-csf': 0.0.1_@babel+core@7.21.4 + '@storybook/mdx1-csf': 0.0.1_@babel+core@7.22.11 core-js: 3.30.0 fs-extra: 9.1.0 global: 4.4.0 @@ -21352,7 +21356,7 @@ packages: /@storybook/docs-tools/6.5.16_sfoxds7t5ydpegc3knd667wn6m: resolution: {integrity: sha512-o+rAWPRGifjBF5xZzTKOqnHN3XQWkl0QFJYVDIiJYJrVll7ExCkpEq/PahOGzIBBV+tpMstJgmKM3lr/lu/jmg==} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@storybook/csf': 0.0.2--canary.4566f4d.1 '@storybook/store': 6.5.16_sfoxds7t5ydpegc3knd667wn6m core-js: 3.30.0 @@ -21387,9 +21391,9 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-transform-template-literals': 7.18.9_@babel+core@7.21.4 - '@babel/preset-react': 7.18.6_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/plugin-transform-template-literals': 7.18.9_@babel+core@7.22.11 + '@babel/preset-react': 7.18.6_@babel+core@7.22.11 '@storybook/addons': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/core-client': 6.5.16_zpymzxef3xv3tkikcnxd3qomju '@storybook/core-common': 6.5.16_hphf5artkrw22ab3e7jo6bgcc4 @@ -21398,7 +21402,7 @@ packages: '@storybook/ui': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@types/node': 14.18.42 '@types/webpack': 4.41.33 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce case-sensitive-paths-webpack-plugin: 2.4.0 chalk: 4.1.2 core-js: 3.30.0 @@ -21445,9 +21449,9 @@ packages: typescript: optional: true dependencies: - '@babel/core': 7.21.4 - '@babel/plugin-transform-template-literals': 7.18.9_@babel+core@7.21.4 - '@babel/preset-react': 7.18.6_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/plugin-transform-template-literals': 7.18.9_@babel+core@7.22.11 + '@babel/preset-react': 7.18.6_@babel+core@7.22.11 '@storybook/addons': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@storybook/core-client': 6.5.16_zpymzxef3xv3tkikcnxd3qomju '@storybook/core-common': 6.5.16_rapklf4l3qxrkek5brfyuedqf4 @@ -21456,7 +21460,7 @@ packages: '@storybook/ui': 6.5.16_sfoxds7t5ydpegc3knd667wn6m '@types/node': 14.18.42 '@types/webpack': 4.41.33 - babel-loader: 8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u + babel-loader: 8.3.0_6gybhbqitvywvqspas67uhcyce case-sensitive-paths-webpack-plugin: 2.4.0 chalk: 4.1.2 core-js: 3.30.0 @@ -21550,32 +21554,13 @@ packages: - webpack-command dev: true - /@storybook/mdx1-csf/0.0.1_@babel+core@7.21.4: - resolution: {integrity: sha512-4biZIWWzoWlCarMZmTpqcJNgo/RBesYZwGFbQeXiGYsswuvfWARZnW9RE9aUEMZ4XPn7B1N3EKkWcdcWe/K2tg==} - dependencies: - '@babel/generator': 7.21.4 - '@babel/parser': 7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 - '@babel/types': 7.21.4 - '@mdx-js/mdx': 1.6.22 - '@types/lodash': 4.14.192 - js-string-escape: 1.0.1 - loader-utils: 2.0.4 - lodash: 4.17.21 - prettier: 2.3.0 - ts-dedent: 2.2.0 - transitivePeerDependencies: - - '@babel/core' - - supports-color - dev: true - /@storybook/mdx1-csf/0.0.1_@babel+core@7.22.11: resolution: {integrity: sha512-4biZIWWzoWlCarMZmTpqcJNgo/RBesYZwGFbQeXiGYsswuvfWARZnW9RE9aUEMZ4XPn7B1N3EKkWcdcWe/K2tg==} dependencies: - '@babel/generator': 7.21.4 + '@babel/generator': 7.22.10 '@babel/parser': 7.21.4 '@babel/preset-env': 7.21.4_@babel+core@7.22.11 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 '@mdx-js/mdx': 1.6.22 '@types/lodash': 4.14.192 js-string-escape: 1.0.1 @@ -22202,13 +22187,13 @@ packages: resolution: {integrity: sha512-cAaR/CAiZRB8GP32N+1jocovUtvlj0+e65TB50/6Lcime+EA49m/8l+P2ko+XPJ4dw3xaPS3jOL4F2X4KWxoeQ==} engines: {node: '>=10'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@svgr/hast-util-to-babel-ast/6.5.1: resolution: {integrity: sha512-1hnUxxjd83EAxbL4a0JDJoD3Dao3hmjvyvyEV8PzWmLK3B9m9NPlW7GKjFyoWE8nM7HnXzPcmmSyOW8yOddSXw==} engines: {node: '>=10'} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 entities: 4.4.0 dev: false @@ -22216,7 +22201,7 @@ packages: resolution: {integrity: sha512-V/wVh33j12hGh05IDg8GpIUXbjAPnTdPTKuP4VNLggnwaHMPNQNae2pRnyTAILWCQdz5GyMqtO488g7CKM8CBA==} engines: {node: '>=10'} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@svgr/babel-preset': 5.5.0 '@svgr/hast-util-to-babel-ast': 5.5.0 svg-parser: 2.0.4 @@ -22688,18 +22673,18 @@ packages: /@types/babel__generator/7.6.4: resolution: {integrity: sha512-tFkciB9j2K755yrTALxD44McOrk+gfpIpvC3sxHjRawj6PfnQxrse4Clq5y/Rq+G3mrBurMax/lG8Qn2t9mSsg==} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@types/babel__template/7.4.1: resolution: {integrity: sha512-azBFKemX6kMg5Io+/rdGT0dkGreboUVR0Cdm3fz9QJWpaQGJRQXl7C+6hOTCZcMll7KFyEQpgbYI2lHdsS4U7g==} dependencies: '@babel/parser': 7.21.4 - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@types/babel__traverse/7.18.3: resolution: {integrity: sha512-1kbcJ40lLB7MHsj39U4Sh1uTd2E7rLEa79kmDpI6cy+XiXsteB3POdQomoq4FxszMrO3ZYchkhYJw7A2862b3w==} dependencies: - '@babel/types': 7.21.4 + '@babel/types': 7.22.11 /@types/bcrypt/3.0.1: resolution: {integrity: sha512-SwBrq5wb6jXP0o3O3jStdPWbKpimTImfdFD/OZE3uW+jhGpds/l5wMX9lfYOTDOa5Bod2QmOgo9ln+tMp2XP/w==} @@ -25777,6 +25762,15 @@ packages: transitivePeerDependencies: - debug + /axios/1.5.0: + resolution: {integrity: sha512-D4DdjDo5CY50Qms0qGQTTw6Q44jl7zRwY7bthds06pUGfChBCTcQs+N743eFWGEd6pRTMd6A+I87aWyFV5wiZQ==} + dependencies: + follow-redirects: 1.15.2 + form-data: 4.0.0 + proxy-from-env: 1.1.0 + transitivePeerDependencies: + - debug + /axobject-query/3.1.1: resolution: {integrity: sha512-goKlv8DZrK9hUh975fnHzhNIO4jUnFCfv/dszV5VwUGDFjI6vQ2VwoyjYjYNEbBE8AH87TduWP5uyDR1D+Iteg==} dependencies: @@ -25800,17 +25794,36 @@ packages: transitivePeerDependencies: - supports-color - /babel-jest/29.5.0_@babel+core@7.21.4: + /babel-jest/27.5.1_@babel+core@7.22.11: + resolution: {integrity: sha512-cdQ5dXjGRd0IBRATiQ4mZGlGlRE8kJpjPOixdNRdT+m3UcNqmYWN6rK6nvtXYfY3D76cb8s/O1Ss8ea24PIwcg==} + engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} + peerDependencies: + '@babel/core': ^7.8.0 + dependencies: + '@babel/core': 7.22.11 + '@jest/transform': 27.5.1 + '@jest/types': 27.5.1 + '@types/babel__core': 7.20.0 + babel-plugin-istanbul: 6.1.1 + babel-preset-jest: 27.5.1_@babel+core@7.22.11 + chalk: 4.1.2 + graceful-fs: 4.2.11 + slash: 3.0.0 + transitivePeerDependencies: + - supports-color + dev: true + + /babel-jest/29.5.0_@babel+core@7.22.11: resolution: {integrity: sha512-mA4eCDh5mSo2EcA9xQjVTpmbbNk32Zb3Q3QFQsNhaK56Q+yoXowzFodLux30HRgyOho5rsQ6B0P9QpMkvvnJ0Q==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: '@babel/core': ^7.8.0 dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/transform': 29.5.0 '@types/babel__core': 7.20.0 babel-plugin-istanbul: 6.1.1 - babel-preset-jest: 29.5.0_@babel+core@7.21.4 + babel-preset-jest: 29.5.0_@babel+core@7.22.11 chalk: 4.1.2 graceful-fs: 4.2.11 slash: 3.0.0 @@ -25846,7 +25859,7 @@ packages: schema-utils: 2.7.1 webpack: 5.78.0 - /babel-loader/8.3.0_pzz2ydzkafj27vzf3wnu5rjngu: + /babel-loader/8.3.0_6gybhbqitvywvqspas67uhcyce: resolution: {integrity: sha512-H8SvsMF+m9t15HNLMipppzkC+Y2Yq+v3SonZyU70RBL/h1gxPkH08Ot8pEE9Z4Kd+czyWJClmFS8qzIP9OZ04Q==} engines: {node: '>= 8.9'} peerDependencies: @@ -25858,17 +25871,16 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 5.82.1_webpack-cli@5.1.4 - dev: true + webpack: 4.46.0 - /babel-loader/8.3.0_yodcrl5qzmr3uixa4yblrqtj3e: + /babel-loader/8.3.0_pzz2ydzkafj27vzf3wnu5rjngu: resolution: {integrity: sha512-H8SvsMF+m9t15HNLMipppzkC+Y2Yq+v3SonZyU70RBL/h1gxPkH08Ot8pEE9Z4Kd+czyWJClmFS8qzIP9OZ04Q==} engines: {node: '>= 8.9'} peerDependencies: '@babel/core': ^7.0.0 webpack: '>=2' dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 find-cache-dir: 3.3.2 loader-utils: 2.0.4 make-dir: 3.1.0 @@ -25876,7 +25888,7 @@ packages: webpack: 5.82.1_webpack-cli@5.1.4 dev: true - /babel-loader/8.3.0_z2ws6pnxa5zk5axe2qz6qd5y4u: + /babel-loader/8.3.0_yodcrl5qzmr3uixa4yblrqtj3e: resolution: {integrity: sha512-H8SvsMF+m9t15HNLMipppzkC+Y2Yq+v3SonZyU70RBL/h1gxPkH08Ot8pEE9Z4Kd+czyWJClmFS8qzIP9OZ04Q==} engines: {node: '>= 8.9'} peerDependencies: @@ -25888,7 +25900,8 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 4.46.0 + webpack: 5.82.1_webpack-cli@5.1.4 + dev: true /babel-loader/9.1.2_vbwv3zr3kwaf4v2iytwakh6feu: resolution: {integrity: sha512-mN14niXW43tddohGl8HPu5yfQq70iUThvFL/4QzESA7GcZoC0eVOhvWdQ8+3UlSjaDE9MVtsW9mxDY07W7VpVA==} @@ -25916,15 +25929,15 @@ packages: '@babel/helper-plugin-utils': 7.10.4 '@mdx-js/util': 1.6.22 - /babel-plugin-const-enum/1.2.0_@babel+core@7.21.4: + /babel-plugin-const-enum/1.2.0_@babel+core@7.22.11: resolution: {integrity: sha512-o1m/6iyyFnp9MRsK1dHF3bneqyf3AlM2q3A/YbgQr2pCat6B6XJVDv2TXqzfY2RYUi4mak6WAksSBPlyYGx9dg==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@babel/helper-plugin-utils': 7.20.2 - '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.21.4 - '@babel/traverse': 7.21.4 + '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.22.11 + '@babel/traverse': 7.22.11 transitivePeerDependencies: - supports-color dev: true @@ -25961,8 +25974,8 @@ packages: resolution: {integrity: sha512-50wCwD5EMNW4aRpOwtqzyZHIewTYNxLA4nhB+09d8BIssfNfzBRhkBIHiaPv1Si226TQSvp8gxAJm2iY2qs2hQ==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/template': 7.20.7 - '@babel/types': 7.21.4 + '@babel/template': 7.22.5 + '@babel/types': 7.22.11 '@types/babel__core': 7.20.0 '@types/babel__traverse': 7.18.3 @@ -25970,8 +25983,8 @@ packages: resolution: {integrity: sha512-zSuuuAlTMT4mzLj2nPnUm6fsE6270vdOfnpbJ+RmruU75UhLFvL0N2NgI7xpeS7NaB6hGqmd5pVpGTDYvi4Q3w==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/template': 7.20.7 - '@babel/types': 7.21.4 + '@babel/template': 7.22.5 + '@babel/types': 7.22.11 '@types/babel__core': 7.20.0 '@types/babel__traverse': 7.18.3 dev: true @@ -26040,13 +26053,13 @@ packages: transitivePeerDependencies: - supports-color - /babel-plugin-polyfill-corejs3/0.1.7_@babel+core@7.21.4: + /babel-plugin-polyfill-corejs3/0.1.7_@babel+core@7.22.11: resolution: {integrity: sha512-u+gbS9bbPhZWEeyy1oR/YaaSpod/KDT07arZHb80aTpl8H5ZBq+uN1nN9/xtX7jQyfLdPfoqI4Rue/MQSWJquw==} peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/core': 7.21.4 - '@babel/helper-define-polyfill-provider': 0.1.5_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/helper-define-polyfill-provider': 0.1.5_@babel+core@7.22.11 core-js-compat: 3.30.0 transitivePeerDependencies: - supports-color @@ -26146,7 +26159,7 @@ packages: /babel-plugin-transform-react-remove-prop-types/0.4.24: resolution: {integrity: sha512-eqj0hVcJUR57/Ug2zE1Yswsw4LhuqqHhD+8v120T1cl3kjg76QwtyBrdIk4WVwK+lAhBJVYCd/v+4nc4y+8JsA==} - /babel-plugin-transform-typescript-metadata/0.3.2_@babel+core@7.21.4: + /babel-plugin-transform-typescript-metadata/0.3.2_@babel+core@7.22.11: resolution: {integrity: sha512-mWEvCQTgXQf48yDqgN7CH50waTyYBeP2Lpqx4nNWab9sxEpdXVeKgfj1qYI2/TgUPQtNFZ85i3PemRtnXVYYJg==} peerDependencies: '@babel/core': ^7 @@ -26155,7 +26168,7 @@ packages: '@babel/traverse': optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@babel/helper-plugin-utils': 7.20.2 dev: true @@ -26178,6 +26191,25 @@ packages: '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.21.4 '@babel/plugin-syntax-top-level-await': 7.14.5_@babel+core@7.21.4 + /babel-preset-current-node-syntax/1.0.1_@babel+core@7.22.11: + resolution: {integrity: sha512-M7LQ0bxarkxQoN+vz5aJPsLBn77n8QgTFmo8WK0/44auK2xlCXrYcUxHFxgU7qW5Yzw/CjmLRK2uJzaCd7LvqQ==} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.22.11 + '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.22.11 + '@babel/plugin-syntax-bigint': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-class-properties': 7.12.13_@babel+core@7.22.11 + '@babel/plugin-syntax-import-meta': 7.10.4_@babel+core@7.22.11 + '@babel/plugin-syntax-json-strings': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-logical-assignment-operators': 7.10.4_@babel+core@7.22.11 + '@babel/plugin-syntax-nullish-coalescing-operator': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-numeric-separator': 7.10.4_@babel+core@7.22.11 + '@babel/plugin-syntax-object-rest-spread': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-optional-catch-binding': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-optional-chaining': 7.8.3_@babel+core@7.22.11 + '@babel/plugin-syntax-top-level-await': 7.14.5_@babel+core@7.22.11 + /babel-preset-jest/27.5.1_@babel+core@7.21.4: resolution: {integrity: sha512-Nptf2FzlPCWYuJg41HBqXVT8ym6bXOevuCTbhxlUpjwtysGaIWFvDEjp4y+G7fl13FgOdjs7P/DmErqH7da0Ag==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} @@ -26188,15 +26220,26 @@ packages: babel-plugin-jest-hoist: 27.5.1 babel-preset-current-node-syntax: 1.0.1_@babel+core@7.21.4 - /babel-preset-jest/29.5.0_@babel+core@7.21.4: + /babel-preset-jest/27.5.1_@babel+core@7.22.11: + resolution: {integrity: sha512-Nptf2FzlPCWYuJg41HBqXVT8ym6bXOevuCTbhxlUpjwtysGaIWFvDEjp4y+G7fl13FgOdjs7P/DmErqH7da0Ag==} + engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} + peerDependencies: + '@babel/core': ^7.0.0 + dependencies: + '@babel/core': 7.22.11 + babel-plugin-jest-hoist: 27.5.1 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.22.11 + dev: true + + /babel-preset-jest/29.5.0_@babel+core@7.22.11: resolution: {integrity: sha512-JOMloxOqdiBSxMAzjRaH023/vvcaSaec49zvg+2LmNsktC7ei39LTJGw02J+9uUtTZUq6xbLyJ4dxe9sSmIuAg==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} peerDependencies: '@babel/core': ^7.0.0 dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 babel-plugin-jest-hoist: 29.5.0 - babel-preset-current-node-syntax: 1.0.1_@babel+core@7.21.4 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.22.11 dev: true /babel-preset-react-app/10.0.1: @@ -31134,7 +31177,7 @@ packages: minimatch: 3.1.2 object.values: 1.1.6 resolve: 1.22.2 - semver: 6.3.0 + semver: 6.3.1 tsconfig-paths: 3.14.2 transitivePeerDependencies: - eslint-import-resolver-typescript @@ -31343,7 +31386,7 @@ packages: object.values: 1.1.6 prop-types: 15.8.1 resolve: 2.0.0-next.4 - semver: 6.3.0 + semver: 6.3.1 string.prototype.matchall: 4.0.8 /eslint-plugin-spellcheck/0.0.20_eslint@8.38.0: @@ -31663,8 +31706,8 @@ packages: resolution: {integrity: sha512-YNF+mZ/Wu2FU/gvmzuWtYc8rloubL7wfXCTgouFrnjGVXPA/EeYYA7pupXWrb3Iv1cTBeSSxxJIbK23l4MRNqg==} engines: {node: '>=8.3.0'} dependencies: - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 c8: 7.13.0 transitivePeerDependencies: - supports-color @@ -35810,7 +35853,7 @@ packages: resolution: {integrity: sha512-BXgQl9kf4WTCPCCpmFGoJkz/+uhvm7h7PFKUYxh7qarQd3ER33vHG//qaE8eN25l07YqZPpHXU9I09l/RD5aGQ==} engines: {node: '>=8'} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.0 semver: 6.3.1 @@ -35822,7 +35865,7 @@ packages: resolution: {integrity: sha512-pzqtp31nLv/XFOzXGuvhCb8qhjmTVo5vjVk19XE4CRlSWz0KoeJ3bw9XsA7nOp9YBf4qHjwBxkDzKcME/J29Yg==} engines: {node: '>=8'} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@babel/parser': 7.21.4 '@istanbuljs/schema': 0.1.3 istanbul-lib-coverage: 3.2.0 @@ -36104,10 +36147,10 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/test-sequencer': 27.5.1 '@jest/types': 27.5.1 - babel-jest: 27.5.1_@babel+core@7.21.4 + babel-jest: 27.5.1_@babel+core@7.22.11 chalk: 4.1.2 deepmerge: 4.3.1 glob: 7.2.3 @@ -36225,11 +36268,11 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/test-sequencer': 29.5.0 '@jest/types': 29.5.0 '@types/node': 16.11.7 - babel-jest: 29.5.0_@babel+core@7.21.4 + babel-jest: 29.5.0_@babel+core@7.22.11 chalk: 4.1.2 ci-info: 3.8.0 deepmerge: 4.3.1 @@ -36265,11 +36308,11 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/test-sequencer': 29.5.0 '@jest/types': 29.5.0 '@types/node': 14.18.42 - babel-jest: 29.5.0_@babel+core@7.21.4 + babel-jest: 29.5.0_@babel+core@7.22.11 chalk: 4.1.2 ci-info: 3.8.0 deepmerge: 4.3.1 @@ -36304,11 +36347,11 @@ packages: ts-node: optional: true dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@jest/test-sequencer': 29.5.0 '@jest/types': 29.5.0 '@types/node': 18.15.11 - babel-jest: 29.5.0_@babel+core@7.21.4 + babel-jest: 29.5.0_@babel+core@7.22.11 chalk: 4.1.2 ci-info: 3.8.0 deepmerge: 4.3.1 @@ -36913,16 +36956,16 @@ packages: resolution: {integrity: sha512-yYykXI5a0I31xX67mgeLw1DZ0bJB+gpq5IpSuCAoyDi0+BhgU/RIrL+RTzDmkNTchvDFWKP8lp+w/42Z3us5sA==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} dependencies: - '@babel/core': 7.21.4 - '@babel/generator': 7.21.4 - '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.21.4 - '@babel/traverse': 7.21.4 - '@babel/types': 7.21.4 + '@babel/core': 7.22.11 + '@babel/generator': 7.22.10 + '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.22.11 + '@babel/traverse': 7.22.11 + '@babel/types': 7.22.11 '@jest/transform': 27.5.1 '@jest/types': 27.5.1 '@types/babel__traverse': 7.18.3 '@types/prettier': 2.7.2 - babel-preset-current-node-syntax: 1.0.1_@babel+core@7.21.4 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.22.11 chalk: 4.1.2 expect: 27.5.1 graceful-fs: 4.2.11 @@ -36942,10 +36985,10 @@ packages: resolution: {integrity: sha512-x7Wolra5V0tt3wRs3/ts3S6ciSQVypgGQlJpz2rsdQYoUKxMxPNaoHMGJN6qAuPJqS+2iQ1ZUn5kl7HCyls84g==} engines: {node: ^14.15.0 || ^16.10.0 || >=18.0.0} dependencies: - '@babel/core': 7.21.4 + '@babel/core': 7.22.11 '@babel/generator': 7.21.4 - '@babel/plugin-syntax-jsx': 7.21.4_@babel+core@7.21.4 - '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.21.4 + '@babel/plugin-syntax-jsx': 7.21.4_@babel+core@7.22.11 + '@babel/plugin-syntax-typescript': 7.21.4_@babel+core@7.22.11 '@babel/traverse': 7.21.4 '@babel/types': 7.21.4 '@jest/expect-utils': 29.5.0 @@ -36953,7 +36996,7 @@ packages: '@jest/types': 29.5.0 '@types/babel__traverse': 7.18.3 '@types/prettier': 2.7.2 - babel-preset-current-node-syntax: 1.0.1_@babel+core@7.21.4 + babel-preset-current-node-syntax: 1.0.1_@babel+core@7.22.11 chalk: 4.1.2 expect: 29.5.0 graceful-fs: 4.2.11 @@ -37321,7 +37364,7 @@ packages: engines: {node: '>=12.0.0'} hasBin: true dependencies: - '@babel/parser': 7.22.13 + '@babel/parser': 7.22.14 '@jsdoc/salty': 0.2.5 '@types/markdown-it': 12.2.3 bluebird: 3.7.2 @@ -38672,7 +38715,7 @@ packages: /mailgun.js/8.2.1: resolution: {integrity: sha512-iKHCMehdUcWzBAp8KU2idLP7AbsTxQ8DjJev4Gvm430Dujul+ZkzKPgn40uYpb9BXGL5l8/w5jpf2pvw51df/w==} dependencies: - axios: 1.4.0 + axios: 1.5.0 base-64: 1.0.0 url-join: 4.0.1 transitivePeerDependencies: @@ -40726,7 +40769,7 @@ packages: '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.42 '@zkochan/js-yaml': 0.0.6 - axios: 1.4.0 + axios: 1.5.0 chalk: 4.1.2 cli-cursor: 3.1.0 cli-spinners: 2.6.1 @@ -40788,7 +40831,7 @@ packages: '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.42 '@zkochan/js-yaml': 0.0.6 - axios: 1.4.0 + axios: 1.5.0 chalk: 4.1.2 cli-cursor: 3.1.0 cli-spinners: 2.6.1 @@ -40851,7 +40894,7 @@ packages: '@yarnpkg/lockfile': 1.1.0 '@yarnpkg/parsers': 3.0.0-rc.42 '@zkochan/js-yaml': 0.0.6 - axios: 1.4.0 + axios: 1.5.0 chalk: 4.1.2 cli-cursor: 3.1.0 cli-spinners: 2.6.1 @@ -41752,27 +41795,6 @@ packages: passport-oauth2: 1.7.0 dev: false - /passport-google-oauth/2.0.0: - resolution: {integrity: sha512-JKxZpBx6wBQXX1/a1s7VmdBgwOugohH+IxCy84aPTZNq/iIPX6u7Mqov1zY7MKRz3niFPol0KJz8zPLBoHKtYA==} - engines: {node: '>= 0.4.0'} - dependencies: - passport-google-oauth1: 1.0.0 - passport-google-oauth20: 2.0.0 - dev: false - - /passport-google-oauth1/1.0.0: - resolution: {integrity: sha512-qpCEhuflJgYrdg5zZIpAq/K3gTqa1CtHjbubsEsidIdpBPLkEVq6tB1I8kBNcH89RdSiYbnKpCBXAZXX/dtx1Q==} - dependencies: - passport-oauth1: 1.3.0 - dev: false - - /passport-google-oauth20/2.0.0: - resolution: {integrity: sha512-KSk6IJ15RoxuGq7D1UKK/8qKhNfzbLeLrG3gkLZ7p4A6DBCcv7xpyQwuXtWdpyR0+E0mwkpjY1VfPOhxQrKzdQ==} - engines: {node: '>= 0.4.0'} - dependencies: - passport-oauth2: 1.7.0 - dev: false - /passport-jwt/4.0.1: resolution: {integrity: sha512-UCKMDYhNuGOBE9/9Ycuoyh7vP6jpeTp/+sfMJl7nLff/t6dps+iaeE0hhNkKN8/HZHcJ7lCdOyDxHdDoxoSvdQ==} dependencies: @@ -41780,15 +41802,6 @@ packages: passport-strategy: 1.0.0 dev: false - /passport-oauth1/1.3.0: - resolution: {integrity: sha512-8T/nX4gwKTw0PjxP1xfD0QhrydQNakzeOpZ6M5Uqdgz9/a/Ag62RmJxnZQ4LkbdXGrRehQHIAHNAu11rCP46Sw==} - engines: {node: '>= 0.4.0'} - dependencies: - oauth: 0.9.15 - passport-strategy: 1.0.0 - utils-merge: 1.0.1 - dev: false - /passport-oauth2/1.7.0: resolution: {integrity: sha512-j2gf34szdTF2Onw3+76alNnaAExlUmHvkc7cL+cmaS5NzHzDP/BvFHJruueQ9XAeNOdpI+CH+PWid8RA7KCwAQ==} engines: {node: '>= 0.4.0'} @@ -44718,8 +44731,8 @@ packages: engines: {node: '>=8.10.0'} hasBin: true dependencies: - '@babel/core': 7.21.4 - '@babel/generator': 7.21.4 + '@babel/core': 7.22.11 + '@babel/generator': 7.22.10 '@babel/runtime': 7.21.0 ast-types: 0.14.2 commander: 2.20.3 @@ -49382,7 +49395,7 @@ packages: yargs-parser: 20.2.9 dev: true - /ts-jest/27.1.5_cnngzrja2umb46xxazlucyx2qu: + /ts-jest/27.1.5_4aafjbpmnrfjtrzkyohogv4jce: resolution: {integrity: sha512-Xv6jBQPoBEvBq/5i2TeSG9tt/nqkbpcurrEG1b+2yfBrcJelOZF9Ml6dmyMh7bcW9JyFbRYpR5rxROSlBLTZHA==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} hasBin: true @@ -49403,6 +49416,7 @@ packages: esbuild: optional: true dependencies: + '@babel/core': 7.22.11 bs-logger: 0.2.6 fast-json-stable-stringify: 2.1.0 jest: 27.5.1_ts-node@10.9.1 @@ -51874,10 +51888,10 @@ packages: engines: {node: '>=10.0.0'} dependencies: '@apideck/better-ajv-errors': 0.3.6_ajv@8.12.0 - '@babel/core': 7.21.4 - '@babel/preset-env': 7.21.4_@babel+core@7.21.4 + '@babel/core': 7.22.11 + '@babel/preset-env': 7.21.4_@babel+core@7.22.11 '@babel/runtime': 7.21.0 - '@rollup/plugin-babel': 5.3.1_b6cdhqm2xsfe2bpl424qdsl4ei + '@rollup/plugin-babel': 5.3.1_lnssqozl4dgplk3xebfs3yicbq '@rollup/plugin-node-resolve': 11.2.1_rollup@2.79.1 '@rollup/plugin-replace': 2.4.2_rollup@2.79.1 '@surma/rollup-plugin-off-main-thread': 2.2.3 diff --git a/providers/custom-sms/.czrc b/providers/custom-sms/.czrc new file mode 100644 index 00000000000..d1bcc209ca1 --- /dev/null +++ b/providers/custom-sms/.czrc @@ -0,0 +1,3 @@ +{ + "path": "cz-conventional-changelog" +} diff --git a/providers/custom-sms/.eslintrc.json b/providers/custom-sms/.eslintrc.json new file mode 100644 index 00000000000..ec40100be69 --- /dev/null +++ b/providers/custom-sms/.eslintrc.json @@ -0,0 +1,3 @@ +{ + "extends": "../../.eslintrc.js" +} diff --git a/providers/custom-sms/.gitignore b/providers/custom-sms/.gitignore new file mode 100644 index 00000000000..963d5292865 --- /dev/null +++ b/providers/custom-sms/.gitignore @@ -0,0 +1,9 @@ +.idea/* +.nyc_output +build +node_modules +test +src/**.js +coverage +*.log +package-lock.json diff --git a/providers/custom-sms/README.md b/providers/custom-sms/README.md new file mode 100644 index 00000000000..ea0346b276f --- /dev/null +++ b/providers/custom-sms/README.md @@ -0,0 +1,9 @@ +# Novu CustomSms Provider + +A CustomSms sms provider library for [@novu/node](https://github.com/novuhq/novu) + +## Usage + +```javascript + FILL IN THE INITIALIZATION USAGE +``` diff --git a/providers/custom-sms/jest.config.js b/providers/custom-sms/jest.config.js new file mode 100644 index 00000000000..e86e13bab91 --- /dev/null +++ b/providers/custom-sms/jest.config.js @@ -0,0 +1,5 @@ +/** @type {import('ts-jest/dist/types').InitialOptionsTsJest} */ +module.exports = { + preset: 'ts-jest', + testEnvironment: 'node', +}; diff --git a/providers/custom-sms/package.json b/providers/custom-sms/package.json new file mode 100644 index 00000000000..540ddf5e710 --- /dev/null +++ b/providers/custom-sms/package.json @@ -0,0 +1,82 @@ +{ + "name": "@novu/custom-sms", + "version": "0.19.0", + "description": "A custom-sms wrapper for novu", + "main": "build/main/index.js", + "typings": "build/main/index.d.ts", + "module": "build/module/index.js", + "private": false, + "repository": "https://github.com/novuhq/novu", + "license": "MIT", + "keywords": [], + "scripts": { + "prebuild": "rimraf build", + "build": "run-p build:*", + "build:main": "tsc -p tsconfig.json", + "build:module": "tsc -p tsconfig.module.json", + "fix": "run-s fix:*", + "fix:prettier": "prettier \"src/**/*.ts\" --write", + "fix:lint": "eslint src --ext .ts --fix", + "test": "run-s test:*", + "lint": "eslint src --ext .ts", + "test:unit": "jest src", + "watch:build": "tsc -p tsconfig.json -w", + "watch:test": "jest src --watch", + "reset-hard": "git clean -dfx && git reset --hard && yarn", + "prepare-release": "run-s reset-hard test" + }, + "publishConfig": { + "access": "public" + }, + "engines": { + "node": ">=13.0.0 <17.0.0", + "pnpm": "^7.26.0" + }, + "dependencies": { + "@novu/stateless": "0.16.3", + "axios": "^1.5.0" + }, + "devDependencies": { + "@istanbuljs/nyc-config-typescript": "~1.0.1", + "@types/jest": "~27.5.2", + "cspell": "~6.19.2", + "jest": "~27.5.1", + "npm-run-all": "^4.1.5", + "nyc": "~15.1.0", + "prettier": "~2.8.0", + "rimraf": "~3.0.2", + "ts-jest": "~27.1.5", + "ts-node": "~10.9.1", + "typescript": "4.9.5" + }, + "files": [ + "build/main", + "build/module", + "!**/*.spec.*", + "!**/*.json", + "CHANGELOG.md", + "LICENSE", + "README.md" + ], + "ava": { + "failFast": true, + "timeout": "60s", + "typescript": { + "rewritePaths": { + "src/": "build/main/" + } + }, + "files": [ + "!build/module/**" + ] + }, + "prettier": { + "singleQuote": true + }, + "nyc": { + "extends": "@istanbuljs/nyc-config-typescript", + "exclude": [ + "**/*.spec.js" + ] + } +} diff --git a/providers/custom-sms/src/index.ts b/providers/custom-sms/src/index.ts new file mode 100644 index 00000000000..fea00acaa0a --- /dev/null +++ b/providers/custom-sms/src/index.ts @@ -0,0 +1 @@ +export * from './lib/custom-sms.provider'; diff --git a/providers/custom-sms/src/lib/custom-sms.provider.spec.ts b/providers/custom-sms/src/lib/custom-sms.provider.spec.ts new file mode 100644 index 00000000000..eea347097b2 --- /dev/null +++ b/providers/custom-sms/src/lib/custom-sms.provider.spec.ts @@ -0,0 +1,3 @@ +import { CustomSmsProvider } from './custom-sms.provider'; + +test('should trigger custom-sms library correctly', async () => {}); diff --git a/providers/custom-sms/src/lib/custom-sms.provider.ts b/providers/custom-sms/src/lib/custom-sms.provider.ts new file mode 100644 index 00000000000..fe28dcb3cc9 --- /dev/null +++ b/providers/custom-sms/src/lib/custom-sms.provider.ts @@ -0,0 +1,47 @@ +import { + ChannelTypeEnum, + ISendMessageSuccessResponse, + ISmsOptions, + ISmsProvider, +} from '@novu/stateless'; +import axios, { AxiosInstance } from 'axios'; + +export class CustomSmsProvider implements ISmsProvider { + id = 'custom-sms'; + channelType = ChannelTypeEnum.SMS as ChannelTypeEnum.SMS; + private axiosInstance: AxiosInstance; + + constructor( + private config: { + baseUrl?: string; + apiKey?: string; + secretKey?: string; + from?: string; + } + ) { + this.axiosInstance = axios.create({ + baseURL: config.baseUrl, + headers: { + apiKey: config.apiKey, + secretKey: config.secretKey, + }, + }); + } + + async sendMessage( + options: ISmsOptions + ): Promise { + const response = await this.axiosInstance.request({ + method: 'POST', + data: { + ...options, + from: this.config.from, + }, + }); + + return { + id: response.data.id, + date: response.data.date, + }; + } +} diff --git a/providers/custom-sms/tsconfig.json b/providers/custom-sms/tsconfig.json new file mode 100644 index 00000000000..5b8120fea36 --- /dev/null +++ b/providers/custom-sms/tsconfig.json @@ -0,0 +1,10 @@ +{ + "extends": "../../tsconfig.json", + "compilerOptions": { + "outDir": "build/main", + "rootDir": "src", + "types": ["node", "jest"] + }, + "include": ["src/**/*.ts"], + "exclude": ["node_modules/**"] +} diff --git a/providers/custom-sms/tsconfig.module.json b/providers/custom-sms/tsconfig.module.json new file mode 100644 index 00000000000..79be3a5c40b --- /dev/null +++ b/providers/custom-sms/tsconfig.module.json @@ -0,0 +1,9 @@ +{ + "extends": "./tsconfig", + "compilerOptions": { + "target": "esnext", + "outDir": "build/module", + "module": "esnext" + }, + "exclude": ["node_modules/**"] +} From 6ebe3ea35d62f6d1dd79672f13c7b9bcc8060cd7 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Tue, 12 Sep 2023 17:39:29 +0300 Subject: [PATCH 02/10] feat: Add Custom SMS provider documentation --- docs/docs/channels/sms/custom-sms.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 docs/docs/channels/sms/custom-sms.md diff --git a/docs/docs/channels/sms/custom-sms.md b/docs/docs/channels/sms/custom-sms.md new file mode 100644 index 00000000000..3e61f73e30e --- /dev/null +++ b/docs/docs/channels/sms/custom-sms.md @@ -0,0 +1,27 @@ +# Custom SMS + +The Custom SMS provider allows you to send transactional SMS messages through your own SMS service using the Novu Platform. + +## Getting Started + +To use the Custom SMS provider within the SMS channel, you'll need to have your own SMS service or access to a service provider that supports sending SMS messages using an API endpoint. You will also need to configure the following parameters in the Custom SMS integration on the Novu platform: + +- `BaseUrl`: The endpoint URL of your SMS service provider. +- `API Key`: Your API key for authenticating with the SMS service. +- `Secret Key` (optional): If your SMS service requires a secret key for authentication. +- `From` (optional): The sender information you want to appear on the SMS (e.g., your company name or phone number). + +## Setting Up Custom SMS Integration with Novu + +Follow these steps to create a Custom SMS integration with Novu: + +- **Visit the Integrations Store Page on Novu:** Log in to your Novu account and navigate to the "Integrations Store" page. +- **Locate Custom SMS Provider:** You will find "Custom SMS" under SMS Section and click on it to open the integration setup. +- **Enter Your SMS Service Credentials:** In the integration setup, provide the following information: + - `BaseUrl`: Fill in the endpoint URL of your SMS service provider. + - `API Key`: Enter your API key for authentication. + - `Secret Key` (optional): If your SMS service requires a secret key, enter it here. + - `From` (optional): Specify the sender information you want to display on the SMS messages. +- **Activate the Integration:** Click on the "Disabled" button to switch it to "Active." + +Once you've completed these steps, you can send notifications using the Custom SMS provider through Novu's platform. From e07883b4455d98c3277ba219f380a89b14d04288 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Thu, 14 Sep 2023 11:07:06 +0300 Subject: [PATCH 03/10] feat: Edit Custom SMS provider options to make it more dynamic --- .../app/integrations/dtos/credentials.dto.ts | 25 +++++++++++ .../providers/dark/square/custom-sms.svg | 1 + .../providers/light/square/custom-sms.svg | 1 + .../integration/integration.schema.ts | 5 +++ .../credentials/provider-credentials.ts | 40 +++++++++++++++++ .../src/consts/providers/provider.enum.ts | 5 +++ .../integration/credential.interface.ts | 5 +++ .../sms/handlers/custom-sms.handler.ts | 5 +++ pnpm-lock.yaml | 15 ++++--- .../custom-sms/src/lib/custom-sms.provider.ts | 43 +++++++++++++++---- 10 files changed, 130 insertions(+), 15 deletions(-) create mode 100644 apps/web/public/static/images/providers/dark/square/custom-sms.svg create mode 100644 apps/web/public/static/images/providers/light/square/custom-sms.svg diff --git a/apps/api/src/app/integrations/dtos/credentials.dto.ts b/apps/api/src/app/integrations/dtos/credentials.dto.ts index 5701d25fbc2..8456fc34b61 100644 --- a/apps/api/src/app/integrations/dtos/credentials.dto.ts +++ b/apps/api/src/app/integrations/dtos/credentials.dto.ts @@ -136,4 +136,29 @@ export class CredentialsDto implements ICredentials { @IsString() @IsOptional() ipPoolName?: string; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + method?: string; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + apiKeyAttribute?: string; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + secretKeyAttribute?: string; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + idPath?: string; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + datePath?: string; } diff --git a/apps/web/public/static/images/providers/dark/square/custom-sms.svg b/apps/web/public/static/images/providers/dark/square/custom-sms.svg new file mode 100644 index 00000000000..87e11a06f5d --- /dev/null +++ b/apps/web/public/static/images/providers/dark/square/custom-sms.svg @@ -0,0 +1 @@ + diff --git a/apps/web/public/static/images/providers/light/square/custom-sms.svg b/apps/web/public/static/images/providers/light/square/custom-sms.svg new file mode 100644 index 00000000000..f22ac13d527 --- /dev/null +++ b/apps/web/public/static/images/providers/light/square/custom-sms.svg @@ -0,0 +1 @@ + diff --git a/libs/dal/src/repositories/integration/integration.schema.ts b/libs/dal/src/repositories/integration/integration.schema.ts index 6fdff2d34fd..b9e4823a6ca 100644 --- a/libs/dal/src/repositories/integration/integration.schema.ts +++ b/libs/dal/src/repositories/integration/integration.schema.ts @@ -46,6 +46,11 @@ const integrationSchema = new Schema( redirectUrl: Schema.Types.String, hmac: Schema.Types.Boolean, ipPoolName: Schema.Types.String, + method: Schema.Types.String, + apiKeyAttribute: Schema.Types.String, + secretKeyAttribute: Schema.Types.String, + idPath: Schema.Types.String, + datePath: Schema.Types.String, }, active: { type: Schema.Types.Boolean, diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index 658fc6d96f7..bd7ceb1fd5e 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -748,18 +748,58 @@ export const customSmsConfig: IConfigCredentials[] = [ type: 'string', required: true, }, + { + key: CredentialsKeyEnum.Method, + displayName: 'HTTP Method', + type: 'string', + value: 'POST', + description: 'The HTTP method to use when calling the API (GET, POST)', + required: true, + }, + { + key: CredentialsKeyEnum.ApiKeyAttribute, + displayName: 'API Key Attribute', + type: 'string', + description: 'The name of the header attribute to use for the API key ex. (X-API-KEY, apiKey, ...)', + required: true, + }, { key: CredentialsKeyEnum.ApiKey, displayName: 'API Key', type: 'string', + description: 'The value of the header attribute to use for the API key', required: true, }, + { + key: CredentialsKeyEnum.SecretKeyAttribute, + displayName: 'Secret Key Attribute', + type: 'string', + description: 'The name of the header attribute to use for the secret key ex. (X-API-SECRET, apiSecret, ...)', + required: false, + }, { key: CredentialsKeyEnum.SecretKey, displayName: 'Secret Key', type: 'string', + description: 'The value of the header attribute to use for the secret key', required: false, }, + { + key: CredentialsKeyEnum.IdPath, + displayName: 'Id Path', + type: 'string', + value: 'id', + description: 'The path to the id field in the response data ex. (id, message.id, ...)', + required: true, + }, + { + key: CredentialsKeyEnum.DatePath, + displayName: 'Date Path', + type: 'string', + value: 'date', + description: 'The path to the date field in the response data ex. (date, message.date, ...)', + required: true, + }, { key: CredentialsKeyEnum.From, displayName: 'From', diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index a24dce05f87..516638754ac 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -27,6 +27,11 @@ export enum CredentialsKeyEnum { RedirectUrl = 'redirectUrl', Hmac = 'hmac', IpPoolName = 'ipPoolName', + Method = 'method', + ApiKeyAttribute = 'apiKeyAttribute', + SecretKeyAttribute = 'secretKeyAttribute', + IdPath = 'idPath', + DatePath = 'datePath', } export enum EmailProviderIdEnum { diff --git a/libs/shared/src/entities/integration/credential.interface.ts b/libs/shared/src/entities/integration/credential.interface.ts index 2991c1d3ce9..473047546dd 100644 --- a/libs/shared/src/entities/integration/credential.interface.ts +++ b/libs/shared/src/entities/integration/credential.interface.ts @@ -25,4 +25,9 @@ export interface ICredentials { redirectUrl?: string; hmac?: boolean; ipPoolName?: string; + method?: string; + apiKeyAttribute?: string; + secretKeyAttribute?: string; + idPath?: string; + datePath?: string; } diff --git a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts index e0b0d5c6388..816a22705bb 100644 --- a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts +++ b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts @@ -13,6 +13,11 @@ export class CustomSmsHandler extends BaseSmsHandler { apiKey: credentials.apiKey, secretKey: credentials.secretKey, from: credentials.from, + method: credentials.method, + apiKeyAttribute: credentials.apiKeyAttribute, + secretKeyAttribute: credentials.secretKeyAttribute, + idPath: credentials.idPath, + datePath: credentials.datePath, }); } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index dc9d78b8cac..9491fed5b3c 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -394,7 +394,7 @@ importers: nodemon: 2.0.22 prettier: 2.8.7 sinon: 9.2.4 - ts-jest: 27.1.5_4aafjbpmnrfjtrzkyohogv4jce + ts-jest: 27.1.5_cnngzrja2umb46xxazlucyx2qu ts-loader: 9.4.2_rggdtlzfqxxwxudp3onsqdyocm ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna tsconfig-paths: 4.1.2 @@ -8663,9 +8663,11 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-module-transforms': 7.22.9_@babel+core@7.20.12 + '@babel/helper-module-transforms': 7.21.2 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-simple-access': 7.20.2 + transitivePeerDependencies: + - supports-color dev: true /@babel/plugin-transform-modules-commonjs/7.21.2_@babel+core@7.21.4: @@ -8675,9 +8677,11 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-module-transforms': 7.22.9_@babel+core@7.21.4 + '@babel/helper-module-transforms': 7.21.2 '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-simple-access': 7.20.2 + transitivePeerDependencies: + - supports-color /@babel/plugin-transform-modules-commonjs/7.21.2_@babel+core@7.22.11: resolution: {integrity: sha512-Cln+Yy04Gxua7iPdj6nOV96smLGjpElir5YwzF0LBPKoPlLDNJePNlrGGaybAJkd0zKRnOVXOgizSqPYMNYkzA==} @@ -31177,7 +31181,7 @@ packages: minimatch: 3.1.2 object.values: 1.1.6 resolve: 1.22.2 - semver: 6.3.1 + semver: 6.3.0 tsconfig-paths: 3.14.2 transitivePeerDependencies: - eslint-import-resolver-typescript @@ -49395,7 +49399,7 @@ packages: yargs-parser: 20.2.9 dev: true - /ts-jest/27.1.5_4aafjbpmnrfjtrzkyohogv4jce: + /ts-jest/27.1.5_cnngzrja2umb46xxazlucyx2qu: resolution: {integrity: sha512-Xv6jBQPoBEvBq/5i2TeSG9tt/nqkbpcurrEG1b+2yfBrcJelOZF9Ml6dmyMh7bcW9JyFbRYpR5rxROSlBLTZHA==} engines: {node: ^10.13.0 || ^12.13.0 || ^14.15.0 || >=15.0.0} hasBin: true @@ -49416,7 +49420,6 @@ packages: esbuild: optional: true dependencies: - '@babel/core': 7.22.11 bs-logger: 0.2.6 fast-json-stable-stringify: 2.1.0 jest: 27.5.1_ts-node@10.9.1 diff --git a/providers/custom-sms/src/lib/custom-sms.provider.ts b/providers/custom-sms/src/lib/custom-sms.provider.ts index fe28dcb3cc9..1110c0e4043 100644 --- a/providers/custom-sms/src/lib/custom-sms.provider.ts +++ b/providers/custom-sms/src/lib/custom-sms.provider.ts @@ -17,14 +17,24 @@ export class CustomSmsProvider implements ISmsProvider { apiKey?: string; secretKey?: string; from?: string; + method?: string; + apiKeyAttribute?: string; + secretKeyAttribute?: string; + idPath?: string; + datePath?: string; } ) { + const headers = { + [this.config?.apiKeyAttribute]: config.apiKey, + }; + + if (this.config?.secretKeyAttribute && this.config?.secretKey) { + headers[this.config?.secretKeyAttribute] = config.secretKey; + } + this.axiosInstance = axios.create({ baseURL: config.baseUrl, - headers: { - apiKey: config.apiKey, - secretKey: config.secretKey, - }, + headers, }); } @@ -32,16 +42,31 @@ export class CustomSmsProvider implements ISmsProvider { options: ISmsOptions ): Promise { const response = await this.axiosInstance.request({ - method: 'POST', + method: this.config?.method || 'POST', data: { ...options, from: this.config.from, }, }); - return { - id: response.data.id, - date: response.data.date, - }; + let id = null; + let date = null; + const responseData = response.data; + + if (this.config.idPath) { + const path = this.config.idPath.split('.'); + id = path.reduce((acc, curr) => acc[curr], responseData); + } else { + id = responseData.id; + } + + if (this.config.datePath) { + const path = this.config.datePath.split('.'); + date = path.reduce((acc, curr) => acc[curr], responseData); + } else { + date = responseData.date; + } + + return { id, date }; } } From 39c86376f4a7d4a89d5917a4f4a50a976c91b265 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Thu, 21 Sep 2023 21:04:09 +0300 Subject: [PATCH 04/10] fix: Remove method field and rename some field names --- .../app/integrations/dtos/credentials.dto.ts | 9 +--- .../integration/integration.schema.ts | 4 +- .../credentials/provider-credentials.ts | 19 ++------ .../src/consts/providers/provider.enum.ts | 4 +- .../integration/credential.interface.ts | 4 +- .../sms/handlers/custom-sms.handler.ts | 5 +-- .../custom-sms/src/lib/custom-sms.provider.ts | 44 +++++++++---------- 7 files changed, 33 insertions(+), 56 deletions(-) diff --git a/apps/api/src/app/integrations/dtos/credentials.dto.ts b/apps/api/src/app/integrations/dtos/credentials.dto.ts index 8456fc34b61..9fa2f0f6e6e 100644 --- a/apps/api/src/app/integrations/dtos/credentials.dto.ts +++ b/apps/api/src/app/integrations/dtos/credentials.dto.ts @@ -140,17 +140,12 @@ export class CredentialsDto implements ICredentials { @ApiPropertyOptional() @IsString() @IsOptional() - method?: string; + apiKeyRequestHeader?: string; @ApiPropertyOptional() @IsString() @IsOptional() - apiKeyAttribute?: string; - - @ApiPropertyOptional() - @IsString() - @IsOptional() - secretKeyAttribute?: string; + secretKeyRequestHeader?: string; @ApiPropertyOptional() @IsString() diff --git a/libs/dal/src/repositories/integration/integration.schema.ts b/libs/dal/src/repositories/integration/integration.schema.ts index 0b0c09fdefa..cb91bb21483 100644 --- a/libs/dal/src/repositories/integration/integration.schema.ts +++ b/libs/dal/src/repositories/integration/integration.schema.ts @@ -47,8 +47,8 @@ const integrationSchema = new Schema( hmac: Schema.Types.Boolean, ipPoolName: Schema.Types.String, method: Schema.Types.String, - apiKeyAttribute: Schema.Types.String, - secretKeyAttribute: Schema.Types.String, + apiKeyRequestHeader: Schema.Types.String, + secretKeyRequestHeader: Schema.Types.String, idPath: Schema.Types.String, datePath: Schema.Types.String, }, diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index bd7ceb1fd5e..51c4516d70f 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -749,15 +749,7 @@ export const customSmsConfig: IConfigCredentials[] = [ required: true, }, { - key: CredentialsKeyEnum.Method, - displayName: 'HTTP Method', - type: 'string', - value: 'POST', - description: 'The HTTP method to use when calling the API (GET, POST)', - required: true, - }, - { - key: CredentialsKeyEnum.ApiKeyAttribute, + key: CredentialsKeyEnum.ApiKeyRequestHeader, displayName: 'API Key Attribute', type: 'string', description: 'The name of the header attribute to use for the API key ex. (X-API-KEY, apiKey, ...)', @@ -771,7 +763,7 @@ export const customSmsConfig: IConfigCredentials[] = [ required: true, }, { - key: CredentialsKeyEnum.SecretKeyAttribute, + key: CredentialsKeyEnum.SecretKeyRequestHeader, displayName: 'Secret Key Attribute', type: 'string', description: 'The name of the header attribute to use for the secret key ex. (X-API-SECRET, apiSecret, ...)', @@ -800,10 +792,5 @@ export const customSmsConfig: IConfigCredentials[] = [ description: 'The path to the date field in the response data ex. (date, message.date, ...)', required: true, }, - { - key: CredentialsKeyEnum.From, - displayName: 'From', - type: 'string', - required: false, - }, + ...smsConfigBase, ]; diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index 516638754ac..d58baf293c5 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -28,8 +28,8 @@ export enum CredentialsKeyEnum { Hmac = 'hmac', IpPoolName = 'ipPoolName', Method = 'method', - ApiKeyAttribute = 'apiKeyAttribute', - SecretKeyAttribute = 'secretKeyAttribute', + ApiKeyRequestHeader = 'apiKeyRequestHeader', + SecretKeyRequestHeader = 'secretKeyRequestHeader', IdPath = 'idPath', DatePath = 'datePath', } diff --git a/libs/shared/src/entities/integration/credential.interface.ts b/libs/shared/src/entities/integration/credential.interface.ts index 473047546dd..7a403caa8b7 100644 --- a/libs/shared/src/entities/integration/credential.interface.ts +++ b/libs/shared/src/entities/integration/credential.interface.ts @@ -26,8 +26,8 @@ export interface ICredentials { hmac?: boolean; ipPoolName?: string; method?: string; - apiKeyAttribute?: string; - secretKeyAttribute?: string; + apiKeyRequestHeader?: string; + secretKeyRequestHeader?: string; idPath?: string; datePath?: string; } diff --git a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts index 816a22705bb..52491fb94c3 100644 --- a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts +++ b/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts @@ -13,9 +13,8 @@ export class CustomSmsHandler extends BaseSmsHandler { apiKey: credentials.apiKey, secretKey: credentials.secretKey, from: credentials.from, - method: credentials.method, - apiKeyAttribute: credentials.apiKeyAttribute, - secretKeyAttribute: credentials.secretKeyAttribute, + apiKeyRequestHeader: credentials.apiKeyRequestHeader, + secretKeyRequestHeader: credentials.secretKeyRequestHeader, idPath: credentials.idPath, datePath: credentials.datePath, }); diff --git a/providers/custom-sms/src/lib/custom-sms.provider.ts b/providers/custom-sms/src/lib/custom-sms.provider.ts index 1110c0e4043..d2d835ece07 100644 --- a/providers/custom-sms/src/lib/custom-sms.provider.ts +++ b/providers/custom-sms/src/lib/custom-sms.provider.ts @@ -13,23 +13,22 @@ export class CustomSmsProvider implements ISmsProvider { constructor( private config: { - baseUrl?: string; - apiKey?: string; + baseUrl: string; + apiKeyRequestHeader: string; + apiKey: string; + secretKeyRequestHeader?: string; secretKey?: string; - from?: string; - method?: string; - apiKeyAttribute?: string; - secretKeyAttribute?: string; + from: string; idPath?: string; datePath?: string; } ) { const headers = { - [this.config?.apiKeyAttribute]: config.apiKey, + [this.config?.apiKeyRequestHeader]: config.apiKey, }; - if (this.config?.secretKeyAttribute && this.config?.secretKey) { - headers[this.config?.secretKeyAttribute] = config.secretKey; + if (this.config?.secretKeyRequestHeader && this.config?.secretKey) { + headers[this.config?.secretKeyRequestHeader] = config.secretKey; } this.axiosInstance = axios.create({ @@ -42,31 +41,28 @@ export class CustomSmsProvider implements ISmsProvider { options: ISmsOptions ): Promise { const response = await this.axiosInstance.request({ - method: this.config?.method || 'POST', + method: 'POST', data: { ...options, from: this.config.from, }, }); - let id = null; - let date = null; const responseData = response.data; - if (this.config.idPath) { - const path = this.config.idPath.split('.'); - id = path.reduce((acc, curr) => acc[curr], responseData); - } else { - id = responseData.id; - } + return { + id: this.getResponseValue(this.config.idPath, responseData, 'id'), + date: this.getResponseValue(this.config.datePath, responseData, 'date'), + }; + } + + private getResponseValue(path: string, data: any, attribute: string) { + if (path) { + const pathArray = path.split('.'); - if (this.config.datePath) { - const path = this.config.datePath.split('.'); - date = path.reduce((acc, curr) => acc[curr], responseData); + return pathArray.reduce((acc, curr) => acc[curr], data); } else { - date = responseData.date; + return data[attribute]; } - - return { id, date }; } } From e4b0331a0712acab5a9386a94c93e37c5b45a7eb Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Thu, 21 Sep 2023 22:33:57 +0300 Subject: [PATCH 05/10] refactor: rename the custom sms provider to generic sms --- .../dark/{custom-sms.svg => generic-sms.svg} | 0 .../{custom-sms.svg => generic-sms.svg} | 0 .../light/{custom-sms.svg => generic-sms.svg} | 0 .../{custom-sms.svg => generic-sms.svg} | 0 .../sms/{custom-sms.md => generic-sms.md} | 2 +- .../src/consts/providers/channels/sms.ts | 10 +- .../credentials/provider-credentials.ts | 8 +- .../src/consts/providers/provider.enum.ts | 2 +- novu.code-workspace | 4 +- packages/application-generic/package.json | 2 +- ...-sms.handler.ts => generic-sms.handler.ts} | 8 +- .../src/factories/sms/handlers/index.ts | 2 +- .../src/factories/sms/sms.factory.ts | 4 +- pnpm-lock.yaml | 212 ++++++++---------- providers/custom-sms/README.md | 9 - providers/custom-sms/src/index.ts | 1 - .../src/lib/custom-sms.provider.spec.ts | 3 - providers/{custom-sms => generic-sms}/.czrc | 0 .../.eslintrc.json | 0 .../{custom-sms => generic-sms}/.gitignore | 0 providers/generic-sms/README.md | 9 + .../jest.config.js | 0 .../{custom-sms => generic-sms}/package.json | 4 +- providers/generic-sms/src/index.ts | 1 + .../src/lib/generic-sms.provider.spec.ts | 3 + .../src/lib/generic-sms.provider.ts} | 4 +- .../{custom-sms => generic-sms}/tsconfig.json | 0 .../tsconfig.module.json | 0 28 files changed, 136 insertions(+), 152 deletions(-) rename apps/web/public/static/images/providers/dark/{custom-sms.svg => generic-sms.svg} (100%) rename apps/web/public/static/images/providers/dark/square/{custom-sms.svg => generic-sms.svg} (100%) rename apps/web/public/static/images/providers/light/{custom-sms.svg => generic-sms.svg} (100%) rename apps/web/public/static/images/providers/light/square/{custom-sms.svg => generic-sms.svg} (100%) rename docs/docs/channels/sms/{custom-sms.md => generic-sms.md} (99%) rename packages/application-generic/src/factories/sms/handlers/{custom-sms.handler.ts => generic-sms.handler.ts} (72%) delete mode 100644 providers/custom-sms/README.md delete mode 100644 providers/custom-sms/src/index.ts delete mode 100644 providers/custom-sms/src/lib/custom-sms.provider.spec.ts rename providers/{custom-sms => generic-sms}/.czrc (100%) rename providers/{custom-sms => generic-sms}/.eslintrc.json (100%) rename providers/{custom-sms => generic-sms}/.gitignore (100%) create mode 100644 providers/generic-sms/README.md rename providers/{custom-sms => generic-sms}/jest.config.js (100%) rename providers/{custom-sms => generic-sms}/package.json (95%) create mode 100644 providers/generic-sms/src/index.ts create mode 100644 providers/generic-sms/src/lib/generic-sms.provider.spec.ts rename providers/{custom-sms/src/lib/custom-sms.provider.ts => generic-sms/src/lib/generic-sms.provider.ts} (95%) rename providers/{custom-sms => generic-sms}/tsconfig.json (100%) rename providers/{custom-sms => generic-sms}/tsconfig.module.json (100%) diff --git a/apps/web/public/static/images/providers/dark/custom-sms.svg b/apps/web/public/static/images/providers/dark/generic-sms.svg similarity index 100% rename from apps/web/public/static/images/providers/dark/custom-sms.svg rename to apps/web/public/static/images/providers/dark/generic-sms.svg diff --git a/apps/web/public/static/images/providers/dark/square/custom-sms.svg b/apps/web/public/static/images/providers/dark/square/generic-sms.svg similarity index 100% rename from apps/web/public/static/images/providers/dark/square/custom-sms.svg rename to apps/web/public/static/images/providers/dark/square/generic-sms.svg diff --git a/apps/web/public/static/images/providers/light/custom-sms.svg b/apps/web/public/static/images/providers/light/generic-sms.svg similarity index 100% rename from apps/web/public/static/images/providers/light/custom-sms.svg rename to apps/web/public/static/images/providers/light/generic-sms.svg diff --git a/apps/web/public/static/images/providers/light/square/custom-sms.svg b/apps/web/public/static/images/providers/light/square/generic-sms.svg similarity index 100% rename from apps/web/public/static/images/providers/light/square/custom-sms.svg rename to apps/web/public/static/images/providers/light/square/generic-sms.svg diff --git a/docs/docs/channels/sms/custom-sms.md b/docs/docs/channels/sms/generic-sms.md similarity index 99% rename from docs/docs/channels/sms/custom-sms.md rename to docs/docs/channels/sms/generic-sms.md index 3e61f73e30e..0688d249b20 100644 --- a/docs/docs/channels/sms/custom-sms.md +++ b/docs/docs/channels/sms/generic-sms.md @@ -1,4 +1,4 @@ -# Custom SMS +# Generic SMS The Custom SMS provider allows you to send transactional SMS messages through your own SMS service using the Novu Platform. diff --git a/libs/shared/src/consts/providers/channels/sms.ts b/libs/shared/src/consts/providers/channels/sms.ts index fc61af82e5d..b2716cf1d1e 100644 --- a/libs/shared/src/consts/providers/channels/sms.ts +++ b/libs/shared/src/consts/providers/channels/sms.ts @@ -18,7 +18,7 @@ import { termiiConfig, africasTalkingConfig, sendchampConfig, - customSmsConfig, + genericSmsConfig, } from '../credentials'; import { SmsProviderIdEnum } from '../provider.enum'; @@ -181,11 +181,11 @@ export const smsProviders: IProviderConfig[] = [ logoFileName: { light: 'sendchamp.svg', dark: 'sendchamp.svg' }, }, { - id: SmsProviderIdEnum.CustomSms, - displayName: `Custom SMS`, + id: SmsProviderIdEnum.GenericSms, + displayName: `Generic SMS`, channel: ChannelTypeEnum.SMS, - credentials: customSmsConfig, + credentials: genericSmsConfig, docReference: '', - logoFileName: { light: 'custom-sms.svg', dark: 'custom-sms.svg' }, + logoFileName: { light: 'generic-sms.svg', dark: 'generic-sms.svg' }, }, ]; diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index 51c4516d70f..f3872caff21 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -741,7 +741,7 @@ export const sendchampConfig: IConfigCredentials[] = [ ...smsConfigBase, ]; -export const customSmsConfig: IConfigCredentials[] = [ +export const genericSmsConfig: IConfigCredentials[] = [ { key: CredentialsKeyEnum.BaseUrl, displayName: 'Base URL', @@ -750,7 +750,7 @@ export const customSmsConfig: IConfigCredentials[] = [ }, { key: CredentialsKeyEnum.ApiKeyRequestHeader, - displayName: 'API Key Attribute', + displayName: 'API Key Request Header', type: 'string', description: 'The name of the header attribute to use for the API key ex. (X-API-KEY, apiKey, ...)', required: true, @@ -764,9 +764,9 @@ export const customSmsConfig: IConfigCredentials[] = [ }, { key: CredentialsKeyEnum.SecretKeyRequestHeader, - displayName: 'Secret Key Attribute', + displayName: 'Secret Key Request Header', type: 'string', - description: 'The name of the header attribute to use for the secret key ex. (X-API-SECRET, apiSecret, ...)', + description: 'The name of the header attribute to use for the secret key ex. (X-SECRET-KEY, secretKey, ...)', required: false, }, { diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index d58baf293c5..bac94642be4 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -76,7 +76,7 @@ export enum SmsProviderIdEnum { AfricasTalking = 'africas-talking', Novu = 'novu-sms', Sendchamp = 'sendchamp', - CustomSms = 'custom-sms', + GenericSms = 'generic-sms', } export enum ChatProviderIdEnum { diff --git a/novu.code-workspace b/novu.code-workspace index 403696c7217..f39dfcadbc0 100644 --- a/novu.code-workspace +++ b/novu.code-workspace @@ -181,8 +181,8 @@ "path": "providers/maqsam" }, { - "name": "🔔 @novu/custom-sms", - "path": "providers/custom-sms" + "name": "🔔 @novu/generic-sms", + "path": "providers/generic-sms" } ], "settings": { diff --git a/packages/application-generic/package.json b/packages/application-generic/package.json index a8f57d5b5a2..9e0a4a22568 100644 --- a/packages/application-generic/package.json +++ b/packages/application-generic/package.json @@ -51,7 +51,7 @@ "@novu/apns": "^0.19.0", "@novu/burst-sms": "^0.19.0", "@novu/clickatell": "^0.19.0", - "@novu/custom-sms": "^0.19.0", + "@novu/generic-sms": "^0.19.0", "@novu/dal": "^0.19.0", "@novu/discord": "^0.19.0", "@novu/email-webhook": "^0.19.0", diff --git a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts b/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts similarity index 72% rename from packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts rename to packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts index 52491fb94c3..fcfabfaee71 100644 --- a/packages/application-generic/src/factories/sms/handlers/custom-sms.handler.ts +++ b/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts @@ -1,14 +1,14 @@ -import { CustomSmsProvider } from '@novu/custom-sms'; +import { GenericSmsProvider } from '@novu/generic-sms'; import { ChannelTypeEnum, ICredentials } from '@novu/shared'; import { BaseSmsHandler } from './base.handler'; -export class CustomSmsHandler extends BaseSmsHandler { +export class GenericSmsHandler extends BaseSmsHandler { constructor() { - super('custom-sms', ChannelTypeEnum.SMS); + super('generic-sms', ChannelTypeEnum.SMS); } buildProvider(credentials: ICredentials) { - this.provider = new CustomSmsProvider({ + this.provider = new GenericSmsProvider({ baseUrl: credentials.baseUrl, apiKey: credentials.apiKey, secretKey: credentials.secretKey, diff --git a/packages/application-generic/src/factories/sms/handlers/index.ts b/packages/application-generic/src/factories/sms/handlers/index.ts index e5fb2232b78..282efe5550f 100644 --- a/packages/application-generic/src/factories/sms/handlers/index.ts +++ b/packages/application-generic/src/factories/sms/handlers/index.ts @@ -16,4 +16,4 @@ export * from './sms-central.handler'; export * from './africas-talking.handler'; export * from './sendchamp.handler'; export * from './novu.handler'; -export * from './custom-sms.handler'; +export * from './generic-sms.handler'; diff --git a/packages/application-generic/src/factories/sms/sms.factory.ts b/packages/application-generic/src/factories/sms/sms.factory.ts index 111336a461e..e616c3070ba 100644 --- a/packages/application-generic/src/factories/sms/sms.factory.ts +++ b/packages/application-generic/src/factories/sms/sms.factory.ts @@ -19,7 +19,7 @@ import { AfricasTalkingSmsHandler, SendchampSmsHandler, NovuSmsHandler, - CustomSmsHandler, + GenericSmsHandler, } from './handlers'; export class SmsFactory implements ISmsFactory { @@ -42,7 +42,7 @@ export class SmsFactory implements ISmsFactory { new AfricasTalkingSmsHandler(), new SendchampSmsHandler(), new NovuSmsHandler(), - new CustomSmsHandler(), + new GenericSmsHandler(), ]; getHandler(integration: IntegrationEntity) { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index e6116a30c9b..f123c9d7671 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -613,7 +613,7 @@ importers: react-is: 18.2.0 react-password-strength-bar: 0.4.1_sfoxds7t5ydpegc3knd667wn6m react-router-dom: 6.2.2_sfoxds7t5ydpegc3knd667wn6m - react-scripts: 5.0.1_hsbg2326ej3krilf7s76hyabwu + react-scripts: 5.0.1_sq2rawq4ox4a7yhpjmexqgy4wu react-syntax-highlighter: 15.5.0_react@17.0.2 react-table: 7.8.0_react@17.0.2 react-use-intercom: 2.1.0_sfoxds7t5ydpegc3knd667wn6m @@ -835,7 +835,7 @@ importers: react-is: 18.2.0 react-refresh: 0.14.0 react-router-dom: 6.10.0_sfoxds7t5ydpegc3knd667wn6m - react-scripts: 5.0.1_s7oswrg7wt65hla35vaobymcou + react-scripts: 5.0.1_2xn6hao67zmtzyfac7qsgeyxpu rimraf: 3.0.2 socket.io-client: 4.7.2 web-vitals: 0.2.4 @@ -1419,7 +1419,6 @@ importers: '@novu/apns': ^0.19.0 '@novu/burst-sms': ^0.19.0 '@novu/clickatell': ^0.19.0 - '@novu/custom-sms': ^0.19.0 '@novu/dal': ^0.19.0 '@novu/discord': ^0.19.0 '@novu/email-webhook': ^0.19.0 @@ -1428,6 +1427,7 @@ importers: '@novu/fcm': ^0.19.0 '@novu/firetext': ^0.19.0 '@novu/forty-six-elks': ^0.19.0 + '@novu/generic-sms': ^0.19.0 '@novu/gupshup': ^0.19.0 '@novu/infobip': ^0.19.0 '@novu/kannel': ^0.19.0 @@ -1511,7 +1511,6 @@ importers: '@novu/apns': link:../../providers/apns '@novu/burst-sms': link:../../providers/burst-sms '@novu/clickatell': link:../../providers/clickatell - '@novu/custom-sms': link:../../providers/custom-sms '@novu/dal': link:../../libs/dal '@novu/discord': link:../../providers/discord '@novu/email-webhook': link:../../providers/email-webhook @@ -1520,6 +1519,7 @@ importers: '@novu/fcm': link:../../providers/fcm '@novu/firetext': link:../../providers/firetext '@novu/forty-six-elks': link:../../providers/forty-six-elks + '@novu/generic-sms': link:../../providers/generic-sms '@novu/gupshup': link:../../providers/gupshup '@novu/infobip': link:../../providers/infobip '@novu/kannel': link:../../providers/kannel @@ -2175,37 +2175,6 @@ importers: typedoc: 0.24.6_typescript@4.9.5 typescript: 4.9.5 - providers/custom-sms: - specifiers: - '@istanbuljs/nyc-config-typescript': ~1.0.1 - '@novu/stateless': 0.16.3 - '@types/jest': ~27.5.2 - axios: ^1.5.0 - cspell: ~6.19.2 - jest: ~27.5.1 - npm-run-all: ^4.1.5 - nyc: ~15.1.0 - prettier: ~2.8.0 - rimraf: ~3.0.2 - ts-jest: ~27.1.5 - ts-node: ~10.9.1 - typescript: 4.9.5 - dependencies: - '@novu/stateless': 0.16.3 - axios: 1.5.0 - devDependencies: - '@istanbuljs/nyc-config-typescript': 1.0.2_nyc@15.1.0 - '@types/jest': 27.5.2 - cspell: 6.19.2 - jest: 27.5.1_ts-node@10.9.1 - npm-run-all: 4.1.5 - nyc: 15.1.0 - prettier: 2.8.7 - rimraf: 3.0.2 - ts-jest: 27.1.5_tdguimvmawsauzyxxfukpkg77i - ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna - typescript: 4.9.5 - providers/discord: specifiers: '@istanbuljs/nyc-config-typescript': ^1.0.1 @@ -2475,6 +2444,37 @@ importers: ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna typescript: 4.9.5 + providers/generic-sms: + specifiers: + '@istanbuljs/nyc-config-typescript': ~1.0.1 + '@novu/stateless': 0.16.3 + '@types/jest': ~27.5.2 + axios: ^1.5.0 + cspell: ~6.19.2 + jest: ~27.5.1 + npm-run-all: ^4.1.5 + nyc: ~15.1.0 + prettier: ~2.8.0 + rimraf: ~3.0.2 + ts-jest: ~27.1.5 + ts-node: ~10.9.1 + typescript: 4.9.5 + dependencies: + '@novu/stateless': 0.16.3 + axios: 1.5.0 + devDependencies: + '@istanbuljs/nyc-config-typescript': 1.0.2_nyc@15.1.0 + '@types/jest': 27.5.2 + cspell: 6.19.2 + jest: 27.5.1_ts-node@10.9.1 + npm-run-all: 4.1.5 + nyc: 15.1.0 + prettier: 2.8.7 + rimraf: 3.0.2 + ts-jest: 27.1.5_tdguimvmawsauzyxxfukpkg77i + ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna + typescript: 4.9.5 + providers/gupshup: specifiers: '@babel/preset-env': ^7.13.15 @@ -6814,7 +6814,6 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/types': 7.22.19 - dev: true /@babel/helper-module-imports/7.22.5: resolution: {integrity: sha512-8Dl6+HD/cKifutF5qGd/8ZJi84QeAKh+CEe1sBzz8UayBBGg1dAIJrdHOcOM5b2MpzWL2yuotJTtGjETq0qjXg==} @@ -6937,8 +6936,8 @@ packages: '@babel/core': ^7.0.0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-annotate-as-pure': 7.18.6 + '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-wrap-function': 7.20.5 '@babel/types': 7.22.11 transitivePeerDependencies: @@ -6952,8 +6951,8 @@ packages: '@babel/core': ^7.0.0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-annotate-as-pure': 7.18.6 + '@babel/helper-environment-visitor': 7.18.9 '@babel/helper-wrap-function': 7.20.5 '@babel/types': 7.22.11 transitivePeerDependencies: @@ -7062,7 +7061,6 @@ packages: /@babel/helper-validator-identifier/7.22.20: resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} engines: {node: '>=6.9.0'} - dev: true /@babel/helper-validator-identifier/7.22.5: resolution: {integrity: sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==} @@ -7251,7 +7249,7 @@ packages: dependencies: '@babel/core': 7.20.12 '@babel/helper-environment-visitor': 7.18.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-remap-async-to-generator': 7.18.9_@babel+core@7.20.12 '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.20.12 transitivePeerDependencies: @@ -7266,7 +7264,7 @@ packages: dependencies: '@babel/core': 7.21.4 '@babel/helper-environment-visitor': 7.18.9 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 '@babel/helper-remap-async-to-generator': 7.18.9_@babel+core@7.21.4 '@babel/plugin-syntax-async-generators': 7.8.4_@babel+core@7.21.4 transitivePeerDependencies: @@ -9687,7 +9685,6 @@ packages: '@babel/helper-plugin-utils': 7.22.5 '@babel/plugin-syntax-jsx': 7.22.5_@babel+core@7.22.11 '@babel/types': 7.22.19 - dev: true /@babel/plugin-transform-react-jsx/7.22.5_@babel+core@7.21.4: resolution: {integrity: sha512-rog5gZaVbUip5iWDMTYbVM15XQq+RkUKhET/IHR6oizR+JEoN6CAfTTuHcK4vwUyzca30qqHqEpzBOnaRMWYMA==} @@ -9702,19 +9699,6 @@ packages: '@babel/plugin-syntax-jsx': 7.22.5_@babel+core@7.21.4 '@babel/types': 7.22.11 - /@babel/plugin-transform-react-jsx/7.22.5_@babel+core@7.22.11: - resolution: {integrity: sha512-rog5gZaVbUip5iWDMTYbVM15XQq+RkUKhET/IHR6oizR+JEoN6CAfTTuHcK4vwUyzca30qqHqEpzBOnaRMWYMA==} - engines: {node: '>=6.9.0'} - peerDependencies: - '@babel/core': ^7.0.0-0 - dependencies: - '@babel/core': 7.22.11 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-module-imports': 7.22.5 - '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-jsx': 7.22.5_@babel+core@7.22.11 - '@babel/types': 7.22.11 - /@babel/plugin-transform-react-pure-annotations/7.18.6_@babel+core@7.21.4: resolution: {integrity: sha512-I8VfEPg9r2TRDdvnHgPepTKvuRomzA8+u+nhY7qSI1fR2hRNebasZEETLyM5mAUr0Ku56OkXJ0I7NHJnO6cJiQ==} engines: {node: '>=6.9.0'} @@ -9722,8 +9706,8 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-annotate-as-pure': 7.22.5 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-annotate-as-pure': 7.18.6 + '@babel/helper-plugin-utils': 7.20.2 /@babel/plugin-transform-react-pure-annotations/7.18.6_@babel+core@7.22.11: resolution: {integrity: sha512-I8VfEPg9r2TRDdvnHgPepTKvuRomzA8+u+nhY7qSI1fR2hRNebasZEETLyM5mAUr0Ku56OkXJ0I7NHJnO6cJiQ==} @@ -10854,7 +10838,6 @@ packages: '@babel/helper-string-parser': 7.22.5 '@babel/helper-validator-identifier': 7.22.20 to-fast-properties: 2.0.0 - dev: true /@base2/pretty-print-object/1.0.1: resolution: {integrity: sha512-4iri8i1AqYHJE2DstZYkyEprg6Pq6sKx3xn5FpySk9sNhH7qN2LLlHJCfDTZRILNwQNPD7mATWM0TBui7uC1pA==} @@ -11186,7 +11169,7 @@ packages: cosmiconfig-typescript-loader: 1.0.9_5kbyudrvu2mmx7hr4ww4jk565e cross-spawn: 7.0.3 lodash: 4.17.21 - react-scripts: 5.0.1_s7oswrg7wt65hla35vaobymcou + react-scripts: 5.0.1_2xn6hao67zmtzyfac7qsgeyxpu semver: 7.4.0 webpack-merge: 5.8.0 transitivePeerDependencies: @@ -22292,7 +22275,7 @@ packages: '@types/babel__core': 7.20.0 babel-plugin-react-docgen: 4.2.1 pnp-webpack-plugin: 1.7.0_typescript@4.9.5 - react-scripts: 5.0.1_hsbg2326ej3krilf7s76hyabwu + react-scripts: 5.0.1_sq2rawq4ox4a7yhpjmexqgy4wu semver: 7.5.4 transitivePeerDependencies: - '@types/webpack' @@ -24591,7 +24574,7 @@ packages: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: '@eslint-community/eslint-utils': 4.4.0_eslint@8.38.0 - '@types/json-schema': 7.0.11 + '@types/json-schema': 7.0.12 '@types/semver': 7.3.13 '@typescript-eslint/scope-manager': 5.58.0 '@typescript-eslint/types': 5.58.0 @@ -26567,7 +26550,7 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/compat-data': 7.22.9 + '@babel/compat-data': 7.21.4 '@babel/core': 7.20.12 '@babel/helper-define-polyfill-provider': 0.3.3_@babel+core@7.20.12 semver: 6.3.1 @@ -26580,7 +26563,7 @@ packages: peerDependencies: '@babel/core': ^7.0.0-0 dependencies: - '@babel/compat-data': 7.22.9 + '@babel/compat-data': 7.21.4 '@babel/core': 7.21.4 '@babel/helper-define-polyfill-provider': 0.3.3_@babel+core@7.21.4 semver: 6.3.1 @@ -28899,7 +28882,7 @@ packages: babel-plugin-import: 1.13.6 craco-less: 1.17.0_ir2lcvgs2do7bdjsff3lxwyn5m less-vars-to-js: 1.3.0 - react-scripts: 5.0.1_s7oswrg7wt65hla35vaobymcou + react-scripts: 5.0.1_2xn6hao67zmtzyfac7qsgeyxpu transitivePeerDependencies: - webpack dev: true @@ -28913,7 +28896,7 @@ packages: '@craco/craco': 7.1.0_s2wp4rvkjiflatocn7n5b6ts7m less: 3.13.1 less-loader: 6.2.0_webpack@5.88.2 - react-scripts: 5.0.1_s7oswrg7wt65hla35vaobymcou + react-scripts: 5.0.1_2xn6hao67zmtzyfac7qsgeyxpu transitivePeerDependencies: - webpack dev: true @@ -30957,6 +30940,7 @@ packages: /errno/0.1.8: resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} hasBin: true + requiresBuild: true dependencies: prr: 1.0.1 optional: true @@ -31311,7 +31295,7 @@ packages: eslint: 8.48.0 dev: true - /eslint-config-react-app/7.0.1_6e3crqvhsc4zowdvmj663unuce: + /eslint-config-react-app/7.0.1_sbdixes4cky6hqsocdpcwctiue: resolution: {integrity: sha512-K6rNzvkIeHaTd8m/QEh1Zko0KI7BACWkkneSs6s9cKZC/J27X3eZR6Upt1jkmZ/4FK+XUOPPxMEN7+lbUXfSlA==} engines: {node: '>=14.0.0'} peerDependencies: @@ -31329,7 +31313,7 @@ packages: babel-preset-react-app: 10.0.1 confusing-browser-globals: 1.0.11 eslint: 8.48.0 - eslint-plugin-flowtype: 8.0.3_mrwnvgvutezltl6ldyspvsth6e + eslint-plugin-flowtype: 8.0.3_plg4yf4cnpgca527xiy32s2mgq eslint-plugin-import: 2.27.5_3tkbfgrexmb4pdkflvp7rgxi4q eslint-plugin-jest: 25.7.0_4ouuxk2y2kuljjbleohanxkb34 eslint-plugin-jsx-a11y: 6.7.1_eslint@8.48.0 @@ -31455,7 +31439,7 @@ packages: ignore: 5.2.4 dev: true - /eslint-plugin-flowtype/8.0.3_mrwnvgvutezltl6ldyspvsth6e: + /eslint-plugin-flowtype/8.0.3_plg4yf4cnpgca527xiy32s2mgq: resolution: {integrity: sha512-dX8l6qUL6O+fYPtpNRideCFSpmWOUVx5QcaGLVqe/vlDiBSe4vYljDWDETwnyFzpl7By/WVIu6rcrniCgH9BqQ==} engines: {node: '>=12.0.0'} peerDependencies: @@ -31464,7 +31448,7 @@ packages: eslint: ^8.1.0 dependencies: '@babel/plugin-syntax-flow': 7.22.5_@babel+core@7.22.11 - '@babel/plugin-transform-react-jsx': 7.22.5_@babel+core@7.22.11 + '@babel/plugin-transform-react-jsx': 7.22.15_@babel+core@7.22.11 eslint: 8.48.0 lodash: 4.17.21 string-natural-compare: 3.0.1 @@ -31518,7 +31502,7 @@ packages: minimatch: 3.1.2 object.values: 1.1.6 resolve: 1.22.2 - semver: 6.3.1 + semver: 6.3.0 tsconfig-paths: 3.14.2 transitivePeerDependencies: - eslint-import-resolver-typescript @@ -31727,7 +31711,7 @@ packages: object.values: 1.1.6 prop-types: 15.8.1 resolve: 2.0.0-next.4 - semver: 6.3.1 + semver: 6.3.0 string.prototype.matchall: 4.0.8 /eslint-plugin-spellcheck/0.0.20_eslint@8.38.0: @@ -45001,7 +44985,7 @@ packages: peerDependencies: react-scripts: '>=2.1.3' dependencies: - react-scripts: 5.0.1_hsbg2326ej3krilf7s76hyabwu + react-scripts: 5.0.1_sq2rawq4ox4a7yhpjmexqgy4wu semver: 5.7.1 dev: false @@ -45569,7 +45553,7 @@ packages: react: 17.0.2 dev: false - /react-scripts/5.0.1_hsbg2326ej3krilf7s76hyabwu: + /react-scripts/5.0.1_2xn6hao67zmtzyfac7qsgeyxpu: resolution: {integrity: sha512-8VAmEm/ZAwQzJ+GOMLbBsTdDKOpuZh7RPs0UymvBR2vRk4iZWCskjbFnxqjrzoIvlNNRZ3QJFx6/qDSi6zSnaQ==} engines: {node: '>=14.0.0'} hasBin: true @@ -45582,54 +45566,54 @@ packages: optional: true dependencies: '@babel/core': 7.21.4 - '@pmmmwh/react-refresh-webpack-plugin': 0.5.10_kwexxzmt7sjpqjleraytwi4jvu + '@pmmmwh/react-refresh-webpack-plugin': 0.5.10_aaw3q2lthy6zceet2ugelootve '@svgr/webpack': 5.5.0 babel-jest: 27.5.1_@babel+core@7.21.4 - babel-loader: 8.3.0_2bpkfvz2mezbew2j5yjox7n6pu + babel-loader: 8.3.0_vymqytky47ah5a633vjyq2m3sy babel-plugin-named-asset-import: 0.3.8_@babel+core@7.21.4 babel-preset-react-app: 10.0.1 bfj: 7.0.2 browserslist: 4.21.5 camelcase: 6.3.0 case-sensitive-paths-webpack-plugin: 2.4.0 - css-loader: 6.7.3_webpack@5.78.0 - css-minimizer-webpack-plugin: 3.4.1_rw5du4nyxcvxj5knuew24gpv6a + css-loader: 6.7.3_webpack@5.88.2 + css-minimizer-webpack-plugin: 3.4.1_webpack@5.88.2 dotenv: 10.0.0 dotenv-expand: 5.1.0 eslint: 8.48.0 - eslint-config-react-app: 7.0.1_6e3crqvhsc4zowdvmj663unuce - eslint-webpack-plugin: 3.2.0_hzv2vgrkwrkjb5sk6efnemby4e - file-loader: 6.2.0_webpack@5.78.0 + eslint-config-react-app: 7.0.1_sbdixes4cky6hqsocdpcwctiue + eslint-webpack-plugin: 3.2.0_3hr2pwtplkwedgf6lcivtacw3q + file-loader: 6.2.0_webpack@5.88.2 fs-extra: 10.1.0 - html-webpack-plugin: 5.5.3_webpack@5.78.0 + html-webpack-plugin: 5.5.3_webpack@5.88.2 identity-obj-proxy: 3.0.0 jest: 27.5.1 jest-resolve: 27.5.1 jest-watch-typeahead: 1.1.0_jest@27.5.1 - mini-css-extract-plugin: 2.7.5_webpack@5.78.0 + mini-css-extract-plugin: 2.7.5_webpack@5.88.2 postcss: 8.4.21 postcss-flexbugs-fixes: 5.0.2_postcss@8.4.21 - postcss-loader: 6.2.1_2izhiogyhzv3k6gmxpzxzwhblu + postcss-loader: 6.2.1_spab46aedetttbaa4fvapwm3fq postcss-normalize: 10.0.1_jrpp4geoaqu5dz2gragkckznb4 postcss-preset-env: 7.8.3_postcss@8.4.21 prompts: 2.4.2 react: 17.0.2 react-app-polyfill: 3.0.0 - react-dev-utils: 12.0.1_vq6t4wvflba3b6dvvfvomzl76u + react-dev-utils: 12.0.1_rjadthzu3mzu3rpkl7r437txge react-refresh: 0.11.0 resolve: 1.22.2 resolve-url-loader: 4.0.0 - sass-loader: 12.6.0_webpack@5.78.0 + sass-loader: 12.6.0_webpack@5.88.2 semver: 7.4.0 - source-map-loader: 3.0.2_webpack@5.78.0 - style-loader: 3.3.2_webpack@5.78.0 + source-map-loader: 3.0.2_webpack@5.88.2 + style-loader: 3.3.2_webpack@5.88.2 tailwindcss: 3.3.1_postcss@8.4.21 - terser-webpack-plugin: 5.3.7_dnqqsr3phzjhopay4d6e5ziqz4 + terser-webpack-plugin: 5.3.7_webpack@5.88.2 typescript: 4.9.5 - webpack: 5.78.0_u5c4qderjagc6tepfyiby6xhau - webpack-dev-server: 4.11.1_webpack@5.78.0 - webpack-manifest-plugin: 4.1.1_webpack@5.78.0 - workbox-webpack-plugin: 6.5.4_webpack@5.78.0 + webpack: 5.88.2 + webpack-dev-server: 4.11.1_webpack@5.88.2 + webpack-manifest-plugin: 4.1.1_webpack@5.88.2 + workbox-webpack-plugin: 6.5.4_webpack@5.88.2 optionalDependencies: fsevents: 2.3.3 transitivePeerDependencies: @@ -45665,7 +45649,7 @@ packages: - webpack-hot-middleware - webpack-plugin-serve - /react-scripts/5.0.1_s7oswrg7wt65hla35vaobymcou: + /react-scripts/5.0.1_sq2rawq4ox4a7yhpjmexqgy4wu: resolution: {integrity: sha512-8VAmEm/ZAwQzJ+GOMLbBsTdDKOpuZh7RPs0UymvBR2vRk4iZWCskjbFnxqjrzoIvlNNRZ3QJFx6/qDSi6zSnaQ==} engines: {node: '>=14.0.0'} hasBin: true @@ -45678,54 +45662,54 @@ packages: optional: true dependencies: '@babel/core': 7.21.4 - '@pmmmwh/react-refresh-webpack-plugin': 0.5.10_aaw3q2lthy6zceet2ugelootve + '@pmmmwh/react-refresh-webpack-plugin': 0.5.10_kwexxzmt7sjpqjleraytwi4jvu '@svgr/webpack': 5.5.0 babel-jest: 27.5.1_@babel+core@7.21.4 - babel-loader: 8.3.0_vymqytky47ah5a633vjyq2m3sy + babel-loader: 8.3.0_2bpkfvz2mezbew2j5yjox7n6pu babel-plugin-named-asset-import: 0.3.8_@babel+core@7.21.4 babel-preset-react-app: 10.0.1 bfj: 7.0.2 browserslist: 4.21.5 camelcase: 6.3.0 case-sensitive-paths-webpack-plugin: 2.4.0 - css-loader: 6.7.3_webpack@5.88.2 - css-minimizer-webpack-plugin: 3.4.1_webpack@5.88.2 + css-loader: 6.7.3_webpack@5.78.0 + css-minimizer-webpack-plugin: 3.4.1_rw5du4nyxcvxj5knuew24gpv6a dotenv: 10.0.0 dotenv-expand: 5.1.0 eslint: 8.48.0 - eslint-config-react-app: 7.0.1_6e3crqvhsc4zowdvmj663unuce - eslint-webpack-plugin: 3.2.0_3hr2pwtplkwedgf6lcivtacw3q - file-loader: 6.2.0_webpack@5.88.2 + eslint-config-react-app: 7.0.1_sbdixes4cky6hqsocdpcwctiue + eslint-webpack-plugin: 3.2.0_hzv2vgrkwrkjb5sk6efnemby4e + file-loader: 6.2.0_webpack@5.78.0 fs-extra: 10.1.0 - html-webpack-plugin: 5.5.3_webpack@5.88.2 + html-webpack-plugin: 5.5.3_webpack@5.78.0 identity-obj-proxy: 3.0.0 jest: 27.5.1 jest-resolve: 27.5.1 jest-watch-typeahead: 1.1.0_jest@27.5.1 - mini-css-extract-plugin: 2.7.5_webpack@5.88.2 + mini-css-extract-plugin: 2.7.5_webpack@5.78.0 postcss: 8.4.21 postcss-flexbugs-fixes: 5.0.2_postcss@8.4.21 - postcss-loader: 6.2.1_spab46aedetttbaa4fvapwm3fq + postcss-loader: 6.2.1_2izhiogyhzv3k6gmxpzxzwhblu postcss-normalize: 10.0.1_jrpp4geoaqu5dz2gragkckznb4 postcss-preset-env: 7.8.3_postcss@8.4.21 prompts: 2.4.2 react: 17.0.2 react-app-polyfill: 3.0.0 - react-dev-utils: 12.0.1_rjadthzu3mzu3rpkl7r437txge + react-dev-utils: 12.0.1_vq6t4wvflba3b6dvvfvomzl76u react-refresh: 0.11.0 resolve: 1.22.2 resolve-url-loader: 4.0.0 - sass-loader: 12.6.0_webpack@5.88.2 + sass-loader: 12.6.0_webpack@5.78.0 semver: 7.4.0 - source-map-loader: 3.0.2_webpack@5.88.2 - style-loader: 3.3.2_webpack@5.88.2 + source-map-loader: 3.0.2_webpack@5.78.0 + style-loader: 3.3.2_webpack@5.78.0 tailwindcss: 3.3.1_postcss@8.4.21 - terser-webpack-plugin: 5.3.7_webpack@5.88.2 + terser-webpack-plugin: 5.3.7_dnqqsr3phzjhopay4d6e5ziqz4 typescript: 4.9.5 - webpack: 5.88.2 - webpack-dev-server: 4.11.1_webpack@5.88.2 - webpack-manifest-plugin: 4.1.1_webpack@5.88.2 - workbox-webpack-plugin: 6.5.4_webpack@5.88.2 + webpack: 5.78.0_u5c4qderjagc6tepfyiby6xhau + webpack-dev-server: 4.11.1_webpack@5.78.0 + webpack-manifest-plugin: 4.1.1_webpack@5.78.0 + workbox-webpack-plugin: 6.5.4_webpack@5.78.0 optionalDependencies: fsevents: 2.3.3 transitivePeerDependencies: diff --git a/providers/custom-sms/README.md b/providers/custom-sms/README.md deleted file mode 100644 index ea0346b276f..00000000000 --- a/providers/custom-sms/README.md +++ /dev/null @@ -1,9 +0,0 @@ -# Novu CustomSms Provider - -A CustomSms sms provider library for [@novu/node](https://github.com/novuhq/novu) - -## Usage - -```javascript - FILL IN THE INITIALIZATION USAGE -``` diff --git a/providers/custom-sms/src/index.ts b/providers/custom-sms/src/index.ts deleted file mode 100644 index fea00acaa0a..00000000000 --- a/providers/custom-sms/src/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './lib/custom-sms.provider'; diff --git a/providers/custom-sms/src/lib/custom-sms.provider.spec.ts b/providers/custom-sms/src/lib/custom-sms.provider.spec.ts deleted file mode 100644 index eea347097b2..00000000000 --- a/providers/custom-sms/src/lib/custom-sms.provider.spec.ts +++ /dev/null @@ -1,3 +0,0 @@ -import { CustomSmsProvider } from './custom-sms.provider'; - -test('should trigger custom-sms library correctly', async () => {}); diff --git a/providers/custom-sms/.czrc b/providers/generic-sms/.czrc similarity index 100% rename from providers/custom-sms/.czrc rename to providers/generic-sms/.czrc diff --git a/providers/custom-sms/.eslintrc.json b/providers/generic-sms/.eslintrc.json similarity index 100% rename from providers/custom-sms/.eslintrc.json rename to providers/generic-sms/.eslintrc.json diff --git a/providers/custom-sms/.gitignore b/providers/generic-sms/.gitignore similarity index 100% rename from providers/custom-sms/.gitignore rename to providers/generic-sms/.gitignore diff --git a/providers/generic-sms/README.md b/providers/generic-sms/README.md new file mode 100644 index 00000000000..4da008758f7 --- /dev/null +++ b/providers/generic-sms/README.md @@ -0,0 +1,9 @@ +# Novu GenericSms Provider + +A Generic sms provider library for [@novu/node](https://github.com/novuhq/novu) + +## Usage + +```javascript + FILL IN THE INITIALIZATION USAGE +``` diff --git a/providers/custom-sms/jest.config.js b/providers/generic-sms/jest.config.js similarity index 100% rename from providers/custom-sms/jest.config.js rename to providers/generic-sms/jest.config.js diff --git a/providers/custom-sms/package.json b/providers/generic-sms/package.json similarity index 95% rename from providers/custom-sms/package.json rename to providers/generic-sms/package.json index 540ddf5e710..f7787fdebc4 100644 --- a/providers/custom-sms/package.json +++ b/providers/generic-sms/package.json @@ -1,7 +1,7 @@ { - "name": "@novu/custom-sms", + "name": "@novu/generic-sms", "version": "0.19.0", - "description": "A custom-sms wrapper for novu", + "description": "A generic-sms wrapper for novu", "main": "build/main/index.js", "typings": "build/main/index.d.ts", "module": "build/module/index.js", diff --git a/providers/generic-sms/src/index.ts b/providers/generic-sms/src/index.ts new file mode 100644 index 00000000000..4ad14734a05 --- /dev/null +++ b/providers/generic-sms/src/index.ts @@ -0,0 +1 @@ +export * from './lib/generic-sms.provider'; diff --git a/providers/generic-sms/src/lib/generic-sms.provider.spec.ts b/providers/generic-sms/src/lib/generic-sms.provider.spec.ts new file mode 100644 index 00000000000..a8f58d1e5a9 --- /dev/null +++ b/providers/generic-sms/src/lib/generic-sms.provider.spec.ts @@ -0,0 +1,3 @@ +import { GenericSmsProvider } from './generic-sms.provider'; + +test('should trigger generic-sms library correctly', async () => {}); diff --git a/providers/custom-sms/src/lib/custom-sms.provider.ts b/providers/generic-sms/src/lib/generic-sms.provider.ts similarity index 95% rename from providers/custom-sms/src/lib/custom-sms.provider.ts rename to providers/generic-sms/src/lib/generic-sms.provider.ts index d2d835ece07..950e7c40338 100644 --- a/providers/custom-sms/src/lib/custom-sms.provider.ts +++ b/providers/generic-sms/src/lib/generic-sms.provider.ts @@ -6,8 +6,8 @@ import { } from '@novu/stateless'; import axios, { AxiosInstance } from 'axios'; -export class CustomSmsProvider implements ISmsProvider { - id = 'custom-sms'; +export class GenericSmsProvider implements ISmsProvider { + id = 'generic-sms'; channelType = ChannelTypeEnum.SMS as ChannelTypeEnum.SMS; private axiosInstance: AxiosInstance; diff --git a/providers/custom-sms/tsconfig.json b/providers/generic-sms/tsconfig.json similarity index 100% rename from providers/custom-sms/tsconfig.json rename to providers/generic-sms/tsconfig.json diff --git a/providers/custom-sms/tsconfig.module.json b/providers/generic-sms/tsconfig.module.json similarity index 100% rename from providers/custom-sms/tsconfig.module.json rename to providers/generic-sms/tsconfig.module.json From 9687b67a0032afcabdba871b1953628b1429db3c Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Fri, 22 Sep 2023 08:17:30 +0300 Subject: [PATCH 06/10] test: add test to generic-sms provider --- .../credentials/provider-credentials.ts | 4 +- pnpm-lock.yaml | 145 ++++++------------ providers/generic-sms/jest.config.js | 3 + providers/generic-sms/package.json | 2 +- .../src/lib/generic-sms.provider.spec.ts | 40 ++++- .../src/lib/generic-sms.provider.ts | 19 +-- 6 files changed, 104 insertions(+), 109 deletions(-) diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index f3872caff21..3b001a02e7d 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -780,7 +780,7 @@ export const genericSmsConfig: IConfigCredentials[] = [ key: CredentialsKeyEnum.IdPath, displayName: 'Id Path', type: 'string', - value: 'id', + value: 'data.id', description: 'The path to the id field in the response data ex. (id, message.id, ...)', required: true, }, @@ -788,7 +788,7 @@ export const genericSmsConfig: IConfigCredentials[] = [ key: CredentialsKeyEnum.DatePath, displayName: 'Date Path', type: 'string', - value: 'date', + value: 'data.date', description: 'The path to the date field in the response data ex. (date, message.date, ...)', required: true, }, diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f123c9d7671..79125a8beff 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -2448,7 +2448,7 @@ importers: specifiers: '@istanbuljs/nyc-config-typescript': ~1.0.1 '@novu/stateless': 0.16.3 - '@types/jest': ~27.5.2 + '@types/jest': ~29.5.0 axios: ^1.5.0 cspell: ~6.19.2 jest: ~27.5.1 @@ -2464,14 +2464,14 @@ importers: axios: 1.5.0 devDependencies: '@istanbuljs/nyc-config-typescript': 1.0.2_nyc@15.1.0 - '@types/jest': 27.5.2 + '@types/jest': 29.5.2 cspell: 6.19.2 jest: 27.5.1_ts-node@10.9.1 npm-run-all: 4.1.5 nyc: 15.1.0 prettier: 2.8.7 rimraf: 3.0.2 - ts-jest: 27.1.5_tdguimvmawsauzyxxfukpkg77i + ts-jest: 27.1.5_jt6hjr4g6reedzkbayzypxjbqa ts-node: 10.9.1_wh2cnrlliuuxb2etxm2m3ttgna typescript: 4.9.5 @@ -6284,14 +6284,14 @@ packages: /@babel/code-frame/7.12.11: resolution: {integrity: sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH1RcIw==} dependencies: - '@babel/highlight': 7.18.6 + '@babel/highlight': 7.22.13 dev: true /@babel/code-frame/7.21.4: resolution: {integrity: sha512-LYvhNKfwWSPpocw8GI7gpK2nq3HSDuEPC/uSYaALSJu9xjsalaaYFOq0Pwt5KmVqwEbZlDu81aLXwBOmD/Fv9g==} engines: {node: '>=6.9.0'} dependencies: - '@babel/highlight': 7.18.6 + '@babel/highlight': 7.22.13 /@babel/code-frame/7.22.13: resolution: {integrity: sha512-XktuhWlJ5g+3TJXc5upd9Ks1HutSArik6jf2eAjYFyIOf4ej3RN+184cZbzDvbPnuTJIUhPKKJE3cIsYTiAT3w==} @@ -6612,14 +6612,14 @@ packages: '@babel/core': ^7.0.0 dependencies: '@babel/core': 7.22.11 - '@babel/helper-annotate-as-pure': 7.18.6 - '@babel/helper-environment-visitor': 7.18.9 - '@babel/helper-function-name': 7.21.0 + '@babel/helper-annotate-as-pure': 7.22.5 + '@babel/helper-environment-visitor': 7.22.5 + '@babel/helper-function-name': 7.22.5 '@babel/helper-member-expression-to-functions': 7.21.0 '@babel/helper-optimise-call-expression': 7.18.6 '@babel/helper-replace-supers': 7.20.7 '@babel/helper-skip-transparent-expression-wrappers': 7.20.0 - '@babel/helper-split-export-declaration': 7.18.6 + '@babel/helper-split-export-declaration': 7.22.6 transitivePeerDependencies: - supports-color @@ -6829,7 +6829,7 @@ packages: '@babel/helper-module-imports': 7.21.4 '@babel/helper-simple-access': 7.20.2 '@babel/helper-split-export-declaration': 7.18.6 - '@babel/helper-validator-identifier': 7.19.1 + '@babel/helper-validator-identifier': 7.22.20 '@babel/template': 7.20.7 '@babel/traverse': 7.22.11 '@babel/types': 7.22.11 @@ -6861,7 +6861,7 @@ packages: '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 dev: false /@babel/helper-module-transforms/7.22.9_@babel+core@7.20.12: @@ -6875,7 +6875,7 @@ packages: '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 dev: true /@babel/helper-module-transforms/7.22.9_@babel+core@7.21.4: @@ -6889,7 +6889,7 @@ packages: '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 /@babel/helper-module-transforms/7.22.9_@babel+core@7.22.11: resolution: {integrity: sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==} @@ -6902,7 +6902,7 @@ packages: '@babel/helper-module-imports': 7.22.5 '@babel/helper-simple-access': 7.22.5 '@babel/helper-split-export-declaration': 7.22.6 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 /@babel/helper-optimise-call-expression/7.18.6: resolution: {integrity: sha512-HP59oD9/fEHQkdcbgFCnbmgH5vIQTJbxh2yf+CdM89/glUNnuzr87Q8GIjGEnOktTROemO0Pe0iPAYbqZuOUiA==} @@ -7062,10 +7062,6 @@ packages: resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} engines: {node: '>=6.9.0'} - /@babel/helper-validator-identifier/7.22.5: - resolution: {integrity: sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==} - engines: {node: '>=6.9.0'} - /@babel/helper-validator-option/7.21.0: resolution: {integrity: sha512-rmL/B8/f0mKS2baE9ZpyTcTavvEuWhTTW8amjzXNvYG4AwBsqTLikfXsEofsJEfKHf+HQVQbFOHy6o+4cnC/fQ==} engines: {node: '>=6.9.0'} @@ -7119,19 +7115,11 @@ packages: transitivePeerDependencies: - supports-color - /@babel/highlight/7.18.6: - resolution: {integrity: sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==} - engines: {node: '>=6.9.0'} - dependencies: - '@babel/helper-validator-identifier': 7.22.5 - chalk: 2.4.2 - js-tokens: 4.0.0 - /@babel/highlight/7.22.13: resolution: {integrity: sha512-C/BaXcnnvBCmHTpz/VGZ8jgtE2aYlW4hxDhseJAWZb7gqGM/qtCK6iZUb0TyKFf7BOUsBH7Q7fkRsDRhg1XklQ==} engines: {node: '>=6.9.0'} dependencies: - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 chalk: 2.4.2 js-tokens: 4.0.0 @@ -7292,7 +7280,7 @@ packages: dependencies: '@babel/core': 7.20.12 '@babel/helper-create-class-features-plugin': 7.21.4_@babel+core@7.20.12 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 transitivePeerDependencies: - supports-color dev: true @@ -7305,7 +7293,7 @@ packages: dependencies: '@babel/core': 7.21.4 '@babel/helper-create-class-features-plugin': 7.21.4_@babel+core@7.21.4 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 transitivePeerDependencies: - supports-color @@ -7792,7 +7780,7 @@ packages: dependencies: '@babel/core': 7.20.12 '@babel/helper-create-regexp-features-plugin': 7.21.4_@babel+core@7.20.12 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 dev: true /@babel/plugin-proposal-unicode-property-regex/7.18.6_@babel+core@7.21.4: @@ -7803,7 +7791,7 @@ packages: dependencies: '@babel/core': 7.21.4 '@babel/helper-create-regexp-features-plugin': 7.21.4_@babel+core@7.21.4 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-plugin-utils': 7.20.2 /@babel/plugin-proposal-unicode-property-regex/7.18.6_@babel+core@7.22.11: resolution: {integrity: sha512-2BShG/d5yoZyXZfVePH91urL5wTG6ASZU9M4o03lKK8u8UW1y08OMttBSOADTcJrnPMpvDXRG3G8fyLh4ovs8w==} @@ -7987,6 +7975,16 @@ packages: '@babel/core': 7.21.4 '@babel/helper-plugin-utils': 7.22.5 + /@babel/plugin-syntax-flow/7.21.4_@babel+core@7.22.11: + resolution: {integrity: sha512-l9xd3N+XG4fZRxEP3vXdK6RW7vN1Uf5dxzRC/09wV86wqZ/YYQooBIGNsiRdfNR3/q2/5pPzV4B54J/9ctX5jw==} + engines: {node: '>=6.9.0'} + peerDependencies: + '@babel/core': ^7.0.0-0 + dependencies: + '@babel/core': 7.22.11 + '@babel/helper-plugin-utils': 7.22.5 + dev: true + /@babel/plugin-syntax-flow/7.22.5_@babel+core@7.22.11: resolution: {integrity: sha512-9RdCl0i+q0QExayk2nOS7853w08yLucnnPML6EN9S8fgMPVtdLDCdx/cOQ/i44Lb9UeQX9A35yaqBBOMMZxPxQ==} engines: {node: '>=6.9.0'} @@ -8895,7 +8893,7 @@ packages: dependencies: '@babel/core': 7.22.11 '@babel/helper-plugin-utils': 7.22.5 - '@babel/plugin-syntax-flow': 7.22.5_@babel+core@7.22.11 + '@babel/plugin-syntax-flow': 7.21.4_@babel+core@7.22.11 dev: true /@babel/plugin-transform-flow-strip-types/7.22.5_@babel+core@7.22.11: @@ -9098,8 +9096,10 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.20.12 - '@babel/helper-module-transforms': 7.22.9_@babel+core@7.20.12 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-plugin-utils': 7.20.2 + transitivePeerDependencies: + - supports-color dev: true /@babel/plugin-transform-modules-amd/7.20.11_@babel+core@7.21.4: @@ -9109,8 +9109,10 @@ packages: '@babel/core': ^7.0.0-0 dependencies: '@babel/core': 7.21.4 - '@babel/helper-module-transforms': 7.22.9_@babel+core@7.21.4 - '@babel/helper-plugin-utils': 7.22.5 + '@babel/helper-module-transforms': 7.21.2 + '@babel/helper-plugin-utils': 7.20.2 + transitivePeerDependencies: + - supports-color /@babel/plugin-transform-modules-amd/7.20.11_@babel+core@7.22.11: resolution: {integrity: sha512-NuzCt5IIYOW0O30UvqktzHYR2ud5bOWbY0yaxWZ6G+aFzOMJvrs5YHNikrbdaT15+KNO31nPOy5Fim3ku6Zb5g==} @@ -9193,7 +9195,7 @@ packages: '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-module-transforms': 7.22.9_@babel+core@7.20.12 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.19.1 + '@babel/helper-validator-identifier': 7.22.20 dev: true /@babel/plugin-transform-modules-systemjs/7.20.11_@babel+core@7.21.4: @@ -9206,7 +9208,7 @@ packages: '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-module-transforms': 7.22.9_@babel+core@7.21.4 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.19.1 + '@babel/helper-validator-identifier': 7.22.20 /@babel/plugin-transform-modules-systemjs/7.20.11_@babel+core@7.22.11: resolution: {integrity: sha512-vVu5g9BPQKSFEmvt2TA4Da5N+QVS66EX21d8uoOihC+OCpUoGvzVsXeqFdtAEfVa5BILAeFt+U7yVmLbQnAJmw==} @@ -9232,7 +9234,7 @@ packages: '@babel/helper-hoist-variables': 7.22.5 '@babel/helper-module-transforms': 7.22.9_@babel+core@7.22.11 '@babel/helper-plugin-utils': 7.22.5 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 dev: true /@babel/plugin-transform-modules-umd/7.18.6_@babel+core@7.20.12: @@ -10828,7 +10830,7 @@ packages: engines: {node: '>=6.9.0'} dependencies: '@babel/helper-string-parser': 7.22.5 - '@babel/helper-validator-identifier': 7.22.5 + '@babel/helper-validator-identifier': 7.22.20 to-fast-properties: 2.0.0 /@babel/types/7.22.19: @@ -23093,7 +23095,7 @@ packages: resolution: {integrity: sha512-3UqjCpey6HiTZT92vODYLPxTBWlM8ZOOjr3LX5F37/VRipW2M1kX6I/Cm4VXzteZqfGfagg8yXywpcOgQBlNsQ==} engines: {node: '>=10'} dependencies: - '@babel/code-frame': 7.21.4 + '@babel/code-frame': 7.22.13 '@babel/runtime': 7.21.0 '@types/aria-query': 4.2.2 aria-query: 4.2.2 @@ -29360,12 +29362,12 @@ packages: peerDependencies: webpack: ^5.0.0 dependencies: - icss-utils: 5.1.0_postcss@8.4.25 - postcss: 8.4.25 - postcss-modules-extract-imports: 3.0.0_postcss@8.4.25 - postcss-modules-local-by-default: 4.0.0_postcss@8.4.25 - postcss-modules-scope: 3.0.0_postcss@8.4.25 - postcss-modules-values: 4.0.0_postcss@8.4.25 + icss-utils: 5.1.0_postcss@8.4.29 + postcss: 8.4.29 + postcss-modules-extract-imports: 3.0.0_postcss@8.4.29 + postcss-modules-local-by-default: 4.0.0_postcss@8.4.29 + postcss-modules-scope: 3.0.0_postcss@8.4.29 + postcss-modules-values: 4.0.0_postcss@8.4.29 postcss-value-parser: 4.2.0 semver: 7.5.4 webpack: 5.78.0_u5c4qderjagc6tepfyiby6xhau @@ -34961,14 +34963,6 @@ packages: dependencies: safer-buffer: 2.1.2 - /icss-utils/5.1.0_postcss@8.4.25: - resolution: {integrity: sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==} - engines: {node: ^10 || ^12 || >= 14} - peerDependencies: - postcss: ^8.1.0 - dependencies: - postcss: 8.4.25 - /icss-utils/5.1.0_postcss@8.4.29: resolution: {integrity: sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA==} engines: {node: ^10 || ^12 || >= 14} @@ -43236,14 +43230,6 @@ packages: postcss: 8.4.25 postcss-selector-parser: 6.0.13 - /postcss-modules-extract-imports/3.0.0_postcss@8.4.25: - resolution: {integrity: sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw==} - engines: {node: ^10 || ^12 || >= 14} - peerDependencies: - postcss: ^8.1.0 - dependencies: - postcss: 8.4.25 - /postcss-modules-extract-imports/3.0.0_postcss@8.4.29: resolution: {integrity: sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw==} engines: {node: ^10 || ^12 || >= 14} @@ -43252,17 +43238,6 @@ packages: dependencies: postcss: 8.4.29 - /postcss-modules-local-by-default/4.0.0_postcss@8.4.25: - resolution: {integrity: sha512-sT7ihtmGSF9yhm6ggikHdV0hlziDTX7oFoXtuVWeDd3hHObNkcHRo9V3yg7vCAY7cONyxJC/XXCmmiHHcvX7bQ==} - engines: {node: ^10 || ^12 || >= 14} - peerDependencies: - postcss: ^8.1.0 - dependencies: - icss-utils: 5.1.0_postcss@8.4.25 - postcss: 8.4.25 - postcss-selector-parser: 6.0.13 - postcss-value-parser: 4.2.0 - /postcss-modules-local-by-default/4.0.0_postcss@8.4.29: resolution: {integrity: sha512-sT7ihtmGSF9yhm6ggikHdV0hlziDTX7oFoXtuVWeDd3hHObNkcHRo9V3yg7vCAY7cONyxJC/XXCmmiHHcvX7bQ==} engines: {node: ^10 || ^12 || >= 14} @@ -43274,15 +43249,6 @@ packages: postcss-selector-parser: 6.0.13 postcss-value-parser: 4.2.0 - /postcss-modules-scope/3.0.0_postcss@8.4.25: - resolution: {integrity: sha512-hncihwFA2yPath8oZ15PZqvWGkWf+XUfQgUGamS4LqoP1anQLOsOJw0vr7J7IwLpoY9fatA2qiGUGmuZL0Iqlg==} - engines: {node: ^10 || ^12 || >= 14} - peerDependencies: - postcss: ^8.1.0 - dependencies: - postcss: 8.4.25 - postcss-selector-parser: 6.0.13 - /postcss-modules-scope/3.0.0_postcss@8.4.29: resolution: {integrity: sha512-hncihwFA2yPath8oZ15PZqvWGkWf+XUfQgUGamS4LqoP1anQLOsOJw0vr7J7IwLpoY9fatA2qiGUGmuZL0Iqlg==} engines: {node: ^10 || ^12 || >= 14} @@ -43292,15 +43258,6 @@ packages: postcss: 8.4.29 postcss-selector-parser: 6.0.13 - /postcss-modules-values/4.0.0_postcss@8.4.25: - resolution: {integrity: sha512-RDxHkAiEGI78gS2ofyvCsu7iycRv7oqw5xMWn9iMoR0N/7mf9D50ecQqUo5BZ9Zh2vH4bCUR/ktCqbB9m8vJjQ==} - engines: {node: ^10 || ^12 || >= 14} - peerDependencies: - postcss: ^8.1.0 - dependencies: - icss-utils: 5.1.0_postcss@8.4.25 - postcss: 8.4.25 - /postcss-modules-values/4.0.0_postcss@8.4.29: resolution: {integrity: sha512-RDxHkAiEGI78gS2ofyvCsu7iycRv7oqw5xMWn9iMoR0N/7mf9D50ecQqUo5BZ9Zh2vH4bCUR/ktCqbB9m8vJjQ==} engines: {node: ^10 || ^12 || >= 14} @@ -45064,7 +45021,7 @@ packages: typescript: optional: true dependencies: - '@babel/code-frame': 7.21.4 + '@babel/code-frame': 7.22.13 address: 1.2.2 browserslist: 4.21.10 chalk: 4.1.2 @@ -45105,7 +45062,7 @@ packages: typescript: optional: true dependencies: - '@babel/code-frame': 7.21.4 + '@babel/code-frame': 7.22.13 address: 1.2.2 browserslist: 4.21.10 chalk: 4.1.2 diff --git a/providers/generic-sms/jest.config.js b/providers/generic-sms/jest.config.js index e86e13bab91..61faa20934a 100644 --- a/providers/generic-sms/jest.config.js +++ b/providers/generic-sms/jest.config.js @@ -2,4 +2,7 @@ module.exports = { preset: 'ts-jest', testEnvironment: 'node', + moduleNameMapper: { + axios: 'axios/dist/node/axios.cjs', + }, }; diff --git a/providers/generic-sms/package.json b/providers/generic-sms/package.json index f7787fdebc4..3bf15100deb 100644 --- a/providers/generic-sms/package.json +++ b/providers/generic-sms/package.json @@ -38,7 +38,7 @@ }, "devDependencies": { "@istanbuljs/nyc-config-typescript": "~1.0.1", - "@types/jest": "~27.5.2", + "@types/jest": "~29.5.0", "cspell": "~6.19.2", "jest": "~27.5.1", "npm-run-all": "^4.1.5", diff --git a/providers/generic-sms/src/lib/generic-sms.provider.spec.ts b/providers/generic-sms/src/lib/generic-sms.provider.spec.ts index a8f58d1e5a9..9a94b39d34f 100644 --- a/providers/generic-sms/src/lib/generic-sms.provider.spec.ts +++ b/providers/generic-sms/src/lib/generic-sms.provider.spec.ts @@ -1,3 +1,41 @@ import { GenericSmsProvider } from './generic-sms.provider'; +import crypto from 'crypto'; -test('should trigger generic-sms library correctly', async () => {}); +test('should trigger generic-sms library correctly', async () => { + const provider = new GenericSmsProvider({ + baseUrl: 'https://api.generic-sms-provider.com', + apiKeyRequestHeader: 'apiKey', + apiKey: '123456', + from: 'sender-id', + idPath: 'message.id', + datePath: 'message.date', + }); + + const spy = jest + .spyOn(provider.axiosInstance, 'request') + .mockImplementation(async () => { + return { + data: { + message: { + id: crypto.randomUUID(), + date: new Date().toISOString(), + }, + }, + } as any; + }); + + await provider.sendMessage({ + to: '+1234567890', + content: 'SMS Content form Generic SMS Provider', + }); + + expect(spy).toHaveBeenCalled(); + expect(spy).toHaveBeenCalledWith({ + method: 'POST', + data: { + to: '+1234567890', + content: 'SMS Content form Generic SMS Provider', + sender: 'sender-id', + }, + }); +}); diff --git a/providers/generic-sms/src/lib/generic-sms.provider.ts b/providers/generic-sms/src/lib/generic-sms.provider.ts index 950e7c40338..5eff6138e99 100644 --- a/providers/generic-sms/src/lib/generic-sms.provider.ts +++ b/providers/generic-sms/src/lib/generic-sms.provider.ts @@ -4,12 +4,13 @@ import { ISmsOptions, ISmsProvider, } from '@novu/stateless'; + import axios, { AxiosInstance } from 'axios'; export class GenericSmsProvider implements ISmsProvider { id = 'generic-sms'; channelType = ChannelTypeEnum.SMS as ChannelTypeEnum.SMS; - private axiosInstance: AxiosInstance; + axiosInstance: AxiosInstance; constructor( private config: { @@ -44,25 +45,21 @@ export class GenericSmsProvider implements ISmsProvider { method: 'POST', data: { ...options, - from: this.config.from, + sender: this.config.from, }, }); const responseData = response.data; return { - id: this.getResponseValue(this.config.idPath, responseData, 'id'), - date: this.getResponseValue(this.config.datePath, responseData, 'date'), + id: this.getResponseValue(this.config.idPath || 'id', responseData), + date: this.getResponseValue(this.config.datePath || 'date', responseData), }; } - private getResponseValue(path: string, data: any, attribute: string) { - if (path) { - const pathArray = path.split('.'); + private getResponseValue(path: string, data: any) { + const pathArray = path.split('.'); - return pathArray.reduce((acc, curr) => acc[curr], data); - } else { - return data[attribute]; - } + return pathArray.reduce((acc, curr) => acc[curr], data); } } From 182964776fd9f52875596740d0eb3d407d72039b Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Sun, 24 Sep 2023 12:31:58 +0300 Subject: [PATCH 07/10] feat: add the option to authenticate the request by token --- .../app/integrations/dtos/credentials.dto.ts | 10 ++++++ .../integration/integration.schema.ts | 2 ++ .../credentials/provider-credentials.ts | 28 ++++++++++++++- .../src/consts/providers/provider.enum.ts | 2 ++ .../integration/credential.interface.ts | 2 ++ .../sms/handlers/generic-sms.handler.ts | 3 ++ .../src/lib/generic-sms.provider.ts | 36 +++++++++++++++---- 7 files changed, 76 insertions(+), 7 deletions(-) diff --git a/apps/api/src/app/integrations/dtos/credentials.dto.ts b/apps/api/src/app/integrations/dtos/credentials.dto.ts index 9fa2f0f6e6e..eaed4cdc65f 100644 --- a/apps/api/src/app/integrations/dtos/credentials.dto.ts +++ b/apps/api/src/app/integrations/dtos/credentials.dto.ts @@ -156,4 +156,14 @@ export class CredentialsDto implements ICredentials { @IsString() @IsOptional() datePath?: string; + + @ApiPropertyOptional() + @IsBoolean() + @IsOptional() + authenticateByToken?: boolean; + + @ApiPropertyOptional() + @IsString() + @IsOptional() + authenticationTokenKey?: string; } diff --git a/libs/dal/src/repositories/integration/integration.schema.ts b/libs/dal/src/repositories/integration/integration.schema.ts index cb91bb21483..c5ac4c7523d 100644 --- a/libs/dal/src/repositories/integration/integration.schema.ts +++ b/libs/dal/src/repositories/integration/integration.schema.ts @@ -51,6 +51,8 @@ const integrationSchema = new Schema( secretKeyRequestHeader: Schema.Types.String, idPath: Schema.Types.String, datePath: Schema.Types.String, + authenticateByToken: Schema.Types.Boolean, + authenticationTokenKey: Schema.Types.String, }, active: { type: Schema.Types.Boolean, diff --git a/libs/shared/src/consts/providers/credentials/provider-credentials.ts b/libs/shared/src/consts/providers/credentials/provider-credentials.ts index 3b001a02e7d..0fb12548044 100644 --- a/libs/shared/src/consts/providers/credentials/provider-credentials.ts +++ b/libs/shared/src/consts/providers/credentials/provider-credentials.ts @@ -759,7 +759,7 @@ export const genericSmsConfig: IConfigCredentials[] = [ key: CredentialsKeyEnum.ApiKey, displayName: 'API Key', type: 'string', - description: 'The value of the header attribute to use for the API key', + description: 'The value of the header attribute to use for the API key.', required: true, }, { @@ -792,5 +792,31 @@ export const genericSmsConfig: IConfigCredentials[] = [ description: 'The path to the date field in the response data ex. (date, message.date, ...)', required: true, }, + { + key: CredentialsKeyEnum.AuthenticateByToken, + displayName: 'Authenticate by token', + type: 'switch', + description: 'If enabled, the API key and secret key will be sent as a token in the Authorization header', + required: true, + }, + { + key: CredentialsKeyEnum.Domain, + displayName: 'Auth URL', + type: 'string', + description: 'The URL to use for authentication in case the Authenticate by token option is enabled', + required: false, + tooltip: { + text: 'The URL to use for authentication in case the Authenticate by token option is enabled', + when: true, + }, + }, + { + key: CredentialsKeyEnum.AuthenticationTokenKey, + displayName: 'Authentication Token Key', + type: 'string', + description: + 'The name of the header attribute to use for the authentication token ex. (X-AUTH-TOKEN, auth-token, ...)', + required: false, + }, ...smsConfigBase, ]; diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index bac94642be4..7e7d838182c 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -32,6 +32,8 @@ export enum CredentialsKeyEnum { SecretKeyRequestHeader = 'secretKeyRequestHeader', IdPath = 'idPath', DatePath = 'datePath', + AuthenticateByToken = 'authenticateByToken', + AuthenticationTokenKey = 'authenticationTokenKey', } export enum EmailProviderIdEnum { diff --git a/libs/shared/src/entities/integration/credential.interface.ts b/libs/shared/src/entities/integration/credential.interface.ts index 7a403caa8b7..c178a50f993 100644 --- a/libs/shared/src/entities/integration/credential.interface.ts +++ b/libs/shared/src/entities/integration/credential.interface.ts @@ -30,4 +30,6 @@ export interface ICredentials { secretKeyRequestHeader?: string; idPath?: string; datePath?: string; + authenticateByToken?: boolean; + authenticationTokenKey?: string; } diff --git a/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts b/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts index fcfabfaee71..9975b30f81e 100644 --- a/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts +++ b/packages/application-generic/src/factories/sms/handlers/generic-sms.handler.ts @@ -17,6 +17,9 @@ export class GenericSmsHandler extends BaseSmsHandler { secretKeyRequestHeader: credentials.secretKeyRequestHeader, idPath: credentials.idPath, datePath: credentials.datePath, + domain: credentials.domain, + authenticateByToken: credentials.authenticateByToken, + authenticationTokenKey: credentials.authenticationTokenKey, }); } } diff --git a/providers/generic-sms/src/lib/generic-sms.provider.ts b/providers/generic-sms/src/lib/generic-sms.provider.ts index 5eff6138e99..4694008e403 100644 --- a/providers/generic-sms/src/lib/generic-sms.provider.ts +++ b/providers/generic-sms/src/lib/generic-sms.provider.ts @@ -11,6 +11,7 @@ export class GenericSmsProvider implements ISmsProvider { id = 'generic-sms'; channelType = ChannelTypeEnum.SMS as ChannelTypeEnum.SMS; axiosInstance: AxiosInstance; + headers: Record; constructor( private config: { @@ -22,25 +23,48 @@ export class GenericSmsProvider implements ISmsProvider { from: string; idPath?: string; datePath?: string; + authenticateByToken?: boolean; + domain?: string; + authenticationTokenKey?: string; } ) { - const headers = { + this.headers = { [this.config?.apiKeyRequestHeader]: config.apiKey, }; if (this.config?.secretKeyRequestHeader && this.config?.secretKey) { - headers[this.config?.secretKeyRequestHeader] = config.secretKey; + this.headers[this.config?.secretKeyRequestHeader] = config.secretKey; } - this.axiosInstance = axios.create({ - baseURL: config.baseUrl, - headers, - }); + if (!this.config?.authenticateByToken) { + this.axiosInstance = axios.create({ + baseURL: config.baseUrl, + headers: this.headers, + }); + } } async sendMessage( options: ISmsOptions ): Promise { + if (this.config?.authenticateByToken) { + const tokenAxiosInstance = await axios.request({ + method: 'POST', + baseURL: this.config.domain, + headers: this.headers, + }); + + const token = + tokenAxiosInstance.data.data[this.config.authenticationTokenKey]; + + this.axiosInstance = axios.create({ + baseURL: this.config.baseUrl, + headers: { + [this.config.authenticationTokenKey]: token, + }, + }); + } + const response = await this.axiosInstance.request({ method: 'POST', data: { From b657b7576152f0e4d8df950afdd7089b70ec437e Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Sun, 24 Sep 2023 14:42:19 +0300 Subject: [PATCH 08/10] docs: update provider documentation --- docs/docs/channels/sms/generic-sms.md | 13 +++++-- .../src/consts/providers/channels/sms.ts | 2 +- providers/generic-sms/README.md | 36 ++++++++++++++++++- 3 files changed, 47 insertions(+), 4 deletions(-) diff --git a/docs/docs/channels/sms/generic-sms.md b/docs/docs/channels/sms/generic-sms.md index 0688d249b20..fb2764d536e 100644 --- a/docs/docs/channels/sms/generic-sms.md +++ b/docs/docs/channels/sms/generic-sms.md @@ -7,9 +7,16 @@ The Custom SMS provider allows you to send transactional SMS messages through yo To use the Custom SMS provider within the SMS channel, you'll need to have your own SMS service or access to a service provider that supports sending SMS messages using an API endpoint. You will also need to configure the following parameters in the Custom SMS integration on the Novu platform: - `BaseUrl`: The endpoint URL of your SMS service provider. +- `API Key Request Header`: The request header used for authenticating with the SMS service ex. `x-api-key`. - `API Key`: Your API key for authenticating with the SMS service. +- `Secret Key Request Header` (optional): If your SMS service requires a secret key for authentication, specify the request header used for authenticating with the SMS service. - `Secret Key` (optional): If your SMS service requires a secret key for authentication. -- `From` (optional): The sender information you want to appear on the SMS (e.g., your company name or phone number). +- `Id Path`: The path to the message ID in the response from the SMS service. +- `Date Path`: The path to the message date in the response from the SMS service. +- `From`: The sender information you want to appear on the SMS (e.g., your company name or phone number). +- `Authenticate by token` (optional): If your SMS service requires authentication by token, set this to `true` this option will use the `API key` and `Secret key` to get the access token. +- `Auth URL` (optional): The endpoint URL of your SMS service provider for authentication. +- `Authentication Token Key` (optional): The key of the authentication token in the response from the SMS service. ## Setting Up Custom SMS Integration with Novu @@ -19,9 +26,11 @@ Follow these steps to create a Custom SMS integration with Novu: - **Locate Custom SMS Provider:** You will find "Custom SMS" under SMS Section and click on it to open the integration setup. - **Enter Your SMS Service Credentials:** In the integration setup, provide the following information: - `BaseUrl`: Fill in the endpoint URL of your SMS service provider. + - `API Key Request Header`: Specify the request header used for authenticating with the SMS service. - `API Key`: Enter your API key for authentication. + - `Secret Key Request Header` (optional): If your SMS service requires a secret key, specify the request header used for authenticating with the SMS service. - `Secret Key` (optional): If your SMS service requires a secret key, enter it here. - - `From` (optional): Specify the sender information you want to display on the SMS messages. + - `From`: Specify the sender information you want to display on the SMS messages. - **Activate the Integration:** Click on the "Disabled" button to switch it to "Active." Once you've completed these steps, you can send notifications using the Custom SMS provider through Novu's platform. diff --git a/libs/shared/src/consts/providers/channels/sms.ts b/libs/shared/src/consts/providers/channels/sms.ts index b2716cf1d1e..9fbd38f3b5b 100644 --- a/libs/shared/src/consts/providers/channels/sms.ts +++ b/libs/shared/src/consts/providers/channels/sms.ts @@ -185,7 +185,7 @@ export const smsProviders: IProviderConfig[] = [ displayName: `Generic SMS`, channel: ChannelTypeEnum.SMS, credentials: genericSmsConfig, - docReference: '', + docReference: 'https://docs.novu.co/channels/sms/generic-sms', logoFileName: { light: 'generic-sms.svg', dark: 'generic-sms.svg' }, }, ]; diff --git a/providers/generic-sms/README.md b/providers/generic-sms/README.md index 4da008758f7..4c2330e6019 100644 --- a/providers/generic-sms/README.md +++ b/providers/generic-sms/README.md @@ -5,5 +5,39 @@ A Generic sms provider library for [@novu/node](https://github.com/novuhq/novu) ## Usage ```javascript - FILL IN THE INITIALIZATION USAGE + +import { GenericSmsProvider } from './generic-sms.provider'; + +const provider = new GenericSmsProvider({ + baseUrl: 'https://api.generic-sms-provider.com', + apiKeyRequestHeader: 'apiKey', + apiKey: '123456', + from: 'sender-id', + idPath: 'message.id', + datePath: 'message.date', +}); + +await provider.sendMessage({ + to: '+1234567890', + content: 'SMS Content form Generic SMS Provider', +}); +``` + +## Options +```typescript + +interface GenericSmsProviderOptions { + baseUrl: string; + apiKeyRequestHeader: string; + apiKey: string; + secretKeyRequestHeader?: string; + secretKey?: string; + from: string; + idPath?: string; + datePath?: string; + domain?: string; + authenticateByToken?: boolean; + authenticationTokenKey?: string; +} + ``` From 4c5623575286baf4756bd1aaf609bcd195398ce4 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Wed, 27 Sep 2023 23:00:11 +0300 Subject: [PATCH 09/10] fix: remove method from integration schema file --- libs/dal/src/repositories/integration/integration.schema.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/libs/dal/src/repositories/integration/integration.schema.ts b/libs/dal/src/repositories/integration/integration.schema.ts index c5ac4c7523d..206dbfe0705 100644 --- a/libs/dal/src/repositories/integration/integration.schema.ts +++ b/libs/dal/src/repositories/integration/integration.schema.ts @@ -46,7 +46,6 @@ const integrationSchema = new Schema( redirectUrl: Schema.Types.String, hmac: Schema.Types.Boolean, ipPoolName: Schema.Types.String, - method: Schema.Types.String, apiKeyRequestHeader: Schema.Types.String, secretKeyRequestHeader: Schema.Types.String, idPath: Schema.Types.String, From c182e875591db565ae29b837ed5c4492225b08f0 Mon Sep 17 00:00:00 2001 From: Firass Ziedan Date: Thu, 28 Sep 2023 11:23:18 +0300 Subject: [PATCH 10/10] fix: remove method from the files --- libs/shared/src/consts/providers/provider.enum.ts | 1 - libs/shared/src/entities/integration/credential.interface.ts | 1 - 2 files changed, 2 deletions(-) diff --git a/libs/shared/src/consts/providers/provider.enum.ts b/libs/shared/src/consts/providers/provider.enum.ts index 7e7d838182c..95885ecc3f1 100644 --- a/libs/shared/src/consts/providers/provider.enum.ts +++ b/libs/shared/src/consts/providers/provider.enum.ts @@ -27,7 +27,6 @@ export enum CredentialsKeyEnum { RedirectUrl = 'redirectUrl', Hmac = 'hmac', IpPoolName = 'ipPoolName', - Method = 'method', ApiKeyRequestHeader = 'apiKeyRequestHeader', SecretKeyRequestHeader = 'secretKeyRequestHeader', IdPath = 'idPath', diff --git a/libs/shared/src/entities/integration/credential.interface.ts b/libs/shared/src/entities/integration/credential.interface.ts index c178a50f993..bf87a26f38b 100644 --- a/libs/shared/src/entities/integration/credential.interface.ts +++ b/libs/shared/src/entities/integration/credential.interface.ts @@ -25,7 +25,6 @@ export interface ICredentials { redirectUrl?: string; hmac?: boolean; ipPoolName?: string; - method?: string; apiKeyRequestHeader?: string; secretKeyRequestHeader?: string; idPath?: string;