@servicelabsco/slabs-access-manager 0.1.235 → 0.1.236
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/access/dtos/send.whatsapp.message.payload.dto.d.ts +1 -1
- package/dist/access/dtos/whatsapp.posting.payload.dto.d.ts +9 -2
- package/dist/access/dtos/whatsapp.posting.payload.dto.js.map +1 -1
- package/dist/access/es6.classes.d.ts +2 -1
- package/dist/access/jobs/whatsapp.message.payload.dto.d.ts +3 -15
- package/dist/access/jobs/whatsapp.message.payload.dto.js.map +1 -1
- package/dist/access/libraries/process.whatsapp.message.d.ts +3 -1
- package/dist/access/libraries/process.whatsapp.message.js +15 -13
- package/dist/access/libraries/process.whatsapp.message.js.map +1 -1
- package/dist/access/libraries/send.whatsapp.message.notification.js +13 -16
- package/dist/access/libraries/send.whatsapp.message.notification.js.map +1 -1
- package/dist/access/services/whatsapp.service.d.ts +4 -1
- package/dist/access/services/whatsapp.service.js +17 -17
- package/dist/access/services/whatsapp.service.js.map +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"whatsapp.posting.payload.dto.js","sourceRoot":"","sources":["../../../src/access/dtos/whatsapp.posting.payload.dto.ts"],"names":[],"mappings":";;;AAAA,MAAa,yBAAyB;
|
|
1
|
+
{"version":3,"file":"whatsapp.posting.payload.dto.js","sourceRoot":"","sources":["../../../src/access/dtos/whatsapp.posting.payload.dto.ts"],"names":[],"mappings":";;;AAAA,MAAa,yBAAyB;CAYrC;AAZD,8DAYC"}
|
|
@@ -77,6 +77,7 @@ import { ServerEmailRecipientsDto } from './dtos/server.email.recipients.dto';
|
|
|
77
77
|
import { SlackMessageDataDto } from './dtos/slack.message.data.dto';
|
|
78
78
|
import { StringSearchDto } from './dtos/string.search.dto';
|
|
79
79
|
import { TokenPayloadDto } from './dtos/token.payload.dto';
|
|
80
|
+
import { WhatsappPostingPayloadDto } from './dtos/whatsapp.posting.payload.dto';
|
|
80
81
|
import { AccessBusinessEntity } from './entities/access.business.entity';
|
|
81
82
|
import { BusinessAppIntegrationCredentialEntity } from './entities/business.app.integration.credential.entity';
|
|
82
83
|
import { BusinessAppIntegrationMessagesEntity } from './entities/business.app.integration.messages.entity';
|
|
@@ -401,7 +402,7 @@ import { WhitelistedWhatsappNumberSubscriber } from './subscribers/whitelisted.w
|
|
|
401
402
|
declare const es6Classes: {
|
|
402
403
|
commands: (typeof WebhookPollCommand)[];
|
|
403
404
|
controllers: (typeof AccessMenuController | typeof ApiAccountController | typeof BulkUploadController | typeof BulkUploadItemController | typeof BusinessAppIntegrationController | typeof BusinessNotificationChannelPreferenceController | typeof BusinessPreferenceController | typeof BusinessReportController | typeof BusinessUserGroupController | typeof BusinessUserNotificationPreferenceController | typeof BusinessWebhookController | typeof ChoiceListController | typeof ChoiceTypeController | typeof CommonWebhookController | typeof CustomFieldController | typeof DashboardBuilderController | typeof DashboardComponentController | typeof DashboardController | typeof DashboardReportController | typeof DeveloperModeController | typeof DownloadLogController | typeof EmailRuleController | typeof FcmTokenController | typeof GroupMemberController | typeof GroupRoleController | typeof ListingController | typeof ListingPreferenceController | typeof ScheduledReportController | typeof ScheduledReportItemController | typeof TagController | typeof UserBusinessSecretController | typeof UserNotificationController | typeof UserPreferenceController)[];
|
|
404
|
-
dtos: (typeof FcmTemplateAttributesDto | typeof NotificationPayloadDto | typeof SendEmailNotificationDataDto | typeof GchatPostingPayloadDto | typeof BoardCastInternalStatusMessageDto | typeof SendWhatsappMessagePayloadDto | typeof AddShortUrlDto | typeof BankAccountPayloadDto | typeof RecurringDefinitionDto | typeof EmailMessageNormalizedDto | typeof SendWebhookRequestPayload | typeof AccessBusinessParamDto | typeof DateRangeFilterDto | typeof DateFilterDto | typeof ListResponseFormatDto | typeof NumberRangeFilterDto | typeof CommonListFilterDto | typeof DbFindDto | typeof ListResponseDto | typeof AddListingPreferenceDto | typeof ProcessCommonListConfigDto | typeof AddIntegrationPreferenceDto | typeof AddBusinessPreferenceDto | typeof GenerateBusinessReportDto | typeof AddBusinessUserNotificationPreferenceDto | typeof AddWebhookDto | typeof ModifyCustomFieldStatusDto | typeof GetScriptValuesDto | typeof AddDashboardComponentPropertiesDto | typeof AddDashboardComponentDto | typeof StringSearchDto | typeof EditQueryDto | typeof TokenPayloadDto | typeof AddGroupMemberDto | typeof AddRoleDto | typeof AddScheduledReportDto | typeof AddBusinessAppIntegrationDto | typeof AddConversationDto | typeof AddTagDto | typeof BusinessAppIntegrationMessagePayloadDto | typeof ProcessListingPayloadDto | typeof RequestLogOptionsDto | typeof ServerEmailRecipientsDto | typeof ServerEmailMessageDto | typeof SlackMessageDataDto)[];
|
|
405
|
+
dtos: (typeof FcmTemplateAttributesDto | typeof NotificationPayloadDto | typeof SendEmailNotificationDataDto | typeof GchatPostingPayloadDto | typeof BoardCastInternalStatusMessageDto | typeof WhatsappPostingPayloadDto | typeof SendWhatsappMessagePayloadDto | typeof AddShortUrlDto | typeof BankAccountPayloadDto | typeof RecurringDefinitionDto | typeof EmailMessageNormalizedDto | typeof SendWebhookRequestPayload | typeof AccessBusinessParamDto | typeof DateRangeFilterDto | typeof DateFilterDto | typeof ListResponseFormatDto | typeof NumberRangeFilterDto | typeof CommonListFilterDto | typeof DbFindDto | typeof ListResponseDto | typeof AddListingPreferenceDto | typeof ProcessCommonListConfigDto | typeof AddIntegrationPreferenceDto | typeof AddBusinessPreferenceDto | typeof GenerateBusinessReportDto | typeof AddBusinessUserNotificationPreferenceDto | typeof AddWebhookDto | typeof ModifyCustomFieldStatusDto | typeof GetScriptValuesDto | typeof AddDashboardComponentPropertiesDto | typeof AddDashboardComponentDto | typeof StringSearchDto | typeof EditQueryDto | typeof TokenPayloadDto | typeof AddGroupMemberDto | typeof AddRoleDto | typeof AddScheduledReportDto | typeof AddBusinessAppIntegrationDto | typeof AddConversationDto | typeof AddTagDto | typeof BusinessAppIntegrationMessagePayloadDto | typeof ProcessListingPayloadDto | typeof RequestLogOptionsDto | typeof ServerEmailRecipientsDto | typeof ServerEmailMessageDto | typeof SlackMessageDataDto)[];
|
|
405
406
|
entities: (typeof AccessBusinessEntity | typeof BusinessUserEntity | typeof ProductEntity | typeof EmailStyleEntity | typeof EmailTemplateLogEntity | typeof FcmMessageEntity | typeof FcmTokenEntity | typeof GchatUserEntity | typeof GchatMessageEntity | typeof GchatWebhookMessageEntity | typeof SlackMessageEntity | typeof BzNotificationChannelPreferenceEntity | typeof SlackIntegrationEntity | typeof SlackUserEntity | typeof WhatsappMessageEntity | typeof WhatsappPreferenceEntity | typeof BusinessAppIntegrationCredentialEntity | typeof BusinessAppIntegrationMessagesEntity | typeof BusinessDownloadableReportEntity | typeof BusinessEmailEntity | typeof BusinessGroupRoleEntity | typeof MenuRoleEntity | typeof MenuEntity | typeof UiActionRoleEntity | typeof MenuActionEntity | typeof ChildMenuEntity | typeof BusinessMenuEntity | typeof BusinessReportEntity | typeof GroupRoleEntity | typeof BusinessUserRoleEntity | typeof BusinessWebhookEntity | typeof ConversationEntity | typeof DashboardComponentEntity | typeof DownloadLogEntity | typeof EmailRecipientEntity | typeof EmailMessageEntity | typeof GroupMemberEntity | typeof PreferenceUserEntity | typeof PreferenceUserGroupEntity | typeof ModuleMenuEntity | typeof RequestLogEntity | typeof ScheduledReportEntity | typeof ScheduledReportEmailEntity | typeof ScheduledReportItemEntity | typeof SlackWebhookMessageEntity | typeof UserNotificationEntity | typeof UserRoleEntity | typeof WatchlistAssignmentEntity | typeof WebhookLogEntity | typeof WebhookSlugEntity)[];
|
|
406
407
|
enums: (typeof NotificationTypeEnum | typeof NotificationChannelTypeEnum | typeof RecurringPeriodEnum | typeof CustomColumnTypeEnum | typeof ProductTypeEnum | typeof PlatformTypeEnum)[];
|
|
407
408
|
jobs: (typeof WhatsappMessagePayloadDto | typeof EvaluateEmailRuleJob | typeof AccessTestJob | typeof ApiAccountJob | typeof AppIntegrationJob | typeof BusinessAppIntegrationCredentialJob | typeof BusinessAppIntegrationJob | typeof BusinessAppIntegrationMessagesJob | typeof BusinessDownloadableReportJob | typeof BusinessEmailJob | typeof BusinessGroupRoleJob | typeof BusinessMenuJob | typeof BusinessPreferenceJob | typeof GenerateBusinessReportJob | typeof BusinessReportJob | typeof BusinessUserGroupJob | typeof BusinessUserJob | typeof BusinessUserNotificationPreferenceJob | typeof BusinessUserRoleJob | typeof BusinessWebhookJob | typeof BzNotificationChannelPreferenceJob | typeof ChildMenuJob | typeof ChoiceListJob | typeof ChoiceTypeJob | typeof ConversationJob | typeof CustomFieldJob | typeof CustomReportJob | typeof DashboardComponentJob | typeof DashboardJob | typeof DownloadLogJob | typeof EmailAttachmentJob | typeof EmailMessageJob | typeof EmailRecipientJob | typeof EmailRuleJob | typeof EmailStyleJob | typeof EmailTemplateLogJob | typeof FcmMessageJob | typeof FcmNotificationJob | typeof FcmTemplateJob | typeof FcmTokenJob | typeof GchatIncomingWebhookJob | typeof GchatMessageJob | typeof GchatTemplateJob | typeof GchatUserJob | typeof GchatWebhookJob | typeof GchatWebhookMessageJob | typeof GroupMemberJob | typeof GroupRoleJob | typeof ListPreferenceJob | typeof ListingColumnJob | typeof ListingPageJob | typeof ListingPreferenceJob | typeof MenuActionJob | typeof MenuJob | typeof MenuRoleJob | typeof ModuleJob | typeof ModuleMenuJob | typeof PreferenceUserGroupJob | typeof PreferenceUsersJob | typeof ProcessServerEmailJob | typeof ProductJob | typeof RequestLogJob | typeof RoleGroupJob | typeof ScheduledReportEmailJob | typeof ScheduledReportItemJob | typeof ScheduledReportJob | typeof SlackIncomingWebhookJob | typeof SlackIntegrationJob | typeof SlackMessageJob | typeof SlackTemplateJob | typeof SlackUserJob | typeof SlackWebhookJob | typeof SlackWebhookMessageJob | typeof SyncBURoleJob | typeof UiActionJob | typeof UiActionRoleJob | typeof UserBusinessSecretJob | typeof UserNotificationJob | typeof UserPreferenceJob | typeof UserRoleJob | typeof WatchlistAssignmentJob | typeof WebhookEventJob | typeof WebhookLogJob | typeof WebhookSlugJob | typeof WebhookTypeJob | typeof WhatsappIncomingWebhookJob | typeof WhatsappMessageJob | typeof WhatsappTemplateJob | typeof WhitelistedWhatsappNumberJob)[];
|
|
@@ -1,24 +1,12 @@
|
|
|
1
|
-
type receiversObject = {
|
|
2
|
-
whatsappNumber: string;
|
|
3
|
-
customParams: [
|
|
4
|
-
{
|
|
5
|
-
name: string;
|
|
6
|
-
value: string;
|
|
7
|
-
}
|
|
8
|
-
];
|
|
9
|
-
};
|
|
10
1
|
export declare class WhatsappMessagePayloadDto {
|
|
11
2
|
number: number;
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
name: string;
|
|
3
|
+
template_identifier: string;
|
|
4
|
+
variables?: {
|
|
5
|
+
key: string;
|
|
16
6
|
value: string;
|
|
17
7
|
}[];
|
|
18
|
-
receivers?: receiversObject[];
|
|
19
8
|
custom_params?: {
|
|
20
9
|
name: string;
|
|
21
10
|
value: string;
|
|
22
11
|
}[];
|
|
23
12
|
}
|
|
24
|
-
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"whatsapp.message.payload.dto.js","sourceRoot":"","sources":["../../../src/access/jobs/whatsapp.message.payload.dto.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"whatsapp.message.payload.dto.js","sourceRoot":"","sources":["../../../src/access/jobs/whatsapp.message.payload.dto.ts"],"names":[],"mappings":";;;AAAA,MAAa,yBAAyB;CAWrC;AAXD,8DAWC"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { PropertyService } from '@servicelabsco/nestjs-utility-services';
|
|
2
2
|
import { WhatsappMessagePayloadDto } from '../jobs/whatsapp.message.payload.dto';
|
|
3
|
+
import { WhatsappService } from '../services/whatsapp.service';
|
|
3
4
|
export declare class ProcessWhatsappMessage {
|
|
4
5
|
private readonly propertyService;
|
|
6
|
+
private readonly whatsappService;
|
|
5
7
|
protected payload: WhatsappMessagePayloadDto;
|
|
6
8
|
protected endPoint: string;
|
|
7
|
-
constructor(propertyService: PropertyService);
|
|
9
|
+
constructor(propertyService: PropertyService, whatsappService: WhatsappService);
|
|
8
10
|
process(payload: WhatsappMessagePayloadDto): Promise<any>;
|
|
9
11
|
send(apiUrl: string, params: any): Promise<any>;
|
|
10
12
|
private getRequestData;
|
|
@@ -3,16 +3,14 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.ProcessWhatsappMessage = void 0;
|
|
4
4
|
const nestjs_utility_services_1 = require("@servicelabsco/nestjs-utility-services");
|
|
5
5
|
class ProcessWhatsappMessage {
|
|
6
|
-
constructor(propertyService) {
|
|
6
|
+
constructor(propertyService, whatsappService) {
|
|
7
7
|
this.propertyService = propertyService;
|
|
8
|
-
this.
|
|
8
|
+
this.whatsappService = whatsappService;
|
|
9
|
+
this.endPoint = 'v1/sendTemplateMessage';
|
|
9
10
|
}
|
|
10
11
|
async process(payload) {
|
|
11
|
-
const isMultiple = payload?.receivers?.length >= 1;
|
|
12
12
|
this.payload = payload;
|
|
13
|
-
|
|
14
|
-
this.endPoint = 'api/v2/sendTemplateMessages';
|
|
15
|
-
const { apiUrl, classParams } = await this.getRequestData(isMultiple);
|
|
13
|
+
const { apiUrl, classParams } = await this.getRequestData();
|
|
16
14
|
return this.send(apiUrl, classParams);
|
|
17
15
|
}
|
|
18
16
|
async send(apiUrl, params) {
|
|
@@ -27,19 +25,23 @@ class ProcessWhatsappMessage {
|
|
|
27
25
|
console.error('Error:', error);
|
|
28
26
|
}
|
|
29
27
|
}
|
|
30
|
-
async getRequestData(
|
|
28
|
+
async getRequestData() {
|
|
31
29
|
const baseUrl = await this.getEndPoints();
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
const token = await this.getAuthorizationToken();
|
|
35
|
-
const { broadcast_name = 'Finnoto Solutions', data: parameters, template_name, receivers, custom_params } = this.payload;
|
|
30
|
+
const apiUrl = `${baseUrl}/${this.endPoint}`;
|
|
31
|
+
const { client_id, client_secret } = await this.whatsappService.getClientSecret();
|
|
36
32
|
const classParams = {
|
|
37
33
|
method: 'POST',
|
|
38
34
|
headers: {
|
|
39
35
|
'Content-Type': 'application/json',
|
|
40
|
-
|
|
36
|
+
'x-client-id': client_id,
|
|
37
|
+
'x-client-secret': client_secret,
|
|
41
38
|
},
|
|
42
|
-
body: JSON.stringify({
|
|
39
|
+
body: JSON.stringify({
|
|
40
|
+
dialing_code: 91,
|
|
41
|
+
mobile: this.payload.number,
|
|
42
|
+
template_identifier: this.payload.template_identifier,
|
|
43
|
+
variables: this.payload.variables,
|
|
44
|
+
}),
|
|
43
45
|
};
|
|
44
46
|
return {
|
|
45
47
|
apiUrl,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"process.whatsapp.message.js","sourceRoot":"","sources":["../../../src/access/libraries/process.whatsapp.message.ts"],"names":[],"mappings":";;;AAAA,oFAA6F;
|
|
1
|
+
{"version":3,"file":"process.whatsapp.message.js","sourceRoot":"","sources":["../../../src/access/libraries/process.whatsapp.message.ts"],"names":[],"mappings":";;;AAAA,oFAA6F;AAS7F,MAAa,sBAAsB;IAI/B,YACqB,eAAgC,EAChC,eAAgC;QADhC,oBAAe,GAAf,eAAe,CAAiB;QAChC,oBAAe,GAAf,eAAe,CAAiB;QAJ3C,aAAQ,GAAG,wBAAwB,CAAC;IAK3C,CAAC;IAEJ,KAAK,CAAC,OAAO,CAAC,OAAkC;QAC5C,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;QAEvB,MAAM,EAAE,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,IAAI,CAAC,cAAc,EAAE,CAAC;QAC5D,OAAO,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;IAC1C,CAAC;IAED,KAAK,CAAC,IAAI,CAAC,MAAc,EAAE,MAAW;QAClC,IAAI,CAAC;YACD,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;YAC7C,IAAI,CAAC,QAAQ,CAAC,EA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ageNotification {
|
|
|
11
11
|
this.whatsappService = whatsappService;
|
|
12
12
|
}
|
|
13
13
|
async process(payload) {
|
|
14
|
-
this.token = await this.whatsappService.getAuthorizationToken();
|
|
15
|
-
if (!this.token)
|
|
16
|
-
return;
|
|
17
14
|
this.payload = payload;
|
|
18
15
|
for (const user of this.payload.user_ids) {
|
|
19
16
|
const isAllowed = await this.whatsappService.isAllowedOnWhatsapp({
|
|
@@ -32,15 +29,17 @@ class SendWhatsappMessageNotification {
|
|
|
32
29
|
const user = await nestjs_utility_services_1.UserEntity.first(userId);
|
|
33
30
|
if (!user)
|
|
34
31
|
return;
|
|
35
|
-
const dialCode = user.dialing_code
|
|
36
|
-
const
|
|
37
|
-
const endPoint = await this.getEndpoint(number);
|
|
38
|
-
const token = await this.whatsappService.getAuthorizationToken();
|
|
32
|
+
const dialCode = user.dialing_code || 91;
|
|
33
|
+
const endPoint = await this.getEndpoint();
|
|
39
34
|
const data = await this.getRequestData(this.payload.data, notification.template);
|
|
40
35
|
const options = {
|
|
41
36
|
endPoint,
|
|
42
|
-
|
|
43
|
-
|
|
37
|
+
data: {
|
|
38
|
+
dialing_code: dialCode,
|
|
39
|
+
mobile: user.mobile,
|
|
40
|
+
template_identifier: data?.template_name,
|
|
41
|
+
variables: data?.parameters,
|
|
42
|
+
},
|
|
44
43
|
};
|
|
45
44
|
const response = await this.whatsappService.sendMessage(options);
|
|
46
45
|
return this.logMessage(userId, notification, data, response.data);
|
|
@@ -68,16 +67,14 @@ class SendWhatsappMessageNotification {
|
|
|
68
67
|
variables.forEach((variable) => {
|
|
69
68
|
if (!data.hasOwnProperty(variable))
|
|
70
69
|
return;
|
|
71
|
-
parameters.push({
|
|
70
|
+
parameters.push({ key: variable, value: data[variable] });
|
|
72
71
|
});
|
|
73
72
|
return parameters;
|
|
74
73
|
}
|
|
75
|
-
async getEndpoint(
|
|
74
|
+
async getEndpoint() {
|
|
76
75
|
const baseUrl = await this.getbaseUrl();
|
|
77
|
-
const subAddress = '
|
|
78
|
-
|
|
79
|
-
const url = `${baseUrl}/${subAddress}${queryParams}`;
|
|
80
|
-
return url;
|
|
76
|
+
const subAddress = 'v1/sendTemplateMessage';
|
|
77
|
+
return `${baseUrl}/${subAddress}`;
|
|
81
78
|
}
|
|
82
79
|
async getbaseUrl() {
|
|
83
80
|
return await this.propertyService.get('whatsapp.message.api.base.url', false);
|
|
@@ -95,7 +92,7 @@ class SendWhatsappMessageNotification {
|
|
|
95
92
|
response,
|
|
96
93
|
source_id: this.payload.source.source_id,
|
|
97
94
|
source_type: this.payload.source.source_type,
|
|
98
|
-
message_identifier: response?.
|
|
95
|
+
message_identifier: response?.messages[0]?.id,
|
|
99
96
|
attributes: this.payload?.attributes,
|
|
100
97
|
});
|
|
101
98
|
return wm.save();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"send.whatsapp.message.notification.js","sourceRoot":"","sources":["../../../src/access/libraries/send.whatsapp.message.notification.ts"],"names":[],"mappings":";;;AAAA,oFAAsG;AAKtG,iFAA4E;AAC5E,4EAAuE;AAOvE,MAAa,+BAA+B;IAIxC,YACqB,YAAwC,EACxC,eAAgC,EAChC,eAAgC;QAFhC,iBAAY,GAAZ,YAAY,CAA4B;QACxC,oBAAe,GAAf,eAAe,CAAiB;QAChC,oBAAe,GAAf,eAAe,CAAiB;IAClD,CAAC;IAEJ,KAAK,CAAC,OAAO,CAAC,OAA+B;QACzC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"send.whatsapp.message.notification.js","sourceRoot":"","sources":["../../../src/access/libraries/send.whatsapp.message.notification.ts"],"names":[],"mappings":";;;AAAA,oFAAsG;AAKtG,iFAA4E;AAC5E,4EAAuE;AAOvE,MAAa,+BAA+B;IAIxC,YACqB,YAAwC,EACxC,eAAgC,EAChC,eAAgC;QAFhC,iBAAY,GAAZ,YAAY,CAA4B;QACxC,oBAAe,GAAf,eAAe,CAAiB;QAChC,oBAAe,GAAf,eAAe,CAAiB;IAClD,CAAC;IAEJ,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,KAAK,CAAC,WAAW;QACrB,MAAM,OAAO,GAAG,MAAM,IAAI,CAAC,UAAU,EAAE,CAAC;QAExC,MAAM,UAAU,GAAG,wBAAwB,CAAC;QAC5C,OAAO,GAAG,OAAO,IAAI,UAAU,EAAE,CAAC;IACtC,CAAC;IAEO,KAAK,CAAC,UAAU;QACpB,OAAO,MAAM,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,+BAA+B,EAAE,KAAK,CAAC,CAAC;IAClF,CAAC;IAEO,KAAK,CAAC,gBAAgB;QAC1B,OAAO,MAAM,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,iCAAiC,EAAE,SAAS,CAAC,CAAC;IACxF,CAAC;IAEO,KAAK,CAAC,UAAU,CAAC,OAAe,EAAE,YAAwC,EAAE,OAAY,EAAE,QAAa;QAC3G,MAAM,EAAE,GAAG,+CAAqB,CAAC,MAAM,CAAC;YACpC,WAAW,EAAE,IAAI,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE;YACrC,OAAO;YACP,wBAAwB,EAAE,YAAY,CAAC,EAAE;YACzC,OAAO,EAAE,6CAAoB,CAAC,OAAO;YACrC,OAAO;YACP,QAAQ;YACR,SAAS,EAAE,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,SAAS;YACxC,WAAW,EAAE,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,WAAW;YAC5C,kBAAkB,EAAE,QAAQ,EAAE,QAAQ,CAAC,CAAC,CAAC,EAAE,EAAE;YAC7C,UAAU,EAAE,IAAI,CAAC,OAAO,EAAE,UAAU;SACvC,CAAC,CAAC;QAEH,OAAO,EAAE,CAAC,IAAI,EAAE,CAAC;IACrB,CAAC;CACJ;AArHD,0EAqHC"}
|
|
@@ -7,7 +7,10 @@ export declare class WhatsappService {
|
|
|
7
7
|
protected readonly cacheService: CacheService;
|
|
8
8
|
private readonly propertyService;
|
|
9
9
|
constructor(remoteRequestService: RemoteRequestService, cacheService: CacheService, propertyService: PropertyService);
|
|
10
|
-
|
|
10
|
+
getClientSecret(): Promise<{
|
|
11
|
+
client_id: string;
|
|
12
|
+
client_secret: string;
|
|
13
|
+
}>;
|
|
11
14
|
hasWhatsappEnabled(business_id: number, user_id: number): Promise<boolean>;
|
|
12
15
|
sendMessage(options: WhatsappPostingPayloadDto): Promise<import("@servicelabsco/nestjs-utility-services").RemoteRawResponseDto>;
|
|
13
16
|
hasBusinessWhatsappEnabled(business_id: number): Promise<boolean>;
|
|
@@ -28,15 +28,13 @@ let WhatsappService = class WhatsappService {
|
|
|
28
28
|
this.cacheService = cacheService;
|
|
29
29
|
this.propertyService = propertyService;
|
|
30
30
|
}
|
|
31
|
-
async
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
throw new nestjs_utility_services_1.OperationException(`token is not setup for wati`);
|
|
39
|
-
return `Bearer ${token}`;
|
|
31
|
+
async getClientSecret() {
|
|
32
|
+
const client_secret = await this.propertyService.get('whatsapp.client.secret');
|
|
33
|
+
const client_id = await this.propertyService.get('whatsapp.client.id');
|
|
34
|
+
return {
|
|
35
|
+
client_id,
|
|
36
|
+
client_secret,
|
|
37
|
+
};
|
|
40
38
|
}
|
|
41
39
|
async hasWhatsappEnabled(business_id, user_id) {
|
|
42
40
|
const preference = await whatsapp_preference_entity_1.WhatsappPreferenceEntity.findOne({ where: { business_id, user_id } });
|
|
@@ -45,13 +43,15 @@ let WhatsappService = class WhatsappService {
|
|
|
45
43
|
return preference.active;
|
|
46
44
|
}
|
|
47
45
|
async sendMessage(options) {
|
|
48
|
-
const { data, endPoint
|
|
46
|
+
const { data, endPoint } = options;
|
|
47
|
+
const { client_id, client_secret } = await this.getClientSecret();
|
|
49
48
|
const opts = {
|
|
50
49
|
url: endPoint,
|
|
51
50
|
method: 'POST',
|
|
52
51
|
headers: {
|
|
53
52
|
'Content-Type': 'application/json',
|
|
54
|
-
|
|
53
|
+
'x-client-id': client_id,
|
|
54
|
+
'x-client-secret': client_secret,
|
|
55
55
|
},
|
|
56
56
|
data,
|
|
57
57
|
};
|
|
@@ -118,10 +118,10 @@ let WhatsappService = class WhatsappService {
|
|
|
118
118
|
const isProd = nestjs_utility_services_1.PlatformUtility.isProductionEnvironment();
|
|
119
119
|
if (!isProd)
|
|
120
120
|
return this.sendDevelopmentMessage(options);
|
|
121
|
-
return new process_whatsapp_message_1.ProcessWhatsappMessage(this.propertyService).process({
|
|
121
|
+
return new process_whatsapp_message_1.ProcessWhatsappMessage(this.propertyService, this).process({
|
|
122
122
|
number: options.mobile,
|
|
123
|
-
|
|
124
|
-
|
|
123
|
+
template_identifier: options.template,
|
|
124
|
+
variables: options.data,
|
|
125
125
|
});
|
|
126
126
|
}
|
|
127
127
|
catch (error) {
|
|
@@ -133,10 +133,10 @@ let WhatsappService = class WhatsappService {
|
|
|
133
133
|
const canBeSent = await whitelisted_whatsapp_number_entity_1.WhitelistedWhatsappNumberEntity.findOne({ where: { mobile: options?.mobile, active: true } });
|
|
134
134
|
if (!canBeSent)
|
|
135
135
|
throw new nestjs_utility_services_1.AccessException('Number is not whitelisted');
|
|
136
|
-
return new process_whatsapp_message_1.ProcessWhatsappMessage(this.propertyService).process({
|
|
136
|
+
return new process_whatsapp_message_1.ProcessWhatsappMessage(this.propertyService, this).process({
|
|
137
137
|
number: options.mobile,
|
|
138
|
-
|
|
139
|
-
|
|
138
|
+
template_identifier: options.template,
|
|
139
|
+
variables: options.data,
|
|
140
140
|
});
|
|
141
141
|
}
|
|
142
142
|
catch (error) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"whatsapp.service.js","sourceRoot":"","sources":["../../../src/access/services/whatsapp.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,
|
|
1
|
+
{"version":3,"file":"whatsapp.service.js","sourceRoot":"","sources":["../../../src/access/services/whatsapp.service.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,2CAA4C;AAC5C,oFAA+I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