@sinch/sms 1.2.0 → 1.3.0
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/index.js +17 -7
- package/dist/index.js.map +1 -1
- package/dist/models/v1/add-keyword/add-keyword.d.ts +13 -0
- package/dist/models/v1/{group-object-auto-update-remove/group-object-auto-update-remove.js → add-keyword/add-keyword.js} +1 -1
- package/dist/models/v1/add-keyword/add-keyword.js.map +1 -0
- package/dist/models/v1/add-keyword/index.d.ts +1 -0
- package/dist/models/v1/add-keyword/index.js.map +1 -0
- package/dist/models/v1/api-mo-message/api-mo-message.d.ts +4 -6
- package/dist/models/v1/api-update-binary-mt-message/api-update-binary-mt-message.d.ts +12 -3
- package/dist/models/v1/api-update-mms-mt-message/api-update-mms-mt-message.d.ts +8 -3
- package/dist/models/v1/api-update-text-mt-message/api-update-text-mt-message.d.ts +17 -2
- package/dist/models/v1/binary-request/binary-request.d.ts +2 -8
- package/dist/models/v1/binary-response/binary-response.d.ts +5 -10
- package/dist/models/v1/create-group-request/create-group-request.d.ts +5 -5
- package/dist/models/v1/enums.d.ts +14 -2
- package/dist/models/v1/group/group.d.ts +2 -2
- package/dist/models/v1/group-auto-update/group-auto-update.d.ts +7 -3
- package/dist/models/v1/inbound-message-response/inbound-message-response.d.ts +2 -1
- package/dist/models/v1/index.d.ts +7 -7
- package/dist/models/v1/index.js +7 -7
- package/dist/models/v1/index.js.map +1 -1
- package/dist/models/v1/media-body/media-body.d.ts +2 -0
- package/dist/models/v1/media-request/media-request.d.ts +5 -5
- package/dist/models/v1/media-response/media-response.d.ts +5 -5
- package/dist/models/v1/message-delivery-status/message-delivery-status.d.ts +4 -4
- package/dist/models/v1/mms-media/index.d.ts +1 -0
- package/dist/models/v1/mms-media/index.js.map +1 -0
- package/dist/models/v1/mms-media/mms-media.d.ts +13 -0
- package/dist/models/v1/mms-media/mms-media.js +3 -0
- package/dist/models/v1/mms-media/mms-media.js.map +1 -0
- package/dist/models/v1/mms-mo-body/index.d.ts +1 -0
- package/dist/models/v1/mms-mo-body/index.js.map +1 -0
- package/dist/models/v1/mms-mo-body/mms-mo-body.d.ts +12 -0
- package/dist/models/v1/mms-mo-body/mms-mo-body.js +3 -0
- package/dist/models/v1/mms-mo-body/mms-mo-body.js.map +1 -0
- package/dist/models/v1/mo-binary/mo-binary.d.ts +1 -1
- package/dist/models/v1/mo-media/index.d.ts +1 -0
- package/dist/models/v1/mo-media/index.js.map +1 -0
- package/dist/models/v1/mo-media/mo-media.d.ts +8 -0
- package/dist/models/v1/mo-media/mo-media.js +3 -0
- package/dist/models/v1/mo-media/mo-media.js.map +1 -0
- package/dist/models/v1/recipient-delivery-report/recipient-delivery-report.d.ts +4 -4
- package/dist/models/v1/remove-keyword/index.d.ts +1 -0
- package/dist/models/v1/remove-keyword/index.js.map +1 -0
- package/dist/models/v1/remove-keyword/remove-keyword.d.ts +13 -0
- package/dist/models/v1/{update-group-request-auto-update-add/update-group-request-auto-update-add.js → remove-keyword/remove-keyword.js} +1 -1
- package/dist/models/v1/remove-keyword/remove-keyword.js.map +1 -0
- package/dist/models/v1/replace-group-request/replace-group-request.d.ts +6 -1
- package/dist/models/v1/requests/delivery-reports/delivery-reports-request-data.d.ts +13 -9
- package/dist/models/v1/requests/groups/groups-request-data.d.ts +3 -3
- package/dist/models/v1/text-request/text-request.d.ts +2 -2
- package/dist/models/v1/text-response/text-response.d.ts +1 -1
- package/dist/models/v1/update-group-request/update-group-request.d.ts +3 -3
- package/dist/rest/v1/batches/batches-api.jest.fixture.d.ts +0 -1
- package/dist/rest/v1/callbacks/callbacks-webhook.d.ts +5 -4
- package/dist/rest/v1/callbacks/callbacks-webhook.js +24 -6
- package/dist/rest/v1/callbacks/callbacks-webhook.js.map +1 -1
- package/dist/rest/v1/delivery-reports/delivery-reports-api.jest.fixture.d.ts +0 -1
- package/dist/rest/v1/groups/groups-api.jest.fixture.d.ts +0 -1
- package/dist/rest/v1/inbounds/inbounds-api.jest.fixture.d.ts +0 -1
- package/dist/rest/v1/sms-domain-api.d.ts +1 -0
- package/dist/rest/v1/sms-domain-api.js +10 -1
- package/dist/rest/v1/sms-domain-api.js.map +1 -1
- package/package.json +2 -2
- package/dist/models/v1/group-object-auto-update/group-object-auto-update.d.ts +0 -10
- package/dist/models/v1/group-object-auto-update/group-object-auto-update.js +0 -3
- package/dist/models/v1/group-object-auto-update/group-object-auto-update.js.map +0 -1
- package/dist/models/v1/group-object-auto-update/index.d.ts +0 -1
- package/dist/models/v1/group-object-auto-update/index.js.map +0 -1
- package/dist/models/v1/group-object-auto-update-remove/group-object-auto-update-remove.d.ts +0 -13
- package/dist/models/v1/group-object-auto-update-remove/group-object-auto-update-remove.js.map +0 -1
- package/dist/models/v1/group-object-auto-update-remove/index.d.ts +0 -1
- package/dist/models/v1/group-object-auto-update-remove/index.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update/index.d.ts +0 -1
- package/dist/models/v1/update-group-request-auto-update/index.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update/update-group-request-auto-update.d.ts +0 -10
- package/dist/models/v1/update-group-request-auto-update/update-group-request-auto-update.js +0 -3
- package/dist/models/v1/update-group-request-auto-update/update-group-request-auto-update.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update-add/index.d.ts +0 -1
- package/dist/models/v1/update-group-request-auto-update-add/index.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update-add/update-group-request-auto-update-add.d.ts +0 -10
- package/dist/models/v1/update-group-request-auto-update-add/update-group-request-auto-update-add.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update-remove/index.d.ts +0 -1
- package/dist/models/v1/update-group-request-auto-update-remove/index.js.map +0 -1
- package/dist/models/v1/update-group-request-auto-update-remove/update-group-request-auto-update-remove.d.ts +0 -13
- package/dist/models/v1/update-group-request-auto-update-remove/update-group-request-auto-update-remove.js +0 -8
- package/dist/models/v1/update-group-request-auto-update-remove/update-group-request-auto-update-remove.js.map +0 -1
- /package/dist/models/v1/{group-object-auto-update-remove → add-keyword}/index.js +0 -0
- /package/dist/models/v1/{group-object-auto-update → mms-media}/index.js +0 -0
- /package/dist/models/v1/{update-group-request-auto-update-add → mms-mo-body}/index.js +0 -0
- /package/dist/models/v1/{update-group-request-auto-update-remove → mo-media}/index.js +0 -0
- /package/dist/models/v1/{update-group-request-auto-update → remove-keyword}/index.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mo-media.js","sourceRoot":"","sources":["../../../../src/models/v1/mo-media/mo-media.ts"],"names":[],"mappings":""}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DeliveryReceiptCodeEnum, DeliveryStatusEnum } from '../enums';
|
|
2
2
|
export interface RecipientDeliveryReport {
|
|
3
3
|
/** The default originator used for the recipient this delivery report belongs to, if default originator pool configured and no originator set when submitting batch. */
|
|
4
4
|
applied_originator?: string;
|
|
@@ -8,8 +8,8 @@ export interface RecipientDeliveryReport {
|
|
|
8
8
|
batch_id: string;
|
|
9
9
|
/** The client identifier of the batch this delivery report belongs to, if set when submitting batch. */
|
|
10
10
|
client_reference?: string;
|
|
11
|
-
/** The detailed status code. */
|
|
12
|
-
code:
|
|
11
|
+
/** The detailed [status code](https://developers.sinch.com/docs/sms/api-reference/sms/tag/Delivery-reports/#tag/Delivery-reports/section/Delivery-report-error-codes). */
|
|
12
|
+
code: DeliveryReceiptCodeEnum;
|
|
13
13
|
/** Applied encoding for message. Present only if smart encoding is enabled. */
|
|
14
14
|
encoding?: 'GSM' | 'UNICODE';
|
|
15
15
|
/** The number of parts the message was split into. Present only if `max_number_of_message_parts` parameter was set. */
|
|
@@ -21,7 +21,7 @@ export interface RecipientDeliveryReport {
|
|
|
21
21
|
/** Phone number that was queried. */
|
|
22
22
|
recipient: string;
|
|
23
23
|
/** The simplified status as described in _Delivery Report Statuses_. */
|
|
24
|
-
status:
|
|
24
|
+
status: DeliveryStatusEnum;
|
|
25
25
|
/** The recipient delivery report type. */
|
|
26
26
|
type: 'recipient_delivery_report_sms' | 'recipient_delivery_report_mms';
|
|
27
27
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type { RemoveKeyword } from './remove-keyword';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/remove-keyword/index.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Keyword to be sent in MO to remove MSISDN to a group
|
|
3
|
+
*/
|
|
4
|
+
export interface RemoveKeyword {
|
|
5
|
+
/** Opt-out keyword like "LEAVE" if `auto_update.to` is dedicated long/short number or unique brand keyword like "Sinch" if it is a shared short code. */
|
|
6
|
+
first_word: string;
|
|
7
|
+
/** Opt-out keyword like "LEAVE" if `auto_update.to` is shared short code. */
|
|
8
|
+
second_word?: string;
|
|
9
|
+
}
|
|
10
|
+
/** Validation regex for first_word */
|
|
11
|
+
export declare const firstWordPattern: RegExp;
|
|
12
|
+
/** Validation regex for second_word */
|
|
13
|
+
export declare const secondWordPattern: RegExp;
|
|
@@ -5,4 +5,4 @@ exports.secondWordPattern = exports.firstWordPattern = void 0;
|
|
|
5
5
|
exports.firstWordPattern = /^\w+$/;
|
|
6
6
|
/** Validation regex for second_word */
|
|
7
7
|
exports.secondWordPattern = /^\w+$/;
|
|
8
|
-
//# sourceMappingURL=
|
|
8
|
+
//# sourceMappingURL=remove-keyword.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"remove-keyword.js","sourceRoot":"","sources":["../../../../src/models/v1/remove-keyword/remove-keyword.ts"],"names":[],"mappings":";;;AAUA,sCAAsC;AACzB,QAAA,gBAAgB,GAAG,OAAO,CAAC;AAExC,uCAAuC;AAC1B,QAAA,iBAAiB,GAAG,OAAO,CAAC"}
|
|
@@ -1,6 +1,11 @@
|
|
|
1
|
+
import { GroupAutoUpdate } from '../group-auto-update';
|
|
1
2
|
export interface ReplaceGroupRequest {
|
|
2
3
|
/** Name of group. */
|
|
3
4
|
name?: string;
|
|
4
|
-
/** The initial members of the group. Constraints: Elements must be phone numbers in
|
|
5
|
+
/** The initial members of the group. Constraints: Elements must be phone numbers in [E.164](https://community.sinch.com/t5/Glossary/E-164/ta-p/7537) format MSISDNs. */
|
|
5
6
|
members: string[];
|
|
7
|
+
/** Phone numbers ([MSISDNs](https://community.sinch.com/t5/Glossary/MSISDN/ta-p/7628)) of child group will be included in this group. If present then this group will be auto populated. Constraints: Elements must be group IDs. */
|
|
8
|
+
child_groups?: string[];
|
|
9
|
+
/** @see GroupAutoUpdate */
|
|
10
|
+
auto_update?: GroupAutoUpdate;
|
|
6
11
|
}
|
|
@@ -1,13 +1,17 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { DeliveryReceiptCodeEnum, DeliveryStatusEnum } from '../../enums';
|
|
2
2
|
export interface GetDeliveryReportByBatchIdRequestData {
|
|
3
3
|
/** The batch ID you received from sending a message. */
|
|
4
4
|
'batch_id': string;
|
|
5
|
-
/**
|
|
5
|
+
/**
|
|
6
|
+
* The type of delivery report.
|
|
7
|
+
* - A `summary` will count the number of messages sent per status.
|
|
8
|
+
* - A `full` report give that of a `summary` report but in addition, lists phone numbers.
|
|
9
|
+
*/
|
|
6
10
|
'type'?: 'summary' | 'full';
|
|
7
|
-
/** Comma separated list of
|
|
8
|
-
'status'?:
|
|
9
|
-
/** Comma separated list of
|
|
10
|
-
'code'?: string |
|
|
11
|
+
/** Comma separated list of delivery report statuses to include */
|
|
12
|
+
'status'?: DeliveryStatusEnum | DeliveryStatusEnum[];
|
|
13
|
+
/** Comma separated list of delivery receipt codes to include */
|
|
14
|
+
'code'?: string | DeliveryReceiptCodeEnum | DeliveryReceiptCodeEnum[];
|
|
11
15
|
}
|
|
12
16
|
export type GetDeliveryReportByPhoneNumberRequestData = GetDeliveryReportByPhoneNumberRequestDataBC | GetDeliveryReportByPhoneNumberRequestDataDeprecated;
|
|
13
17
|
export interface GetDeliveryReportByPhoneNumberRequestDataBC {
|
|
@@ -36,9 +40,9 @@ export interface ListDeliveryReportsRequestData {
|
|
|
36
40
|
/** Only list messages received before this date/time. */
|
|
37
41
|
'end_date'?: Date;
|
|
38
42
|
/** Comma separated list of delivery report statuses to include. */
|
|
39
|
-
'status'?:
|
|
40
|
-
/** Comma separated list of delivery receipt
|
|
41
|
-
'code'?: string;
|
|
43
|
+
'status'?: DeliveryStatusEnum | DeliveryStatusEnum[];
|
|
44
|
+
/** Comma separated list of delivery receipt codes to include. */
|
|
45
|
+
'code'?: string | DeliveryReceiptCodeEnum | DeliveryReceiptCodeEnum[];
|
|
42
46
|
/** Client reference to include */
|
|
43
47
|
'client_reference'?: string;
|
|
44
48
|
}
|
|
@@ -3,7 +3,7 @@ import { ReplaceGroupRequest } from '../../replace-group-request';
|
|
|
3
3
|
import { UpdateGroupRequest } from '../../update-group-request';
|
|
4
4
|
export interface CreateGroupRequestData {
|
|
5
5
|
/** */
|
|
6
|
-
'createGroupRequestBody'
|
|
6
|
+
'createGroupRequestBody': CreateGroupRequest;
|
|
7
7
|
}
|
|
8
8
|
export interface DeleteGroupRequestData {
|
|
9
9
|
/** ID of a group that you are interested in getting. */
|
|
@@ -23,7 +23,7 @@ export interface ReplaceGroupRequestData {
|
|
|
23
23
|
/** ID of a group that you are interested in getting. */
|
|
24
24
|
'group_id': string;
|
|
25
25
|
/** */
|
|
26
|
-
'replaceGroupRequestBody'
|
|
26
|
+
'replaceGroupRequestBody': ReplaceGroupRequest;
|
|
27
27
|
}
|
|
28
28
|
export interface GetGroupRequestData {
|
|
29
29
|
/** ID of a group that you are interested in getting. */
|
|
@@ -33,5 +33,5 @@ export interface UpdateGroupRequestData {
|
|
|
33
33
|
/** ID of a group that you are interested in getting. */
|
|
34
34
|
'group_id': string;
|
|
35
35
|
/** */
|
|
36
|
-
'updateGroupRequestBody'
|
|
36
|
+
'updateGroupRequestBody': UpdateGroupRequest;
|
|
37
37
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ParameterGroup } from '../parameter-group';
|
|
2
2
|
import { DeliveryReportEnum } from '../enums';
|
|
3
3
|
export interface TextRequest {
|
|
4
|
-
/** List of Phone numbers and group IDs that will receive the batch.
|
|
4
|
+
/** List of Phone numbers and group IDs that will receive the batch. [More info](https://community.sinch.com/t5/Glossary/MSISDN/ta-p/7628) */
|
|
5
5
|
to: string[];
|
|
6
6
|
/** Sender number. Must be valid phone number, short code or alphanumeric. Required if Automatic Default Originator not configured. */
|
|
7
7
|
from?: string;
|
|
@@ -23,7 +23,7 @@ export interface TextRequest {
|
|
|
23
23
|
callback_url?: string;
|
|
24
24
|
/** The client identifier of a batch message. If set, the identifier will be added in the delivery report/callback of this batch */
|
|
25
25
|
client_reference?: string;
|
|
26
|
-
/** If set to `true`, then [feedback](/docs/sms/api-reference/sms/tag/Batches/#tag/Batches/operation/deliveryFeedback) is expected after successful delivery. */
|
|
26
|
+
/** If set to `true`, then [feedback](https://developers.sinch.com/docs/sms/api-reference/sms/tag/Batches/#tag/Batches/operation/deliveryFeedback) is expected after successful delivery. */
|
|
27
27
|
feedback_enabled?: boolean;
|
|
28
28
|
/** Shows message on screen without user interaction while not saving the message to the inbox. */
|
|
29
29
|
flash_message?: boolean;
|
|
@@ -31,7 +31,7 @@ export interface TextResponse {
|
|
|
31
31
|
callback_url?: string;
|
|
32
32
|
/** The client identifier of a batch message. If set, the identifier will be added in the delivery report/callback of this batch */
|
|
33
33
|
client_reference?: string;
|
|
34
|
-
/** If set to `true`, then [feedback](/docs/sms/api-reference/sms/tag/Batches/#tag/Batches/operation/deliveryFeedback) is expected after successful delivery. */
|
|
34
|
+
/** If set to `true`, then [feedback](https://developers.sinch.com/docs/sms/api-reference/sms/tag/Batches/#tag/Batches/operation/deliveryFeedback) is expected after successful delivery. */
|
|
35
35
|
feedback_enabled?: boolean;
|
|
36
36
|
/** Shows message on screen without user interaction while not saving the message to the inbox. */
|
|
37
37
|
flash_message?: boolean;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { GroupAutoUpdate } from '../group-auto-update';
|
|
2
2
|
export interface UpdateGroupRequest {
|
|
3
3
|
/** The name of the group. Omitting `name` from the JSON body will leave the name unchanged. To remove an existing name set, name explicitly to the JSON value `null`. */
|
|
4
4
|
name?: string | null;
|
|
@@ -10,6 +10,6 @@ export interface UpdateGroupRequest {
|
|
|
10
10
|
add_from_group?: string;
|
|
11
11
|
/** Remove the members in a specified group from this group. Constraints: Must be valid group ID */
|
|
12
12
|
remove_from_group?: string;
|
|
13
|
-
/** @see
|
|
14
|
-
auto_update?:
|
|
13
|
+
/** @see GroupAutoUpdate */
|
|
14
|
+
auto_update?: GroupAutoUpdate;
|
|
15
15
|
}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="jest" />
|
|
2
1
|
import { BatchesApi } from './batches-api';
|
|
3
2
|
import { BinaryResponse, CancelBatchMessageRequestData, DeliveryFeedbackRequestData, DryRunRequestData, DryRunResponse, GetBatchMessageRequestData, ListBatchesRequestData, MediaResponse, ReplaceBatchMessageRequestData, SendBinarySMSRequestData, SendMediaSMSRequestData, SendSMSRequestData, SendSMSResponse, SendTextSMSRequestData, TextResponse, UpdateBatchMessageRequestData } from '../../../models';
|
|
4
3
|
import { ApiListPromise } from '@sinch/sdk-client';
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
import { DeliveryReport, MOBinary, MOText, RecipientDeliveryReport } from '../../../models';
|
|
1
|
+
import { DeliveryReport, MOBinary, MOMedia, MOText, RecipientDeliveryReport } from '../../../models';
|
|
3
2
|
import { CallbackProcessor } from '@sinch/sdk-client';
|
|
4
3
|
import { IncomingHttpHeaders } from 'http';
|
|
5
|
-
export type SmsCallback = DeliveryReport | RecipientDeliveryReport | MOText | MOBinary;
|
|
4
|
+
export type SmsCallback = DeliveryReport | RecipientDeliveryReport | MOText | MOBinary | MOMedia;
|
|
6
5
|
export declare class SmsCallbackWebhooks implements CallbackProcessor<SmsCallback> {
|
|
7
|
-
|
|
6
|
+
private readonly appSecret;
|
|
7
|
+
constructor(appSecret?: string);
|
|
8
|
+
validateAuthenticationHeader(headers: IncomingHttpHeaders, body: any, _path?: string, _method?: string): boolean;
|
|
8
9
|
/**
|
|
9
10
|
* Reviver for an SMS Event.
|
|
10
11
|
* This method ensures the object can be treated as an SMS Event and should be called before any action is taken to manipulate the object.
|
|
@@ -1,12 +1,18 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.SmsCallbackWebhooks = void 0;
|
|
4
|
+
const sdk_client_1 = require("@sinch/sdk-client");
|
|
4
5
|
class SmsCallbackWebhooks {
|
|
5
|
-
|
|
6
|
+
constructor(appSecret) {
|
|
7
|
+
this.appSecret = appSecret;
|
|
8
|
+
}
|
|
9
|
+
validateAuthenticationHeader(headers, body,
|
|
6
10
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
11
|
+
_path, _method) {
|
|
12
|
+
if (!this.appSecret) {
|
|
13
|
+
return false;
|
|
14
|
+
}
|
|
15
|
+
return (0, sdk_client_1.validateWebhookSignature)(this.appSecret, headers, body);
|
|
10
16
|
}
|
|
11
17
|
/**
|
|
12
18
|
* Reviver for an SMS Event.
|
|
@@ -15,10 +21,14 @@ class SmsCallbackWebhooks {
|
|
|
15
21
|
* @return {SmsCallback} - The parsed SMS event object
|
|
16
22
|
*/
|
|
17
23
|
parseEvent(eventBody) {
|
|
24
|
+
if (typeof eventBody === 'string') {
|
|
25
|
+
eventBody = JSON.parse(eventBody);
|
|
26
|
+
}
|
|
18
27
|
if (eventBody.type) {
|
|
19
28
|
let recipientDeliveryReport = null;
|
|
20
29
|
let moText = null;
|
|
21
30
|
let moBinary = null;
|
|
31
|
+
let moMedia = null;
|
|
22
32
|
switch (eventBody.type) {
|
|
23
33
|
case 'delivery_report_sms':
|
|
24
34
|
case 'delivery_report_mms':
|
|
@@ -51,12 +61,20 @@ class SmsCallbackWebhooks {
|
|
|
51
61
|
moBinary.sent_at = new Date(moBinary.sent_at);
|
|
52
62
|
}
|
|
53
63
|
return moBinary;
|
|
64
|
+
case 'mo_media':
|
|
65
|
+
moMedia = eventBody;
|
|
66
|
+
if (moMedia.received_at) {
|
|
67
|
+
moMedia.received_at = new Date(moMedia.received_at);
|
|
68
|
+
}
|
|
69
|
+
if (moMedia.sent_at) {
|
|
70
|
+
moMedia.sent_at = new Date(moMedia.sent_at);
|
|
71
|
+
}
|
|
72
|
+
return moMedia;
|
|
54
73
|
default:
|
|
55
74
|
throw new Error(`Unknown SMS event type: ${eventBody.type}`);
|
|
56
75
|
}
|
|
57
76
|
}
|
|
58
|
-
|
|
59
|
-
throw new Error('Unknown SMS event');
|
|
77
|
+
throw new Error(`Unknown SMS event: ${JSON.stringify(eventBody)}`);
|
|
60
78
|
}
|
|
61
79
|
;
|
|
62
80
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callbacks-webhook.js","sourceRoot":"","sources":["../../../../src/rest/v1/callbacks/callbacks-webhook.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"callbacks-webhook.js","sourceRoot":"","sources":["../../../../src/rest/v1/callbacks/callbacks-webhook.ts"],"names":[],"mappings":";;;AACA,kDAAgF;AAKhF,MAAa,mBAAmB;IAI9B,YAAY,SAAkB;QAC5B,IAAI,CAAC,SAAS,GAAG,SAAS,CAAC;IAC7B,CAAC;IAEM,4BAA4B,CACjC,OAA4B,EAC5B,IAAS;IACT,6DAA6D;IAC7D,KAAc,EAAE,OAAgB;QAEhC,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,CAAC;YACpB,OAAO,KAAK,CAAC;QACf,CAAC;QACD,OAAO,IAAA,qCAAwB,EAC7B,IAAI,CAAC,SAAS,EACd,OAAO,EACP,IAAI,CACL,CAAC;IACJ,CAAC;I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AChB,KAAK,WAAW;oBACd,QAAQ,GAAG,SAAqB,CAAC;oBACjC,IAAI,QAAQ,CAAC,WAAW,EAAE,CAAC;wBACzB,QAAQ,CAAC,WAAW,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC;oBACxD,CAAC;oBACD,IAAI,QAAQ,CAAC,OAAO,EAAE,CAAC;wBACrB,QAAQ,CAAC,OAAO,GAAG,IAAI,IAAI,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;oBAChD,CAAC;oBACD,OAAO,QAAQ,CAAC;gBAClB,KAAK,UAAU;oBACb,OAAO,GAAG,SAAoB,CAAC;oBAC/B,IAAI,OAAO,CAAC,WAAW,EAAE,CAAC;wBACxB,OAAO,CAAC,WAAW,GAAG,IAAI,IAAI,CAAC,OAAO,CAAC,WAAW,CAAC,CAAC;oBACtD,CAAC;oBACD,IAAI,OAAO,CAAC,OAAO,EAAE,CAAC;wBACpB,OAAO,CAAC,OAAO,GAAG,IAAI,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;oBAC9C,CAAC;oBACD,OAAO,OAAO,CAAC;gBACjB;oBACE,MAAM,IAAI,KAAK,CAAC,2BAA2B,SAAS,CAAC,IAAI,EAAE,CAAC,CAAC;YAC/D,CAAC;QACH,CAAC;QACD,MAAM,IAAI,KAAK,CAAC,sBAAsB,IAAI,CAAC,SAAS,CAAC,SAAS,CAAC,EAAE,CAAC,CAAC;IACrE,CAAC;IAAA,CAAC;CAEH;AAvFD,kDAuFC"}
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="jest" />
|
|
2
1
|
import { DeliveryReportsApi } from './delivery-reports-api';
|
|
3
2
|
import { DeliveryReport, GetDeliveryReportByBatchIdRequestData, GetDeliveryReportByPhoneNumberRequestData, ListDeliveryReportsRequestData, RecipientDeliveryReport } from '../../../models';
|
|
4
3
|
import { ApiListPromise } from '@sinch/sdk-client';
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="jest" />
|
|
2
1
|
import { GroupsApi } from './groups-api';
|
|
3
2
|
import { Group, CreateGroupRequestData, DeleteGroupRequestData, ListMembersRequestData, ListGroupsRequestData, ReplaceGroupRequestData, GetGroupRequestData, UpdateGroupRequestData } from '../../../models';
|
|
4
3
|
import { ApiListPromise } from '@sinch/sdk-client';
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Api, ApiClient, SinchClientParameters, SmsRegion, UnifiedCredentials, ServicePlanIdCredentials } from '@sinch/sdk-client';
|
|
2
|
+
export declare const DEFAULT_SMS_REGION_DEPRECATION_WARNING: string;
|
|
2
3
|
export declare class SmsDomainApi implements Api {
|
|
3
4
|
readonly apiName: string;
|
|
4
5
|
client?: ApiClient;
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.SmsDomainApi = void 0;
|
|
3
|
+
exports.SmsDomainApi = exports.DEFAULT_SMS_REGION_DEPRECATION_WARNING = void 0;
|
|
4
4
|
const sdk_client_1 = require("@sinch/sdk-client");
|
|
5
|
+
exports.DEFAULT_SMS_REGION_DEPRECATION_WARNING = '** DEPRECATION NOTICE ** '
|
|
6
|
+
+ 'The "smsRegion" property will become mandatory in the next major version of the SDK and not default '
|
|
7
|
+
+ 'to "us" anymore. Please set it to a valid region.';
|
|
5
8
|
class SmsDomainApi {
|
|
6
9
|
constructor(sinchClientParameters, apiName) {
|
|
7
10
|
this.sinchClientParameters = sinchClientParameters;
|
|
@@ -13,6 +16,8 @@ class SmsDomainApi {
|
|
|
13
16
|
*/
|
|
14
17
|
setHostname(hostname) {
|
|
15
18
|
try {
|
|
19
|
+
// The following line is a workaround to detect if the hostname is set for the Conversation or Templates API - To be deleted in 2.0
|
|
20
|
+
this.sinchClientParameters.smsHostname = hostname;
|
|
16
21
|
this.client = this.getSinchClient();
|
|
17
22
|
this.client.apiClientOptions.hostname = hostname;
|
|
18
23
|
}
|
|
@@ -64,6 +69,10 @@ class SmsDomainApi {
|
|
|
64
69
|
getSinchClient() {
|
|
65
70
|
if (!this.client) {
|
|
66
71
|
const region = this.sinchClientParameters.smsRegion ?? sdk_client_1.SmsRegion.UNITED_STATES;
|
|
72
|
+
// Deprecation Notice - to remove in 2.0
|
|
73
|
+
if (!this.sinchClientParameters.smsRegion && !this.sinchClientParameters.smsHostname) {
|
|
74
|
+
console.warn(exports.DEFAULT_SMS_REGION_DEPRECATION_WARNING);
|
|
75
|
+
}
|
|
67
76
|
if (!Object.values(sdk_client_1.SupportedSmsRegion).includes(region)) {
|
|
68
77
|
console.warn(`The region "${region}" is not known as a supported region for the SMS API`);
|
|
69
78
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sms-domain-api.js","sourceRoot":"","sources":["../../../src/rest/v1/sms-domain-api.ts"],"names":[],"mappings":";;;AAAA,kDAY2B;
|
|
1
|
+
{"version":3,"file":"sms-domain-api.js","sourceRoot":"","sources":["../../../src/rest/v1/sms-domain-api.ts"],"names":[],"mappings":";;;AAAA,kDAY2B;AAEd,QAAA,sCAAsC,GAAG,2BAA2B;MAC7E,sGAAsG;MACtG,mDAAmD,CAAC;AAExD,MAAa,YAAY;IAKvB,YAAY,qBAA4C,EAAE,OAAe;QACvE,IAAI,CAAC,qBAAqB,GAAG,qBAAqB,CAAC;QACnD,IAAI,CAAC,OAAO,GAAG,OAAO,CAAC;IACzB,CAAC;IAED;;;OAGG;IACI,WAAW,CAAC,QAAgB;QACjC,IAAI,CAAC;YACH,mIAAmI;YACnI,IAAI,CAAC,qBAAqB,CAAC,WAAW,GAAG,QAAQ,CAAC;YAClD,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC,cAAc,EAAE,CAAC;YACpC,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,QAAQ,GAAG,QAAQ,CAAC;QACnD,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,OAAO,CAAC,KAAK,CA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 +29,7 @@
|
|
|
29
29
|
"test:e2e": "cucumber-js"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@sinch/sdk-client": "^1.
|
|
32
|
+
"@sinch/sdk-client": "^1.3.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {},
|
|
35
35
|
"publishConfig": {
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { GroupObjectAutoUpdateRemove } from '../group-object-auto-update-remove';
|
|
2
|
-
import { UpdateGroupRequestAutoUpdateAdd } from '../update-group-request-auto-update-add';
|
|
3
|
-
export interface GroupObjectAutoUpdate {
|
|
4
|
-
/** Short code or long number addressed in <a href=\"https://community.sinch.com/t5/Glossary/MO-Mobile-Originated/ta-p/7618\" target=\"_blank\">MO</a>. Constraints: Must be valid phone number or short code. */
|
|
5
|
-
to?: string;
|
|
6
|
-
/** @see UpdateGroupRequestAutoUpdateAdd */
|
|
7
|
-
add?: UpdateGroupRequestAutoUpdateAdd;
|
|
8
|
-
/** @see GroupObjectAutoUpdateRemove */
|
|
9
|
-
remove?: GroupObjectAutoUpdateRemove;
|
|
10
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"group-object-auto-update.js","sourceRoot":"","sources":["../../../../src/models/v1/group-object-auto-update/group-object-auto-update.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { GroupObjectAutoUpdate } from './group-object-auto-update';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/group-object-auto-update/index.ts"],"names":[],"mappings":""}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Keyword to be sent in MO to remove from a group.
|
|
3
|
-
*/
|
|
4
|
-
export interface GroupObjectAutoUpdateRemove {
|
|
5
|
-
/** Opt-out keyword like \"LEAVE\" If auto_update.to is dedicated long/short number or unique brand keyword like \"Sinch\" if it is a shared short code. Constraints: Must be one word. */
|
|
6
|
-
first_word?: string;
|
|
7
|
-
/** Opt-out keyword like \"LEAVE\" if auto_update.to is shared short code. Constraints: Must be one word. */
|
|
8
|
-
second_word?: string;
|
|
9
|
-
}
|
|
10
|
-
/** Validation regex for first_word */
|
|
11
|
-
export declare const firstWordPattern: RegExp;
|
|
12
|
-
/** Validation regex for second_word */
|
|
13
|
-
export declare const secondWordPattern: RegExp;
|
package/dist/models/v1/group-object-auto-update-remove/group-object-auto-update-remove.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"group-object-auto-update-remove.js","sourceRoot":"","sources":["../../../../src/models/v1/group-object-auto-update-remove/group-object-auto-update-remove.ts"],"names":[],"mappings":";;;AAYA,sCAAsC;AACzB,QAAA,gBAAgB,GAAG,OAAO,CAAC;AACxC,uCAAuC;AAC1B,QAAA,iBAAiB,GAAG,OAAO,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { GroupObjectAutoUpdateRemove } from './group-object-auto-update-remove';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/group-object-auto-update-remove/index.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { UpdateGroupRequestAutoUpdate } from './update-group-request-auto-update';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update/index.ts"],"names":[],"mappings":""}
|
package/dist/models/v1/update-group-request-auto-update/update-group-request-auto-update.d.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { UpdateGroupRequestAutoUpdateAdd } from '../update-group-request-auto-update-add';
|
|
2
|
-
import { UpdateGroupRequestAutoUpdateRemove } from '../update-group-request-auto-update-remove';
|
|
3
|
-
export interface UpdateGroupRequestAutoUpdate {
|
|
4
|
-
/** Short code or long number addressed in <a href=\"https://community.sinch.com/t5/Glossary/MO-Mobile-Originated/ta-p/7618\" target=\"_blank\">MO</a>. Constraints: Must be a valid phone number or short code. */
|
|
5
|
-
to?: string;
|
|
6
|
-
/** @see UpdateGroupRequestAutoUpdateAdd */
|
|
7
|
-
add?: UpdateGroupRequestAutoUpdateAdd;
|
|
8
|
-
/** @see UpdateGroupRequestAutoUpdateRemove */
|
|
9
|
-
remove?: UpdateGroupRequestAutoUpdateRemove;
|
|
10
|
-
}
|
package/dist/models/v1/update-group-request-auto-update/update-group-request-auto-update.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-group-request-auto-update.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update/update-group-request-auto-update.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { UpdateGroupRequestAutoUpdateAdd } from './update-group-request-auto-update-add';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update-add/index.ts"],"names":[],"mappings":""}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
export interface UpdateGroupRequestAutoUpdateAdd {
|
|
2
|
-
/** Keyword to be sent in <a href=\"https://community.sinch.com/t5/Glossary/MO-Mobile-Originated/ta-p/7618\" target=\"_blank\">MO</a> to add phone number to a group opt-in keyword like \"JOIN\". If `auto_update.to` is dedicated long/short number or unique brand keyword like \"Sinch\" if it is a shared short code. Constraints: Must be one word. */
|
|
3
|
-
first_word?: string;
|
|
4
|
-
/** Opt-in keyword like \"JOIN\" if auto_update.to is shared short code. Constraints: Must be one word. */
|
|
5
|
-
second_word?: string;
|
|
6
|
-
}
|
|
7
|
-
/** Validation regex for first_word */
|
|
8
|
-
export declare const firstWordPattern: RegExp;
|
|
9
|
-
/** Validation regex for second_word */
|
|
10
|
-
export declare const secondWordPattern: RegExp;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-group-request-auto-update-add.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update-add/update-group-request-auto-update-add.ts"],"names":[],"mappings":";;;AASA,sCAAsC;AACzB,QAAA,gBAAgB,GAAG,OAAO,CAAC;AACxC,uCAAuC;AAC1B,QAAA,iBAAiB,GAAG,OAAO,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { UpdateGroupRequestAutoUpdateRemove } from './update-group-request-auto-update-remove';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update-remove/index.ts"],"names":[],"mappings":""}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Keyword to be sent in MO to remove from a group.
|
|
3
|
-
*/
|
|
4
|
-
export interface UpdateGroupRequestAutoUpdateRemove {
|
|
5
|
-
/** Opt-out keyword. For example, \"LEAVE\" if `auto_update.to` is a dedicated long/short number or a unique brand keyword like \"Sinch\" (if it is a shared short code). Constraints: Must be one word. */
|
|
6
|
-
first_word?: string;
|
|
7
|
-
/** Opt-out keyword. For example, \"LEAVE\" if `auto_update.to` is a shared short code. Constraints: Must be one word. */
|
|
8
|
-
second_word?: string;
|
|
9
|
-
}
|
|
10
|
-
/** Validation regex for first_word */
|
|
11
|
-
export declare const firstWordPattern: RegExp;
|
|
12
|
-
/** Validation regex for second_word */
|
|
13
|
-
export declare const secondWordPattern: RegExp;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.secondWordPattern = exports.firstWordPattern = void 0;
|
|
4
|
-
/** Validation regex for first_word */
|
|
5
|
-
exports.firstWordPattern = /^\w+$/;
|
|
6
|
-
/** Validation regex for second_word */
|
|
7
|
-
exports.secondWordPattern = /^\w+$/;
|
|
8
|
-
//# sourceMappingURL=update-group-request-auto-update-remove.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"update-group-request-auto-update-remove.js","sourceRoot":"","sources":["../../../../src/models/v1/update-group-request-auto-update-remove/update-group-request-auto-update-remove.ts"],"names":[],"mappings":";;;AAYA,sCAAsC;AACzB,QAAA,gBAAgB,GAAG,OAAO,CAAC;AACxC,uCAAuC;AAC1B,QAAA,iBAAiB,GAAG,OAAO,CAAC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|