@libgot/whatsapp-bridge-sdk 1.0.40-rc.2 → 1.0.40-rc.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 +2 -2
- package/apis/chats-api.ts +19 -7
- package/dist/apis/chats-api.d.ts +8 -4
- package/dist/apis/chats-api.js +18 -7
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
## @1.0.40-rc.
|
|
1
|
+
## @1.0.40-rc.3
|
|
2
2
|
|
|
3
3
|
This generator creates TypeScript/JavaScript client that utilizes [axios](https://github.com/axios/axios). The generated Node module can be used in the following environments:
|
|
4
4
|
|
|
@@ -36,7 +36,7 @@ navigate to the folder of your consuming project and run one of the following co
|
|
|
36
36
|
_published:_
|
|
37
37
|
|
|
38
38
|
```
|
|
39
|
-
npm install @libgot/whatsapp-bridge-sdk@1.0.40-rc.
|
|
39
|
+
npm install @libgot/whatsapp-bridge-sdk@1.0.40-rc.3 --save
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
_unPublished (not recommended):_
|
package/apis/chats-api.ts
CHANGED
|
@@ -289,15 +289,20 @@ export const ChatsApiAxiosParamCreator = function (configuration?: Configuration
|
|
|
289
289
|
/**
|
|
290
290
|
*
|
|
291
291
|
* @param {MarkChatUnreadDto} body
|
|
292
|
+
* @param {string} apikey
|
|
292
293
|
* @param {number} id
|
|
293
294
|
* @param {*} [options] Override http request option.
|
|
294
295
|
* @throws {RequiredError}
|
|
295
296
|
*/
|
|
296
|
-
markChatUnread: async (body: MarkChatUnreadDto, id: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
297
|
+
markChatUnread: async (body: MarkChatUnreadDto, apikey: string, id: number, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
297
298
|
// verify required parameter 'body' is not null or undefined
|
|
298
299
|
if (body === null || body === undefined) {
|
|
299
300
|
throw new RequiredError('body','Required parameter body was null or undefined when calling markChatUnread.');
|
|
300
301
|
}
|
|
302
|
+
// verify required parameter 'apikey' is not null or undefined
|
|
303
|
+
if (apikey === null || apikey === undefined) {
|
|
304
|
+
throw new RequiredError('apikey','Required parameter apikey was null or undefined when calling markChatUnread.');
|
|
305
|
+
}
|
|
301
306
|
// verify required parameter 'id' is not null or undefined
|
|
302
307
|
if (id === null || id === undefined) {
|
|
303
308
|
throw new RequiredError('id','Required parameter id was null or undefined when calling markChatUnread.');
|
|
@@ -314,6 +319,10 @@ export const ChatsApiAxiosParamCreator = function (configuration?: Configuration
|
|
|
314
319
|
const localVarHeaderParameter = {} as any;
|
|
315
320
|
const localVarQueryParameter = {} as any;
|
|
316
321
|
|
|
322
|
+
if (apikey !== undefined && apikey !== null) {
|
|
323
|
+
localVarHeaderParameter['apikey'] = String(apikey);
|
|
324
|
+
}
|
|
325
|
+
|
|
317
326
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
318
327
|
|
|
319
328
|
const query = new URLSearchParams(localVarUrlObj.search);
|
|
@@ -413,12 +422,13 @@ export const ChatsApiFp = function(configuration?: Configuration) {
|
|
|
413
422
|
/**
|
|
414
423
|
*
|
|
415
424
|
* @param {MarkChatUnreadDto} body
|
|
425
|
+
* @param {string} apikey
|
|
416
426
|
* @param {number} id
|
|
417
427
|
* @param {*} [options] Override http request option.
|
|
418
428
|
* @throws {RequiredError}
|
|
419
429
|
*/
|
|
420
|
-
async markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
|
421
|
-
const localVarAxiosArgs = await ChatsApiAxiosParamCreator(configuration).markChatUnread(body, id, options);
|
|
430
|
+
async markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>> {
|
|
431
|
+
const localVarAxiosArgs = await ChatsApiAxiosParamCreator(configuration).markChatUnread(body, apikey, id, options);
|
|
422
432
|
return (axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH) => {
|
|
423
433
|
const axiosRequestArgs :AxiosRequestConfig = {...localVarAxiosArgs.options, url: basePath + localVarAxiosArgs.url};
|
|
424
434
|
return axios.request(axiosRequestArgs);
|
|
@@ -487,12 +497,13 @@ export const ChatsApiFactory = function (configuration?: Configuration, basePath
|
|
|
487
497
|
/**
|
|
488
498
|
*
|
|
489
499
|
* @param {MarkChatUnreadDto} body
|
|
500
|
+
* @param {string} apikey
|
|
490
501
|
* @param {number} id
|
|
491
502
|
* @param {*} [options] Override http request option.
|
|
492
503
|
* @throws {RequiredError}
|
|
493
504
|
*/
|
|
494
|
-
async markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
|
495
|
-
return ChatsApiFp(configuration).markChatUnread(body, id, options).then((request) => request(axios, basePath));
|
|
505
|
+
async markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>> {
|
|
506
|
+
return ChatsApiFp(configuration).markChatUnread(body, apikey, id, options).then((request) => request(axios, basePath));
|
|
496
507
|
},
|
|
497
508
|
};
|
|
498
509
|
};
|
|
@@ -562,12 +573,13 @@ export class ChatsApi extends BaseAPI {
|
|
|
562
573
|
/**
|
|
563
574
|
*
|
|
564
575
|
* @param {MarkChatUnreadDto} body
|
|
576
|
+
* @param {string} apikey
|
|
565
577
|
* @param {number} id
|
|
566
578
|
* @param {*} [options] Override http request option.
|
|
567
579
|
* @throws {RequiredError}
|
|
568
580
|
* @memberof ChatsApi
|
|
569
581
|
*/
|
|
570
|
-
public async markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
|
571
|
-
return ChatsApiFp(this.configuration).markChatUnread(body, id, options).then((request) => request(this.axios, this.basePath));
|
|
582
|
+
public async markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig) : Promise<AxiosResponse<void>> {
|
|
583
|
+
return ChatsApiFp(this.configuration).markChatUnread(body, apikey, id, options).then((request) => request(this.axios, this.basePath));
|
|
572
584
|
}
|
|
573
585
|
}
|
package/dist/apis/chats-api.d.ts
CHANGED
|
@@ -68,11 +68,12 @@ export declare const ChatsApiAxiosParamCreator: (configuration?: Configuration)
|
|
|
68
68
|
/**
|
|
69
69
|
*
|
|
70
70
|
* @param {MarkChatUnreadDto} body
|
|
71
|
+
* @param {string} apikey
|
|
71
72
|
* @param {number} id
|
|
72
73
|
* @param {*} [options] Override http request option.
|
|
73
74
|
* @throws {RequiredError}
|
|
74
75
|
*/
|
|
75
|
-
markChatUnread: (body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
76
|
+
markChatUnread: (body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
76
77
|
};
|
|
77
78
|
/**
|
|
78
79
|
* ChatsApi - functional programming interface
|
|
@@ -125,11 +126,12 @@ export declare const ChatsApiFp: (configuration?: Configuration) => {
|
|
|
125
126
|
/**
|
|
126
127
|
*
|
|
127
128
|
* @param {MarkChatUnreadDto} body
|
|
129
|
+
* @param {string} apikey
|
|
128
130
|
* @param {number} id
|
|
129
131
|
* @param {*} [options] Override http request option.
|
|
130
132
|
* @throws {RequiredError}
|
|
131
133
|
*/
|
|
132
|
-
markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>>;
|
|
134
|
+
markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => Promise<AxiosResponse<void>>>;
|
|
133
135
|
};
|
|
134
136
|
/**
|
|
135
137
|
* ChatsApi - factory interface
|
|
@@ -182,11 +184,12 @@ export declare const ChatsApiFactory: (configuration?: Configuration, basePath?:
|
|
|
182
184
|
/**
|
|
183
185
|
*
|
|
184
186
|
* @param {MarkChatUnreadDto} body
|
|
187
|
+
* @param {string} apikey
|
|
185
188
|
* @param {number} id
|
|
186
189
|
* @param {*} [options] Override http request option.
|
|
187
190
|
* @throws {RequiredError}
|
|
188
191
|
*/
|
|
189
|
-
markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>>;
|
|
192
|
+
markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>>;
|
|
190
193
|
};
|
|
191
194
|
/**
|
|
192
195
|
* ChatsApi - object-oriented interface
|
|
@@ -245,10 +248,11 @@ export declare class ChatsApi extends BaseAPI {
|
|
|
245
248
|
/**
|
|
246
249
|
*
|
|
247
250
|
* @param {MarkChatUnreadDto} body
|
|
251
|
+
* @param {string} apikey
|
|
248
252
|
* @param {number} id
|
|
249
253
|
* @param {*} [options] Override http request option.
|
|
250
254
|
* @throws {RequiredError}
|
|
251
255
|
* @memberof ChatsApi
|
|
252
256
|
*/
|
|
253
|
-
markChatUnread(body: MarkChatUnreadDto, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>>;
|
|
257
|
+
markChatUnread(body: MarkChatUnreadDto, apikey: string, id: number, options?: AxiosRequestConfig): Promise<AxiosResponse<void>>;
|
|
254
258
|
}
|
package/dist/apis/chats-api.js
CHANGED
|
@@ -270,15 +270,20 @@ const ChatsApiAxiosParamCreator = function (configuration) {
|
|
|
270
270
|
/**
|
|
271
271
|
*
|
|
272
272
|
* @param {MarkChatUnreadDto} body
|
|
273
|
+
* @param {string} apikey
|
|
273
274
|
* @param {number} id
|
|
274
275
|
* @param {*} [options] Override http request option.
|
|
275
276
|
* @throws {RequiredError}
|
|
276
277
|
*/
|
|
277
|
-
markChatUnread: (body_1, id_1, ...args_1) => __awaiter(this, [body_1, id_1, ...args_1], void 0, function* (body, id, options = {}) {
|
|
278
|
+
markChatUnread: (body_1, apikey_1, id_1, ...args_1) => __awaiter(this, [body_1, apikey_1, id_1, ...args_1], void 0, function* (body, apikey, id, options = {}) {
|
|
278
279
|
// verify required parameter 'body' is not null or undefined
|
|
279
280
|
if (body === null || body === undefined) {
|
|
280
281
|
throw new base_1.RequiredError('body', 'Required parameter body was null or undefined when calling markChatUnread.');
|
|
281
282
|
}
|
|
283
|
+
// verify required parameter 'apikey' is not null or undefined
|
|
284
|
+
if (apikey === null || apikey === undefined) {
|
|
285
|
+
throw new base_1.RequiredError('apikey', 'Required parameter apikey was null or undefined when calling markChatUnread.');
|
|
286
|
+
}
|
|
282
287
|
// verify required parameter 'id' is not null or undefined
|
|
283
288
|
if (id === null || id === undefined) {
|
|
284
289
|
throw new base_1.RequiredError('id', 'Required parameter id was null or undefined when calling markChatUnread.');
|
|
@@ -294,6 +299,9 @@ const ChatsApiAxiosParamCreator = function (configuration) {
|
|
|
294
299
|
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
295
300
|
const localVarHeaderParameter = {};
|
|
296
301
|
const localVarQueryParameter = {};
|
|
302
|
+
if (apikey !== undefined && apikey !== null) {
|
|
303
|
+
localVarHeaderParameter['apikey'] = String(apikey);
|
|
304
|
+
}
|
|
297
305
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
298
306
|
const query = new URLSearchParams(localVarUrlObj.search);
|
|
299
307
|
for (const key in localVarQueryParameter) {
|
|
@@ -399,13 +407,14 @@ const ChatsApiFp = function (configuration) {
|
|
|
399
407
|
/**
|
|
400
408
|
*
|
|
401
409
|
* @param {MarkChatUnreadDto} body
|
|
410
|
+
* @param {string} apikey
|
|
402
411
|
* @param {number} id
|
|
403
412
|
* @param {*} [options] Override http request option.
|
|
404
413
|
* @throws {RequiredError}
|
|
405
414
|
*/
|
|
406
|
-
markChatUnread(body, id, options) {
|
|
415
|
+
markChatUnread(body, apikey, id, options) {
|
|
407
416
|
return __awaiter(this, void 0, void 0, function* () {
|
|
408
|
-
const localVarAxiosArgs = yield (0, exports.ChatsApiAxiosParamCreator)(configuration).markChatUnread(body, id, options);
|
|
417
|
+
const localVarAxiosArgs = yield (0, exports.ChatsApiAxiosParamCreator)(configuration).markChatUnread(body, apikey, id, options);
|
|
409
418
|
return (axios = axios_1.default, basePath = base_1.BASE_PATH) => {
|
|
410
419
|
const axiosRequestArgs = Object.assign(Object.assign({}, localVarAxiosArgs.options), { url: basePath + localVarAxiosArgs.url });
|
|
411
420
|
return axios.request(axiosRequestArgs);
|
|
@@ -483,13 +492,14 @@ const ChatsApiFactory = function (configuration, basePath, axios) {
|
|
|
483
492
|
/**
|
|
484
493
|
*
|
|
485
494
|
* @param {MarkChatUnreadDto} body
|
|
495
|
+
* @param {string} apikey
|
|
486
496
|
* @param {number} id
|
|
487
497
|
* @param {*} [options] Override http request option.
|
|
488
498
|
* @throws {RequiredError}
|
|
489
499
|
*/
|
|
490
|
-
markChatUnread(body, id, options) {
|
|
500
|
+
markChatUnread(body, apikey, id, options) {
|
|
491
501
|
return __awaiter(this, void 0, void 0, function* () {
|
|
492
|
-
return (0, exports.ChatsApiFp)(configuration).markChatUnread(body, id, options).then((request) => request(axios, basePath));
|
|
502
|
+
return (0, exports.ChatsApiFp)(configuration).markChatUnread(body, apikey, id, options).then((request) => request(axios, basePath));
|
|
493
503
|
});
|
|
494
504
|
},
|
|
495
505
|
};
|
|
@@ -568,14 +578,15 @@ class ChatsApi extends base_1.BaseAPI {
|
|
|
568
578
|
/**
|
|
569
579
|
*
|
|
570
580
|
* @param {MarkChatUnreadDto} body
|
|
581
|
+
* @param {string} apikey
|
|
571
582
|
* @param {number} id
|
|
572
583
|
* @param {*} [options] Override http request option.
|
|
573
584
|
* @throws {RequiredError}
|
|
574
585
|
* @memberof ChatsApi
|
|
575
586
|
*/
|
|
576
|
-
markChatUnread(body, id, options) {
|
|
587
|
+
markChatUnread(body, apikey, id, options) {
|
|
577
588
|
return __awaiter(this, void 0, void 0, function* () {
|
|
578
|
-
return (0, exports.ChatsApiFp)(this.configuration).markChatUnread(body, id, options).then((request) => request(this.axios, this.basePath));
|
|
589
|
+
return (0, exports.ChatsApiFp)(this.configuration).markChatUnread(body, apikey, id, options).then((request) => request(this.axios, this.basePath));
|
|
579
590
|
});
|
|
580
591
|
}
|
|
581
592
|
}
|