@sinch/fax 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +126 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -0
- package/dist/models/index.d.ts +1 -0
- package/dist/models/index.js +18 -0
- package/dist/models/index.js.map +1 -0
- package/dist/models/v3/bar-code/bar-code.d.ts +11 -0
- package/dist/models/v3/bar-code/bar-code.js +3 -0
- package/dist/models/v3/bar-code/bar-code.js.map +1 -0
- package/dist/models/v3/bar-code/index.d.ts +1 -0
- package/dist/models/v3/bar-code/index.js +3 -0
- package/dist/models/v3/bar-code/index.js.map +1 -0
- package/dist/models/v3/email/email.d.ts +12 -0
- package/dist/models/v3/email/email.js +3 -0
- package/dist/models/v3/email/email.js.map +1 -0
- package/dist/models/v3/email/index.d.ts +1 -0
- package/dist/models/v3/email/index.js +3 -0
- package/dist/models/v3/email/index.js.map +1 -0
- package/dist/models/v3/enums.d.ts +16 -0
- package/dist/models/v3/enums.js +10 -0
- package/dist/models/v3/enums.js.map +1 -0
- package/dist/models/v3/fax/fax.d.ts +62 -0
- package/dist/models/v3/fax/fax.js +3 -0
- package/dist/models/v3/fax/fax.js.map +1 -0
- package/dist/models/v3/fax/index.d.ts +1 -0
- package/dist/models/v3/fax/index.js +3 -0
- package/dist/models/v3/fax/index.js.map +1 -0
- package/dist/models/v3/fax-base64-file/fax-base64-file.d.ts +7 -0
- package/dist/models/v3/fax-base64-file/fax-base64-file.js +3 -0
- package/dist/models/v3/fax-base64-file/fax-base64-file.js.map +1 -0
- package/dist/models/v3/fax-base64-file/index.d.ts +1 -0
- package/dist/models/v3/fax-base64-file/index.js +3 -0
- package/dist/models/v3/fax-base64-file/index.js.map +1 -0
- package/dist/models/v3/fax-content-url/fax-content-url.d.ts +4 -0
- package/dist/models/v3/fax-content-url/fax-content-url.js +3 -0
- package/dist/models/v3/fax-content-url/fax-content-url.js.map +1 -0
- package/dist/models/v3/fax-content-url/index.d.ts +1 -0
- package/dist/models/v3/fax-content-url/index.js +3 -0
- package/dist/models/v3/fax-content-url/index.js.map +1 -0
- package/dist/models/v3/fax-money/fax-money.d.ts +9 -0
- package/dist/models/v3/fax-money/fax-money.js +3 -0
- package/dist/models/v3/fax-money/fax-money.js.map +1 -0
- package/dist/models/v3/fax-money/index.d.ts +1 -0
- package/dist/models/v3/fax-money/index.js +3 -0
- package/dist/models/v3/fax-money/index.js.map +1 -0
- package/dist/models/v3/fax-request/fax-request.d.ts +43 -0
- package/dist/models/v3/fax-request/fax-request.js +3 -0
- package/dist/models/v3/fax-request/fax-request.js.map +1 -0
- package/dist/models/v3/fax-request/index.d.ts +1 -0
- package/dist/models/v3/fax-request/index.js +3 -0
- package/dist/models/v3/fax-request/index.js.map +1 -0
- package/dist/models/v3/index.d.ts +13 -0
- package/dist/models/v3/index.js +47 -0
- package/dist/models/v3/index.js.map +1 -0
- package/dist/models/v3/mod-events/base-fax-event/base-fax-event.d.ts +16 -0
- package/dist/models/v3/mod-events/base-fax-event/base-fax-event.js +3 -0
- package/dist/models/v3/mod-events/base-fax-event/base-fax-event.js.map +1 -0
- package/dist/models/v3/mod-events/base-fax-event/index.d.ts +1 -0
- package/dist/models/v3/mod-events/base-fax-event/index.js +3 -0
- package/dist/models/v3/mod-events/base-fax-event/index.js.map +1 -0
- package/dist/models/v3/mod-events/fax-completed-event/fax-completed-event.d.ts +13 -0
- package/dist/models/v3/mod-events/fax-completed-event/fax-completed-event.js +3 -0
- package/dist/models/v3/mod-events/fax-completed-event/fax-completed-event.js.map +1 -0
- package/dist/models/v3/mod-events/fax-completed-event/index.d.ts +1 -0
- package/dist/models/v3/mod-events/fax-completed-event/index.js +3 -0
- package/dist/models/v3/mod-events/fax-completed-event/index.js.map +1 -0
- package/dist/models/v3/mod-events/incoming-fax-event/incoming-fax-event.d.ts +15 -0
- package/dist/models/v3/mod-events/incoming-fax-event/incoming-fax-event.js +3 -0
- package/dist/models/v3/mod-events/incoming-fax-event/incoming-fax-event.js.map +1 -0
- package/dist/models/v3/mod-events/incoming-fax-event/index.d.ts +1 -0
- package/dist/models/v3/mod-events/incoming-fax-event/index.js +3 -0
- package/dist/models/v3/mod-events/incoming-fax-event/index.js.map +1 -0
- package/dist/models/v3/mod-events/index.d.ts +2 -0
- package/dist/models/v3/mod-events/index.js +19 -0
- package/dist/models/v3/mod-events/index.js.map +1 -0
- package/dist/models/v3/service/index.d.ts +1 -0
- package/dist/models/v3/service/index.js +3 -0
- package/dist/models/v3/service/index.js.map +1 -0
- package/dist/models/v3/service/service.d.ts +35 -0
- package/dist/models/v3/service/service.js +3 -0
- package/dist/models/v3/service/service.js.map +1 -0
- package/dist/models/v3/service-email-settings/index.d.ts +1 -0
- package/dist/models/v3/service-email-settings/index.js +3 -0
- package/dist/models/v3/service-email-settings/index.js.map +1 -0
- package/dist/models/v3/service-email-settings/service-email-settings.d.ts +6 -0
- package/dist/models/v3/service-email-settings/service-email-settings.js +3 -0
- package/dist/models/v3/service-email-settings/service-email-settings.js.map +1 -0
- package/dist/models/v3/service-phone-number/index.d.ts +1 -0
- package/dist/models/v3/service-phone-number/index.js +3 -0
- package/dist/models/v3/service-phone-number/index.js.map +1 -0
- package/dist/models/v3/service-phone-number/service-phone-number.d.ts +8 -0
- package/dist/models/v3/service-phone-number/service-phone-number.js +3 -0
- package/dist/models/v3/service-phone-number/service-phone-number.js.map +1 -0
- package/dist/models/v3/update-email-request/index.d.ts +1 -0
- package/dist/models/v3/update-email-request/index.js +3 -0
- package/dist/models/v3/update-email-request/index.js.map +1 -0
- package/dist/models/v3/update-email-request/update-email-request.d.ts +4 -0
- package/dist/models/v3/update-email-request/update-email-request.js +3 -0
- package/dist/models/v3/update-email-request/update-email-request.js.map +1 -0
- package/dist/rest/index.d.ts +1 -0
- package/dist/rest/index.js +18 -0
- package/dist/rest/index.js.map +1 -0
- package/dist/rest/v3/callbacks/callbacks-webhook.d.ts +16 -0
- package/dist/rest/v3/callbacks/callbacks-webhook.js +61 -0
- package/dist/rest/v3/callbacks/callbacks-webhook.js.map +1 -0
- package/dist/rest/v3/callbacks/index.d.ts +1 -0
- package/dist/rest/v3/callbacks/index.js +18 -0
- package/dist/rest/v3/callbacks/index.js.map +1 -0
- package/dist/rest/v3/emails/emails-api.d.ts +71 -0
- package/dist/rest/v3/emails/emails-api.jest.fixture.d.ts +26 -0
- package/dist/rest/v3/emails/emails-api.jest.fixture.js +29 -0
- package/dist/rest/v3/emails/emails-api.jest.fixture.js.map +1 -0
- package/dist/rest/v3/emails/emails-api.js +148 -0
- package/dist/rest/v3/emails/emails-api.js.map +1 -0
- package/dist/rest/v3/emails/index.d.ts +2 -0
- package/dist/rest/v3/emails/index.js +19 -0
- package/dist/rest/v3/emails/index.js.map +1 -0
- package/dist/rest/v3/enums.d.ts +1 -0
- package/dist/rest/v3/enums.js +3 -0
- package/dist/rest/v3/enums.js.map +1 -0
- package/dist/rest/v3/fax-domain-api.d.ts +26 -0
- package/dist/rest/v3/fax-domain-api.js +68 -0
- package/dist/rest/v3/fax-domain-api.js.map +1 -0
- package/dist/rest/v3/fax-service.d.ts +16 -0
- package/dist/rest/v3/fax-service.js +25 -0
- package/dist/rest/v3/fax-service.js.map +1 -0
- package/dist/rest/v3/faxes/faxes-api.d.ts +85 -0
- package/dist/rest/v3/faxes/faxes-api.jest.fixture.d.ts +26 -0
- package/dist/rest/v3/faxes/faxes-api.jest.fixture.js +29 -0
- package/dist/rest/v3/faxes/faxes-api.jest.fixture.js.map +1 -0
- package/dist/rest/v3/faxes/faxes-api.js +222 -0
- package/dist/rest/v3/faxes/faxes-api.js.map +1 -0
- package/dist/rest/v3/faxes/index.d.ts +2 -0
- package/dist/rest/v3/faxes/index.js +19 -0
- package/dist/rest/v3/faxes/index.js.map +1 -0
- package/dist/rest/v3/index.d.ts +6 -0
- package/dist/rest/v3/index.js +23 -0
- package/dist/rest/v3/index.js.map +1 -0
- package/dist/rest/v3/services/index.d.ts +2 -0
- package/dist/rest/v3/services/index.js +19 -0
- package/dist/rest/v3/services/index.js.map +1 -0
- package/dist/rest/v3/services/services-api.d.ts +98 -0
- package/dist/rest/v3/services/services-api.jest.fixture.d.ts +34 -0
- package/dist/rest/v3/services/services-api.jest.fixture.js +37 -0
- package/dist/rest/v3/services/services-api.jest.fixture.js.map +1 -0
- package/dist/rest/v3/services/services-api.js +199 -0
- package/dist/rest/v3/services/services-api.js.map +1 -0
- package/package.json +37 -0
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FaxesApi = void 0;
|
|
4
|
+
const sdk_client_1 = require("@sinch/sdk-client");
|
|
5
|
+
const fax_domain_api_1 = require("../fax-domain-api");
|
|
6
|
+
class FaxesApi extends fax_domain_api_1.FaxDomainApi {
|
|
7
|
+
/**
|
|
8
|
+
* Initialize your interface
|
|
9
|
+
*
|
|
10
|
+
* @param {SinchClientParameters} sinchClientParameters - The parameters used to initialize the API Client.
|
|
11
|
+
*/
|
|
12
|
+
constructor(sinchClientParameters) {
|
|
13
|
+
super(sinchClientParameters, 'FaxesApi');
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Delete fax content
|
|
17
|
+
* Delete the fax content for a fax using the ID number of the fax. Please note that this only deletes the content of the fax from storage.
|
|
18
|
+
* @param { DeleteFaxContentRequestData } data - The data to provide to the API call.
|
|
19
|
+
*/
|
|
20
|
+
async deleteContent(data) {
|
|
21
|
+
this.client = this.getSinchClient();
|
|
22
|
+
const getParams = this.client.extractQueryParams(data, []);
|
|
23
|
+
const headers = {
|
|
24
|
+
'Content-Type': 'application/json',
|
|
25
|
+
'Accept': 'application/json',
|
|
26
|
+
};
|
|
27
|
+
const body = '';
|
|
28
|
+
const basePathUrl = `${this.client.apiClientOptions.basePath}/v3/projects/${this.client.apiClientOptions.projectId}/faxes/${data['id']}/file`;
|
|
29
|
+
const requestOptions = await this.client.prepareOptions(basePathUrl, 'DELETE', getParams, headers, body || undefined);
|
|
30
|
+
const url = this.client.prepareUrl(requestOptions.basePath, requestOptions.queryParams);
|
|
31
|
+
return this.client.processCall({
|
|
32
|
+
url,
|
|
33
|
+
requestOptions,
|
|
34
|
+
apiName: this.apiName,
|
|
35
|
+
operationId: 'DeleteFaxContentById',
|
|
36
|
+
});
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Download fax content
|
|
40
|
+
* Download the fax content.
|
|
41
|
+
* @param { DownloadFaxContentRequestData } data - The data to provide to the API call.
|
|
42
|
+
*/
|
|
43
|
+
async downloadContent(data) {
|
|
44
|
+
this.client = this.getSinchClient();
|
|
45
|
+
data['fileFormat'] = data['fileFormat'] !== undefined ? data['fileFormat'] : 'pdf';
|
|
46
|
+
const getParams = this.client.extractQueryParams(data, []);
|
|
47
|
+
const headers = {
|
|
48
|
+
'Content-Type': 'application/json',
|
|
49
|
+
'Accept': 'application/pdf',
|
|
50
|
+
};
|
|
51
|
+
const body = '';
|
|
52
|
+
const basePathUrl = `${this.client.apiClientOptions.basePath}/v3/projects/${this.client.apiClientOptions.projectId}/faxes/${data['id']}/file.${data['fileFormat']}`;
|
|
53
|
+
const requestOptions = await this.client.prepareOptions(basePathUrl, 'GET', getParams, headers, body || undefined);
|
|
54
|
+
const url = this.client.prepareUrl(requestOptions.basePath, requestOptions.queryParams);
|
|
55
|
+
return this.client.processFileCall({
|
|
56
|
+
url,
|
|
57
|
+
requestOptions,
|
|
58
|
+
apiName: this.apiName,
|
|
59
|
+
operationId: 'GetFaxFileById',
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Get fax
|
|
64
|
+
* Get fax information using the ID number of the fax.
|
|
65
|
+
* @param { GetFaxRequestData } data - The data to provide to the API call.
|
|
66
|
+
*/
|
|
67
|
+
async get(data) {
|
|
68
|
+
this.client = this.getSinchClient();
|
|
69
|
+
const getParams = this.client.extractQueryParams(data, []);
|
|
70
|
+
const headers = {
|
|
71
|
+
'Content-Type': 'application/json',
|
|
72
|
+
'Accept': 'application/json',
|
|
73
|
+
};
|
|
74
|
+
const body = '';
|
|
75
|
+
const basePathUrl = `${this.client.apiClientOptions.basePath}/v3/projects/${this.client.apiClientOptions.projectId}/faxes/${data['id']}`;
|
|
76
|
+
const requestOptions = await this.client.prepareOptions(basePathUrl, 'GET', getParams, headers, body || undefined);
|
|
77
|
+
const url = this.client.prepareUrl(requestOptions.basePath, requestOptions.queryParams);
|
|
78
|
+
return this.client.processCall({
|
|
79
|
+
url,
|
|
80
|
+
requestOptions,
|
|
81
|
+
apiName: this.apiName,
|
|
82
|
+
operationId: 'GetFaxInfoPerId',
|
|
83
|
+
});
|
|
84
|
+
}
|
|
85
|
+
/**
|
|
86
|
+
* List faxes
|
|
87
|
+
* List faxes sent (OUTBOUND) or received (INBOUND), set parameters to filter the list. Example: Return calls made between 1st of January 2021 and 10th of January 2021. ``` created>=2021-01-01&startTime<=2021-01-10 ```
|
|
88
|
+
* @param { ListFaxesRequestData } data - The data to provide to the API call.
|
|
89
|
+
* @return {ApiListPromise<Fax>}
|
|
90
|
+
*/
|
|
91
|
+
list(data) {
|
|
92
|
+
this.client = this.getSinchClient();
|
|
93
|
+
const getParams = this.client.extractQueryParams(data, [
|
|
94
|
+
'createTime',
|
|
95
|
+
'direction',
|
|
96
|
+
'status',
|
|
97
|
+
'to',
|
|
98
|
+
'from',
|
|
99
|
+
'pageSize',
|
|
100
|
+
'page'
|
|
101
|
+
]);
|
|
102
|
+
const headers = {
|
|
103
|
+
'Content-Type': 'application/json',
|
|
104
|
+
'Accept': 'application/json',
|
|
105
|
+
};
|
|
106
|
+
const body = '';
|
|
107
|
+
const basePathUrl = `${this.client.apiClientOptions.basePath}/v3/projects/${this.client.apiClientOptions.projectId}/faxes`;
|
|
108
|
+
const requestOptionsPromise = this.client.prepareOptions(basePathUrl, 'GET', getParams, headers, body || undefined);
|
|
109
|
+
const operationProperties = {
|
|
110
|
+
pagination: sdk_client_1.PaginationEnum.PAGE3,
|
|
111
|
+
apiName: this.apiName,
|
|
112
|
+
operationId: 'GetFaxes',
|
|
113
|
+
dataKey: 'faxes',
|
|
114
|
+
};
|
|
115
|
+
// Create the promise containing the response wrapped as a PageResult
|
|
116
|
+
const listPromise = (0, sdk_client_1.buildPageResultPromise)(this.client, requestOptionsPromise, operationProperties);
|
|
117
|
+
// Add properties to the Promise to offer the possibility to use it as an iterator
|
|
118
|
+
Object.assign(listPromise, (0, sdk_client_1.createIteratorMethodsForPagination)(this.client, requestOptionsPromise, listPromise, operationProperties));
|
|
119
|
+
return listPromise;
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* Send a fax
|
|
123
|
+
* Create and send a fax. Fax content may be supplied via one or more files or URLs of supported filetypes.
|
|
124
|
+
* This endpoint supports the following content types for the fax payload:
|
|
125
|
+
* - Multipart/form-data
|
|
126
|
+
* - Application/json
|
|
127
|
+
* We will however always return a fax object in the response in application json.
|
|
128
|
+
* If you supply a callbackUrl the callback will be sent as multipart/form-data with the content of the fax as an attachment to the body, *unless* you specify callbackContentType as application/json.
|
|
129
|
+
* #### file(s)
|
|
130
|
+
* Files may be included in the POST request as multipart/form-data parts.
|
|
131
|
+
* #### contentUrl
|
|
132
|
+
* Any URL on the Internet (including ones with basic authentication), and we'll pull it down and make it a fax. This might be useful to you if you're using a web framework for templates and creating fax files.
|
|
133
|
+
* Please note: If you are passing fax a secure URL (starting with 'https://'), make sure that your SSL certificate (including your intermediate cert, if you have one) is installed properly, valid, and up-to-date.
|
|
134
|
+
* @param { SendFaxRequestData } data - The data to provide to the API call.
|
|
135
|
+
*/
|
|
136
|
+
async send(data) {
|
|
137
|
+
this.client = this.getSinchClient();
|
|
138
|
+
const requestBody = data.sendFaxRequestBody;
|
|
139
|
+
requestBody['headerText'] = requestBody['headerText'] !== undefined
|
|
140
|
+
? requestBody['headerText'] : '';
|
|
141
|
+
requestBody['headerPageNumbers'] = requestBody['headerPageNumbers'] !== undefined
|
|
142
|
+
? requestBody['headerPageNumbers'] : true;
|
|
143
|
+
requestBody['headerTimeZone'] = requestBody['headerTimeZone'] !== undefined
|
|
144
|
+
? requestBody['headerTimeZone'] : 'America/New_York';
|
|
145
|
+
requestBody['retryDelaySeconds'] = requestBody['retryDelaySeconds'] !== undefined
|
|
146
|
+
? requestBody['retryDelaySeconds'] : 60;
|
|
147
|
+
requestBody['callbackContentType'] = requestBody['callbackContentType'] !== undefined
|
|
148
|
+
? requestBody['callbackContentType'] : 'multipart/form-data';
|
|
149
|
+
requestBody['imageConversionMethod'] = requestBody['imageConversionMethod'] !== undefined
|
|
150
|
+
? requestBody['imageConversionMethod'] : 'HALFTONE';
|
|
151
|
+
const getParams = this.client.extractQueryParams(data, []);
|
|
152
|
+
const headers = {
|
|
153
|
+
'Accept': 'application/json',
|
|
154
|
+
};
|
|
155
|
+
let body;
|
|
156
|
+
// Except if the request body contains a non-empty property 'files' (where the message will be sent as application/json)
|
|
157
|
+
// the request will be sent as multipart/formdata
|
|
158
|
+
const isUsingJson = data['sendFaxRequestBody'].files !== undefined;
|
|
159
|
+
if (isUsingJson) {
|
|
160
|
+
headers['Content-Type'] = 'application/json';
|
|
161
|
+
body = JSON.stringify(data['sendFaxRequestBody']);
|
|
162
|
+
}
|
|
163
|
+
else {
|
|
164
|
+
const formParams = {};
|
|
165
|
+
const requestData = data.sendFaxRequestBody;
|
|
166
|
+
if (requestData.to) {
|
|
167
|
+
formParams['to'] = requestData.to;
|
|
168
|
+
}
|
|
169
|
+
if (requestData.file) {
|
|
170
|
+
formParams['file'] = requestData.file;
|
|
171
|
+
}
|
|
172
|
+
if (requestData.from) {
|
|
173
|
+
formParams['from'] = requestData.from;
|
|
174
|
+
}
|
|
175
|
+
if (requestData.contentUrl) {
|
|
176
|
+
formParams['contentUrl'] = requestData.contentUrl;
|
|
177
|
+
}
|
|
178
|
+
if (requestData.headerText) {
|
|
179
|
+
formParams['headerText'] = requestData.headerText;
|
|
180
|
+
}
|
|
181
|
+
if (requestData.headerPageNumbers) {
|
|
182
|
+
formParams['headerPageNumbers'] = requestData.headerPageNumbers;
|
|
183
|
+
}
|
|
184
|
+
if (requestData.headerTimeZone) {
|
|
185
|
+
formParams['headerTimeZone'] = requestData.headerTimeZone;
|
|
186
|
+
}
|
|
187
|
+
if (requestData.retryDelaySeconds) {
|
|
188
|
+
formParams['retryDelaySeconds'] = requestData.retryDelaySeconds;
|
|
189
|
+
}
|
|
190
|
+
if (requestData.labels) {
|
|
191
|
+
formParams['labels'] = requestData.labels;
|
|
192
|
+
}
|
|
193
|
+
if (requestData.callbackUrl) {
|
|
194
|
+
formParams['callbackUrl'] = requestData.callbackUrl;
|
|
195
|
+
}
|
|
196
|
+
if (requestData.callbackContentType) {
|
|
197
|
+
formParams['callbackContentType'] = requestData.callbackContentType;
|
|
198
|
+
}
|
|
199
|
+
if (requestData.imageConversionMethod) {
|
|
200
|
+
formParams['imageConversionMethod'] = requestData.imageConversionMethod;
|
|
201
|
+
}
|
|
202
|
+
if (requestData.serviceId) {
|
|
203
|
+
formParams['serviceId'] = requestData.serviceId;
|
|
204
|
+
}
|
|
205
|
+
if (requestData.maxRetries) {
|
|
206
|
+
formParams['maxRetries'] = requestData.maxRetries;
|
|
207
|
+
}
|
|
208
|
+
body = this.client.processFormData(formParams, 'multipart/form-data');
|
|
209
|
+
}
|
|
210
|
+
const basePathUrl = `${this.client.apiClientOptions.basePath}/v3/projects/${this.client.apiClientOptions.projectId}/faxes`;
|
|
211
|
+
const requestOptions = await this.client.prepareOptions(basePathUrl, 'POST', getParams, headers, body || undefined);
|
|
212
|
+
const url = this.client.prepareUrl(requestOptions.basePath, requestOptions.queryParams);
|
|
213
|
+
return this.client.processCall({
|
|
214
|
+
url,
|
|
215
|
+
requestOptions,
|
|
216
|
+
apiName: this.apiName,
|
|
217
|
+
operationId: 'SendFax',
|
|
218
|
+
});
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
exports.FaxesApi = FaxesApi;
|
|
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,CAAC;YAC9G,IAAI,WAAW,CAAC,qBAAqB,EAAG,CAAC;gBAAA,UAAU,CAAC,uBAAuB,CAAC,GAAG,WAAW,CAAC,qBAAqB,CAAC;YAAA,CAAC;YAClH,IAAI,WAAW,CAAC,SAAS,EAAG,CAAC;gBAAC,UAAU,CAAC,WAAW,CAAC,GAAG,WAAW,CAAC,SAAS,CAAC;YAAC,CAAC;YAChF,IAAI,WAAW,CAAC,UAAU,EAAG,CAAC;gBAAC,UAAU,CAAC,YAAY,CAAC,GAAG,WAAW,CAAC,UAAU,CAAC;YAAC,CAAC;YACnF,IAAI,GAAG,IAAI,CAAC,MAAM,CAAC,eAAe,CAAC,UAAU,EAAE,qBAAqB,CAAC,CAAC;QACxE,CAAC;QAED,MAAM,WAAW,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,QAAQ,gBAAgB,IAAI,CAAC,MAAM,CAAC,gBAAgB,CAAC,SAAS,QAAQ,CAAC;QAE3H,MAAM,cAAc,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,cAAc,CAAC,WAAW,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,IAAI,SAAS,CAAC,CAAC;QACpH,MAAM,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,UAAU,CAAC,cAAc,CAAC,QAAQ,EAAE,cAAc,CAAC,WAAW,CAAC,CAAC;QAExF,OAAO,IAAI,CAAC,MAAM,CAAC,WAAW,CAAM;YAClC,GAAG;YACH,cAAc;YACd,OAAO,EAAE,IAAI,CAAC,OAAO;YACrB,WAAW,EAAE,SAAS;SACvB,CAAC,CAAC;IACL,CAAC;CAEF;AA1ND,4BA0NC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./faxes-api"), exports);
|
|
18
|
+
__exportStar(require("./faxes-api.jest.fixture"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/rest/v3/faxes/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,2DAAyC"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./callbacks"), exports);
|
|
18
|
+
__exportStar(require("./emails"), exports);
|
|
19
|
+
__exportStar(require("./faxes"), exports);
|
|
20
|
+
__exportStar(require("./services"), exports);
|
|
21
|
+
__exportStar(require("./enums"), exports);
|
|
22
|
+
__exportStar(require("./fax-service"), exports);
|
|
23
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/rest/v3/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,2CAAyB;AACzB,0CAAwB;AACxB,6CAA2B;AAC3B,0CAAwB;AACxB,gDAA8B"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./services-api"), exports);
|
|
18
|
+
__exportStar(require("./services-api.jest.fixture"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/rest/v3/services/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iDAA+B;AAC/B,8DAA4C"}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
import { ServicePhoneNumber, ServiceRequest, ServiceResponse } from '../../../models';
|
|
2
|
+
import { ApiListPromise, SinchClientParameters } from '@sinch/sdk-client';
|
|
3
|
+
import { FaxDomainApi } from '../fax-domain-api';
|
|
4
|
+
export interface CreateServiceRequestData {
|
|
5
|
+
/** */
|
|
6
|
+
'createServiceRequestBody'?: ServiceRequest;
|
|
7
|
+
}
|
|
8
|
+
export interface GetServiceRequestData {
|
|
9
|
+
/** The service ID you want to update. */
|
|
10
|
+
'serviceId': string;
|
|
11
|
+
}
|
|
12
|
+
export interface ListEmailsForNumberRequestData {
|
|
13
|
+
/** The phone number you want to get emails for. */
|
|
14
|
+
'phoneNumber': string;
|
|
15
|
+
/** The serviceId containing the numbers you want to list. */
|
|
16
|
+
'serviceId': string;
|
|
17
|
+
/** Number of items to return on each page. */
|
|
18
|
+
'pageSize'?: number;
|
|
19
|
+
/** Optional. The page to fetch. If not specified, the first page will be returned. */
|
|
20
|
+
'page'?: string;
|
|
21
|
+
}
|
|
22
|
+
export interface ListNumbersForServiceRequestData {
|
|
23
|
+
/** The serviceId containing the numbers you want to list. */
|
|
24
|
+
'serviceId': string;
|
|
25
|
+
/** Number of items to return on each page. */
|
|
26
|
+
'pageSize'?: number;
|
|
27
|
+
/** Optional. The page to fetch. If not specified, the first page will be returned. */
|
|
28
|
+
'page'?: string;
|
|
29
|
+
}
|
|
30
|
+
export interface ListServicesRequestData {
|
|
31
|
+
/** Number of services to return on each request. */
|
|
32
|
+
'pageSize'?: number;
|
|
33
|
+
/** Optional. The page to fetch. If not specified, the first page will be returned. */
|
|
34
|
+
'page'?: string;
|
|
35
|
+
}
|
|
36
|
+
export interface DeleteServiceRequestData {
|
|
37
|
+
/** The serviceId you want to remove from your project. */
|
|
38
|
+
'serviceId': string;
|
|
39
|
+
}
|
|
40
|
+
export interface UpdateServiceRequestData {
|
|
41
|
+
/** The service ID you want to update. */
|
|
42
|
+
'serviceId': string;
|
|
43
|
+
/** */
|
|
44
|
+
'updateServiceRequestBody'?: ServiceRequest;
|
|
45
|
+
}
|
|
46
|
+
export declare class ServicesApi extends FaxDomainApi {
|
|
47
|
+
/**
|
|
48
|
+
* Initialize your interface
|
|
49
|
+
*
|
|
50
|
+
* @param {SinchClientParameters} sinchClientParameters - The parameters used to initialize the API Client.
|
|
51
|
+
*/
|
|
52
|
+
constructor(sinchClientParameters: SinchClientParameters);
|
|
53
|
+
/**
|
|
54
|
+
* Create a service
|
|
55
|
+
* Creates a new service that you can use to set default configuration values.
|
|
56
|
+
* @param { CreateServiceRequestData } data - The data to provide to the API call.
|
|
57
|
+
*/
|
|
58
|
+
create(data: CreateServiceRequestData): Promise<ServiceResponse>;
|
|
59
|
+
/**
|
|
60
|
+
* Get a service
|
|
61
|
+
* Get a service resource.
|
|
62
|
+
* @param { GetServiceRequestData } data - The data to provide to the API call.
|
|
63
|
+
*/
|
|
64
|
+
get(data: GetServiceRequestData): Promise<ServiceResponse>;
|
|
65
|
+
/**
|
|
66
|
+
* List emails for a number
|
|
67
|
+
* List any emails for a number.
|
|
68
|
+
* @param { ListEmailsForNumberRequestData } data - The data to provide to the API call.
|
|
69
|
+
* @return {ApiListPromise<string>} - The list of emails for a given number
|
|
70
|
+
*/
|
|
71
|
+
listEmailsForNumber(data: ListEmailsForNumberRequestData): ApiListPromise<string>;
|
|
72
|
+
/**
|
|
73
|
+
* List numbers for service
|
|
74
|
+
* List numbers for a service.
|
|
75
|
+
* @param { ListNumbersForServiceRequestData } data - The data to provide to the API call.
|
|
76
|
+
* @return {ApiListPromise<ServicePhoneNumber>}
|
|
77
|
+
*/
|
|
78
|
+
listNumbers(data: ListNumbersForServiceRequestData): ApiListPromise<ServicePhoneNumber>;
|
|
79
|
+
/**
|
|
80
|
+
* List services
|
|
81
|
+
* Get a list of services for a project.
|
|
82
|
+
* @param { ListServicesRequestData } data - The data to provide to the API call.
|
|
83
|
+
* @return {ApiListPromise<ServiceResponse>}
|
|
84
|
+
*/
|
|
85
|
+
list(data: ListServicesRequestData): ApiListPromise<ServiceResponse>;
|
|
86
|
+
/**
|
|
87
|
+
* Remove a service
|
|
88
|
+
* Removes a service from your project.
|
|
89
|
+
* @param { DeleteServiceRequestData } data - The data to provide to the API call.
|
|
90
|
+
*/
|
|
91
|
+
delete(data: DeleteServiceRequestData): Promise<void>;
|
|
92
|
+
/**
|
|
93
|
+
* Update a Service
|
|
94
|
+
* Update settings on the service.
|
|
95
|
+
* @param { UpdateServiceRequestData } data - The data to provide to the API call.
|
|
96
|
+
*/
|
|
97
|
+
update(data: UpdateServiceRequestData): Promise<ServiceResponse>;
|
|
98
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/// <reference types="jest" />
|
|
2
|
+
import { ServicePhoneNumber, ServiceResponse } from '../../../models';
|
|
3
|
+
import { ServicesApi, CreateServiceRequestData, GetServiceRequestData, ListNumbersForServiceRequestData, ListServicesRequestData, DeleteServiceRequestData, UpdateServiceRequestData, ListEmailsForNumberRequestData } from './services-api';
|
|
4
|
+
import { ApiListPromise } from '@sinch/sdk-client';
|
|
5
|
+
export declare class ServicesApiFixture implements Partial<Readonly<ServicesApi>> {
|
|
6
|
+
/**
|
|
7
|
+
* Fixture associated to function create
|
|
8
|
+
*/
|
|
9
|
+
create: jest.Mock<Promise<ServiceResponse>, [CreateServiceRequestData]>;
|
|
10
|
+
/**
|
|
11
|
+
* Fixture associated to function get
|
|
12
|
+
*/
|
|
13
|
+
get: jest.Mock<Promise<ServiceResponse>, [GetServiceRequestData]>;
|
|
14
|
+
/**
|
|
15
|
+
* Fixture associated to function listEmailsForNumber
|
|
16
|
+
*/
|
|
17
|
+
listEmailsForNumber: jest.Mock<ApiListPromise<string>, [ListEmailsForNumberRequestData]>;
|
|
18
|
+
/**
|
|
19
|
+
* Fixture associated to function listNumbers
|
|
20
|
+
*/
|
|
21
|
+
listNumbers: jest.Mock<ApiListPromise<ServicePhoneNumber>, [ListNumbersForServiceRequestData]>;
|
|
22
|
+
/**
|
|
23
|
+
* Fixture associated to function list
|
|
24
|
+
*/
|
|
25
|
+
list: jest.Mock<ApiListPromise<ServiceResponse>, [ListServicesRequestData]>;
|
|
26
|
+
/**
|
|
27
|
+
* Fixture associated to function delete
|
|
28
|
+
*/
|
|
29
|
+
delete: jest.Mock<Promise<void>, [DeleteServiceRequestData]>;
|
|
30
|
+
/**
|
|
31
|
+
* Fixture associated to function update
|
|
32
|
+
*/
|
|
33
|
+
update: jest.Mock<Promise<ServiceResponse>, [UpdateServiceRequestData]>;
|
|
34
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ServicesApiFixture = void 0;
|
|
4
|
+
class ServicesApiFixture {
|
|
5
|
+
constructor() {
|
|
6
|
+
/**
|
|
7
|
+
* Fixture associated to function create
|
|
8
|
+
*/
|
|
9
|
+
this.create = jest.fn();
|
|
10
|
+
/**
|
|
11
|
+
* Fixture associated to function get
|
|
12
|
+
*/
|
|
13
|
+
this.get = jest.fn();
|
|
14
|
+
/**
|
|
15
|
+
* Fixture associated to function listEmailsForNumber
|
|
16
|
+
*/
|
|
17
|
+
this.listEmailsForNumber = jest.fn();
|
|
18
|
+
/**
|
|
19
|
+
* Fixture associated to function listNumbers
|
|
20
|
+
*/
|
|
21
|
+
this.listNumbers = jest.fn();
|
|
22
|
+
/**
|
|
23
|
+
* Fixture associated to function list
|
|
24
|
+
*/
|
|
25
|
+
this.list = jest.fn();
|
|
26
|
+
/**
|
|
27
|
+
* Fixture associated to function delete
|
|
28
|
+
*/
|
|
29
|
+
this.delete = jest.fn();
|
|
30
|
+
/**
|
|
31
|
+
* Fixture associated to function update
|
|
32
|
+
*/
|
|
33
|
+
this.update = jest.fn();
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
exports.ServicesApiFixture = ServicesApiFixture;
|
|
37
|
+
//# sourceMappingURL=services-api.jest.fixture.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"services-api.jest.fixture.js","sourceRoot":"","sources":["../../../../src/rest/v3/services/services-api.jest.fixture.ts"],"names":[],"mappings":";;;AAaA,MAAa,kBAAkB;IAA/B;QAEE;;WAEG;QACI,WAAM,GAAoE,IAAI,CAAC,EAAE,EAAE,CAAC;QAC3F;;WAEG;QACI,QAAG,GAAiE,IAAI,CAAC,EAAE,EAAE,CAAC;QACrF;;WAEG;QACI,wBAAmB,GAAwE,IAAI,CAAC,EAAE,EAAE,CAAC;QAC5G;;WAEG;QACI,gBAAW,GACoE,IAAI,CAAC,EAAE,EAAE,CAAC;QAChG;;WAEG;QACI,SAAI,GAA0E,IAAI,CAAC,EAAE,EAAE,CAAC;QAC/F;;WAEG;QACI,WAAM,GAAyD,IAAI,CAAC,EAAE,EAAE,CAAC;QAChF;;WAEG;QACI,WAAM,GAAoE,IAAI,CAAC,EAAE,EAAE,CAAC;IAC7F,CAAC;CAAA;AA/BD,gDA+BC"}
|