@emilgroup/webhook-sdk-node 1.1.1-beta.3 → 1.6.1-beta.12
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/api/health-checks-api.ts +4 -2
- package/api/inbound-webhooks-api.ts +20 -10
- package/api/trigger-inbound-webhooks-api.ts +4 -2
- package/api/webhook-requests-api.ts +4 -2
- package/base.ts +1 -0
- package/common.ts +3 -2
- package/dist/api/health-checks-api.d.ts +1 -1
- package/dist/api/health-checks-api.js +7 -4
- package/dist/api/inbound-webhooks-api.d.ts +5 -5
- package/dist/api/inbound-webhooks-api.js +32 -19
- package/dist/api/trigger-inbound-webhooks-api.d.ts +1 -1
- package/dist/api/trigger-inbound-webhooks-api.js +7 -4
- package/dist/api/webhook-requests-api.d.ts +1 -1
- package/dist/api/webhook-requests-api.js +4 -3
- package/dist/base.d.ts +2 -1
- package/dist/base.js +1 -0
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -0
- package/dist/models/inbound-webhook-class.d.ts +1 -1
- package/dist/models/list-inbound-webhook-response-class.d.ts +3 -3
- package/dist/models/list-webhook-requests-response-class.d.ts +3 -3
- package/models/inbound-webhook-class.ts +1 -1
- package/models/list-inbound-webhook-response-class.ts +3 -3
- package/models/list-webhook-requests-response-class.ts +3 -3
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
|
|
|
17
17
|
Navigate to the folder of your consuming project and run one of the following commands:
|
|
18
18
|
|
|
19
19
|
```
|
|
20
|
-
npm install @emilgroup/webhook-sdk-node@1.
|
|
20
|
+
npm install @emilgroup/webhook-sdk-node@1.6.1-beta.12 --save
|
|
21
21
|
```
|
|
22
22
|
or
|
|
23
23
|
```
|
|
24
|
-
yarn add @emilgroup/webhook-sdk-node@1.
|
|
24
|
+
yarn add @emilgroup/webhook-sdk-node@1.6.1-beta.12
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
And then you can import ``.
|
package/api/health-checks-api.ts
CHANGED
|
@@ -60,8 +60,10 @@ export const HealthChecksApiAxiosParamCreator = function (configuration?: Config
|
|
|
60
60
|
// http bearer authentication required
|
|
61
61
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
62
62
|
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
64
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
65
|
+
if (authorizationValue) {
|
|
66
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
65
67
|
}
|
|
66
68
|
|
|
67
69
|
|
|
@@ -71,8 +71,10 @@ export const InboundWebhooksApiAxiosParamCreator = function (configuration?: Con
|
|
|
71
71
|
// http bearer authentication required
|
|
72
72
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
73
73
|
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
75
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
76
|
+
if (authorizationValue) {
|
|
77
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
76
78
|
}
|
|
77
79
|
|
|
78
80
|
|
|
@@ -119,8 +121,10 @@ export const InboundWebhooksApiAxiosParamCreator = function (configuration?: Con
|
|
|
119
121
|
// http bearer authentication required
|
|
120
122
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
121
123
|
|
|
122
|
-
|
|
123
|
-
|
|
124
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
125
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
126
|
+
if (authorizationValue) {
|
|
127
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
124
128
|
}
|
|
125
129
|
|
|
126
130
|
|
|
@@ -164,8 +168,10 @@ export const InboundWebhooksApiAxiosParamCreator = function (configuration?: Con
|
|
|
164
168
|
// http bearer authentication required
|
|
165
169
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
166
170
|
|
|
167
|
-
|
|
168
|
-
|
|
171
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
172
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
173
|
+
if (authorizationValue) {
|
|
174
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
169
175
|
}
|
|
170
176
|
|
|
171
177
|
|
|
@@ -240,8 +246,10 @@ export const InboundWebhooksApiAxiosParamCreator = function (configuration?: Con
|
|
|
240
246
|
localVarQueryParameter['filters'] = filters;
|
|
241
247
|
}
|
|
242
248
|
|
|
243
|
-
|
|
244
|
-
|
|
249
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
250
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
251
|
+
if (authorizationValue) {
|
|
252
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
245
253
|
}
|
|
246
254
|
|
|
247
255
|
|
|
@@ -288,8 +296,10 @@ export const InboundWebhooksApiAxiosParamCreator = function (configuration?: Con
|
|
|
288
296
|
// http bearer authentication required
|
|
289
297
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
290
298
|
|
|
291
|
-
|
|
292
|
-
|
|
299
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
300
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
301
|
+
if (authorizationValue) {
|
|
302
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
293
303
|
}
|
|
294
304
|
|
|
295
305
|
|
|
@@ -64,8 +64,10 @@ export const TriggerInboundWebhooksApiAxiosParamCreator = function (configuratio
|
|
|
64
64
|
// http bearer authentication required
|
|
65
65
|
await setBearerAuthToObject(localVarHeaderParameter, configuration)
|
|
66
66
|
|
|
67
|
-
|
|
68
|
-
|
|
67
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
68
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
69
|
+
if (authorizationValue) {
|
|
70
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
69
71
|
}
|
|
70
72
|
|
|
71
73
|
|
|
@@ -93,8 +93,10 @@ export const WebhookRequestsApiAxiosParamCreator = function (configuration?: Con
|
|
|
93
93
|
localVarQueryParameter['filters'] = filters;
|
|
94
94
|
}
|
|
95
95
|
|
|
96
|
-
|
|
97
|
-
|
|
96
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
97
|
+
const authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
98
|
+
if (authorizationValue) {
|
|
99
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
98
100
|
}
|
|
99
101
|
|
|
100
102
|
|
package/base.ts
CHANGED
|
@@ -60,6 +60,7 @@ export enum Environment {
|
|
|
60
60
|
Staging = 'https://apiv2-staging.emil.de',
|
|
61
61
|
Development = 'https://apiv2-dev.emil.de',
|
|
62
62
|
ProductionZurich = 'https://eu-central-2.apiv2.emil.de',
|
|
63
|
+
StagingZurich = 'https://eu-central-2.apiv2-staging.emil.de',
|
|
63
64
|
}
|
|
64
65
|
|
|
65
66
|
let _retry_count = 0
|
package/common.ts
CHANGED
|
@@ -131,9 +131,10 @@ export const toPathString = function (url: URL) {
|
|
|
131
131
|
* @export
|
|
132
132
|
*/
|
|
133
133
|
export const createRequestFunction = function (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) {
|
|
134
|
-
|
|
134
|
+
// Typed by hand: since axios 1.20, request() returns an internal axios type that SDK declarations cannot name.
|
|
135
|
+
return <T = unknown, R = AxiosResponse<T>>(axios: AxiosInstance = globalAxios, basePath: string = BASE_PATH): Promise<R> => {
|
|
135
136
|
const axiosRequestArgs = {...axiosArgs.options, url: (configuration?.basePath || basePath) + axiosArgs.url};
|
|
136
|
-
return axios.request<T, R>(axiosRequestArgs)
|
|
137
|
+
return axios.request<T, R>(axiosRequestArgs) as Promise<R>;
|
|
137
138
|
};
|
|
138
139
|
}
|
|
139
140
|
|
|
@@ -83,5 +83,5 @@ export declare class HealthChecksApi extends BaseAPI {
|
|
|
83
83
|
* @throws {RequiredError}
|
|
84
84
|
* @memberof HealthChecksApi
|
|
85
85
|
*/
|
|
86
|
-
check(requestParameters?: HealthChecksApiCheckRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<InlineResponse200, any, {}>>;
|
|
86
|
+
check(requestParameters?: HealthChecksApiCheckRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<InlineResponse200, any, {}, any>>;
|
|
87
87
|
}
|
|
@@ -106,7 +106,7 @@ var HealthChecksApiAxiosParamCreator = function (configuration) {
|
|
|
106
106
|
check: function (authorization, options) {
|
|
107
107
|
if (options === void 0) { options = {}; }
|
|
108
108
|
return __awaiter(_this, void 0, void 0, function () {
|
|
109
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
109
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
110
110
|
return __generator(this, function (_a) {
|
|
111
111
|
switch (_a.label) {
|
|
112
112
|
case 0:
|
|
@@ -121,13 +121,16 @@ var HealthChecksApiAxiosParamCreator = function (configuration) {
|
|
|
121
121
|
localVarQueryParameter = {};
|
|
122
122
|
// authentication bearer required
|
|
123
123
|
// http bearer authentication required
|
|
124
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
124
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
125
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
126
|
+
];
|
|
125
127
|
case 1:
|
|
126
128
|
// authentication bearer required
|
|
127
129
|
// http bearer authentication required
|
|
128
130
|
_a.sent();
|
|
129
|
-
|
|
130
|
-
|
|
131
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
132
|
+
if (authorizationValue) {
|
|
133
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
131
134
|
}
|
|
132
135
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
133
136
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -344,7 +344,7 @@ export declare class InboundWebhooksApi extends BaseAPI {
|
|
|
344
344
|
* @throws {RequiredError}
|
|
345
345
|
* @memberof InboundWebhooksApi
|
|
346
346
|
*/
|
|
347
|
-
createInboundWebhook(requestParameters: InboundWebhooksApiCreateInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateInboundWebhookResponseClass, any, {}>>;
|
|
347
|
+
createInboundWebhook(requestParameters: InboundWebhooksApiCreateInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<CreateInboundWebhookResponseClass, any, {}, any>>;
|
|
348
348
|
/**
|
|
349
349
|
* Deletes an inbound webhook by its code **Required Permissions** \"webhook-management.webhooks.delete\"
|
|
350
350
|
* @summary Delete the inbound webhook
|
|
@@ -353,7 +353,7 @@ export declare class InboundWebhooksApi extends BaseAPI {
|
|
|
353
353
|
* @throws {RequiredError}
|
|
354
354
|
* @memberof InboundWebhooksApi
|
|
355
355
|
*/
|
|
356
|
-
deleteInboundWebhook(requestParameters: InboundWebhooksApiDeleteInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}>>;
|
|
356
|
+
deleteInboundWebhook(requestParameters: InboundWebhooksApiDeleteInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any, {}, any>>;
|
|
357
357
|
/**
|
|
358
358
|
* Retrieves an inbound webhook by its code **Required Permissions** \"webhook-management.webhooks.view\"
|
|
359
359
|
* @summary Retrieve the inbound webhook
|
|
@@ -362,7 +362,7 @@ export declare class InboundWebhooksApi extends BaseAPI {
|
|
|
362
362
|
* @throws {RequiredError}
|
|
363
363
|
* @memberof InboundWebhooksApi
|
|
364
364
|
*/
|
|
365
|
-
getInboundWebhook(requestParameters: InboundWebhooksApiGetInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetInboundWebhookResponseClass, any, {}>>;
|
|
365
|
+
getInboundWebhook(requestParameters: InboundWebhooksApiGetInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<GetInboundWebhookResponseClass, any, {}, any>>;
|
|
366
366
|
/**
|
|
367
367
|
* Lists all inbound webhooks with optional filters **Required Permissions** \"webhook-management.webhooks.view\"
|
|
368
368
|
* @summary List inbound webhooks
|
|
@@ -371,7 +371,7 @@ export declare class InboundWebhooksApi extends BaseAPI {
|
|
|
371
371
|
* @throws {RequiredError}
|
|
372
372
|
* @memberof InboundWebhooksApi
|
|
373
373
|
*/
|
|
374
|
-
listInboundWebhooks(requestParameters?: InboundWebhooksApiListInboundWebhooksRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListInboundWebhookResponseClass, any, {}>>;
|
|
374
|
+
listInboundWebhooks(requestParameters?: InboundWebhooksApiListInboundWebhooksRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListInboundWebhookResponseClass, any, {}, any>>;
|
|
375
375
|
/**
|
|
376
376
|
* Updates an existing inbound webhook configuration **Required Permissions** \"webhook-management.webhooks.update\"
|
|
377
377
|
* @summary Update the inbound webhook
|
|
@@ -380,5 +380,5 @@ export declare class InboundWebhooksApi extends BaseAPI {
|
|
|
380
380
|
* @throws {RequiredError}
|
|
381
381
|
* @memberof InboundWebhooksApi
|
|
382
382
|
*/
|
|
383
|
-
updateInboundWebhook(requestParameters: InboundWebhooksApiUpdateInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateInboundWebhookResponseClass, any, {}>>;
|
|
383
|
+
updateInboundWebhook(requestParameters: InboundWebhooksApiUpdateInboundWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<UpdateInboundWebhookResponseClass, any, {}, any>>;
|
|
384
384
|
}
|
|
@@ -107,7 +107,7 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
107
107
|
createInboundWebhook: function (createInboundWebhookRequestDto, authorization, options) {
|
|
108
108
|
if (options === void 0) { options = {}; }
|
|
109
109
|
return __awaiter(_this, void 0, void 0, function () {
|
|
110
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
110
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
111
111
|
return __generator(this, function (_a) {
|
|
112
112
|
switch (_a.label) {
|
|
113
113
|
case 0:
|
|
@@ -124,13 +124,16 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
124
124
|
localVarQueryParameter = {};
|
|
125
125
|
// authentication bearer required
|
|
126
126
|
// http bearer authentication required
|
|
127
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
127
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
128
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
129
|
+
];
|
|
128
130
|
case 1:
|
|
129
131
|
// authentication bearer required
|
|
130
132
|
// http bearer authentication required
|
|
131
133
|
_a.sent();
|
|
132
|
-
|
|
133
|
-
|
|
134
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
135
|
+
if (authorizationValue) {
|
|
136
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
134
137
|
}
|
|
135
138
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
136
139
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
@@ -156,7 +159,7 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
156
159
|
deleteInboundWebhook: function (code, authorization, options) {
|
|
157
160
|
if (options === void 0) { options = {}; }
|
|
158
161
|
return __awaiter(_this, void 0, void 0, function () {
|
|
159
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
162
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
160
163
|
return __generator(this, function (_a) {
|
|
161
164
|
switch (_a.label) {
|
|
162
165
|
case 0:
|
|
@@ -174,13 +177,16 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
174
177
|
localVarQueryParameter = {};
|
|
175
178
|
// authentication bearer required
|
|
176
179
|
// http bearer authentication required
|
|
177
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
180
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
181
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
182
|
+
];
|
|
178
183
|
case 1:
|
|
179
184
|
// authentication bearer required
|
|
180
185
|
// http bearer authentication required
|
|
181
186
|
_a.sent();
|
|
182
|
-
|
|
183
|
-
|
|
187
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
188
|
+
if (authorizationValue) {
|
|
189
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
184
190
|
}
|
|
185
191
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
186
192
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -204,7 +210,7 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
204
210
|
getInboundWebhook: function (code, authorization, options) {
|
|
205
211
|
if (options === void 0) { options = {}; }
|
|
206
212
|
return __awaiter(_this, void 0, void 0, function () {
|
|
207
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
213
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
208
214
|
return __generator(this, function (_a) {
|
|
209
215
|
switch (_a.label) {
|
|
210
216
|
case 0:
|
|
@@ -222,13 +228,16 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
222
228
|
localVarQueryParameter = {};
|
|
223
229
|
// authentication bearer required
|
|
224
230
|
// http bearer authentication required
|
|
225
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
231
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
232
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
233
|
+
];
|
|
226
234
|
case 1:
|
|
227
235
|
// authentication bearer required
|
|
228
236
|
// http bearer authentication required
|
|
229
237
|
_a.sent();
|
|
230
|
-
|
|
231
|
-
|
|
238
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
239
|
+
if (authorizationValue) {
|
|
240
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
232
241
|
}
|
|
233
242
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
234
243
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -258,7 +267,7 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
258
267
|
listInboundWebhooks: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
259
268
|
if (options === void 0) { options = {}; }
|
|
260
269
|
return __awaiter(_this, void 0, void 0, function () {
|
|
261
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
270
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
262
271
|
return __generator(this, function (_a) {
|
|
263
272
|
switch (_a.label) {
|
|
264
273
|
case 0:
|
|
@@ -299,8 +308,9 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
299
308
|
if (filters !== undefined) {
|
|
300
309
|
localVarQueryParameter['filters'] = filters;
|
|
301
310
|
}
|
|
302
|
-
|
|
303
|
-
|
|
311
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
312
|
+
if (authorizationValue) {
|
|
313
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
304
314
|
}
|
|
305
315
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
306
316
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -325,7 +335,7 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
325
335
|
updateInboundWebhook: function (code, updateInboundWebhookRequestDto, authorization, options) {
|
|
326
336
|
if (options === void 0) { options = {}; }
|
|
327
337
|
return __awaiter(_this, void 0, void 0, function () {
|
|
328
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
338
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
329
339
|
return __generator(this, function (_a) {
|
|
330
340
|
switch (_a.label) {
|
|
331
341
|
case 0:
|
|
@@ -345,13 +355,16 @@ var InboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
345
355
|
localVarQueryParameter = {};
|
|
346
356
|
// authentication bearer required
|
|
347
357
|
// http bearer authentication required
|
|
348
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
358
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
359
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
360
|
+
];
|
|
349
361
|
case 1:
|
|
350
362
|
// authentication bearer required
|
|
351
363
|
// http bearer authentication required
|
|
352
364
|
_a.sent();
|
|
353
|
-
|
|
354
|
-
|
|
365
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
366
|
+
if (authorizationValue) {
|
|
367
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
355
368
|
}
|
|
356
369
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
357
370
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
@@ -92,5 +92,5 @@ export declare class TriggerInboundWebhooksApi extends BaseAPI {
|
|
|
92
92
|
* @throws {RequiredError}
|
|
93
93
|
* @memberof TriggerInboundWebhooksApi
|
|
94
94
|
*/
|
|
95
|
-
triggerIncomingWebhook(requestParameters: TriggerInboundWebhooksApiTriggerIncomingWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<TriggerInboundWebhookAcceptedResponseClass, any, {}>>;
|
|
95
|
+
triggerIncomingWebhook(requestParameters: TriggerInboundWebhooksApiTriggerIncomingWebhookRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<TriggerInboundWebhookAcceptedResponseClass, any, {}, any>>;
|
|
96
96
|
}
|
|
@@ -107,7 +107,7 @@ var TriggerInboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
107
107
|
triggerIncomingWebhook: function (code, authorization, options) {
|
|
108
108
|
if (options === void 0) { options = {}; }
|
|
109
109
|
return __awaiter(_this, void 0, void 0, function () {
|
|
110
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
110
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
111
111
|
return __generator(this, function (_a) {
|
|
112
112
|
switch (_a.label) {
|
|
113
113
|
case 0:
|
|
@@ -125,13 +125,16 @@ var TriggerInboundWebhooksApiAxiosParamCreator = function (configuration) {
|
|
|
125
125
|
localVarQueryParameter = {};
|
|
126
126
|
// authentication bearer required
|
|
127
127
|
// http bearer authentication required
|
|
128
|
-
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
128
|
+
return [4 /*yield*/, (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration)
|
|
129
|
+
// Only Authorization falls back to the configured token; an empty value is never sent.
|
|
130
|
+
];
|
|
129
131
|
case 1:
|
|
130
132
|
// authentication bearer required
|
|
131
133
|
// http bearer authentication required
|
|
132
134
|
_a.sent();
|
|
133
|
-
|
|
134
|
-
|
|
135
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
136
|
+
if (authorizationValue) {
|
|
137
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
135
138
|
}
|
|
136
139
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
137
140
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
@@ -146,5 +146,5 @@ export declare class WebhookRequestsApi extends BaseAPI {
|
|
|
146
146
|
* @throws {RequiredError}
|
|
147
147
|
* @memberof WebhookRequestsApi
|
|
148
148
|
*/
|
|
149
|
-
listWebhookRequests(requestParameters?: WebhookRequestsApiListWebhookRequestsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListWebhookRequestsResponseClass, any, {}>>;
|
|
149
|
+
listWebhookRequests(requestParameters?: WebhookRequestsApiListWebhookRequestsRequest, options?: AxiosRequestConfig): Promise<import("axios").AxiosResponse<ListWebhookRequestsResponseClass, any, {}, any>>;
|
|
150
150
|
}
|
|
@@ -113,7 +113,7 @@ var WebhookRequestsApiAxiosParamCreator = function (configuration) {
|
|
|
113
113
|
listWebhookRequests: function (authorization, pageSize, pageToken, filter, search, order, expand, filters, options) {
|
|
114
114
|
if (options === void 0) { options = {}; }
|
|
115
115
|
return __awaiter(_this, void 0, void 0, function () {
|
|
116
|
-
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
116
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, authorizationValue, headersFromBaseOptions;
|
|
117
117
|
return __generator(this, function (_a) {
|
|
118
118
|
switch (_a.label) {
|
|
119
119
|
case 0:
|
|
@@ -154,8 +154,9 @@ var WebhookRequestsApiAxiosParamCreator = function (configuration) {
|
|
|
154
154
|
if (filters !== undefined) {
|
|
155
155
|
localVarQueryParameter['filters'] = filters;
|
|
156
156
|
}
|
|
157
|
-
|
|
158
|
-
|
|
157
|
+
authorizationValue = 'Authorization'.toLowerCase() === 'authorization' ? (authorization || baseAccessToken) : authorization;
|
|
158
|
+
if (authorizationValue) {
|
|
159
|
+
localVarHeaderParameter['Authorization'] = String(authorizationValue);
|
|
159
160
|
}
|
|
160
161
|
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
161
162
|
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
package/dist/base.d.ts
CHANGED
|
@@ -39,7 +39,8 @@ export declare enum Environment {
|
|
|
39
39
|
Test = "https://apiv2-test.emil.de",
|
|
40
40
|
Staging = "https://apiv2-staging.emil.de",
|
|
41
41
|
Development = "https://apiv2-dev.emil.de",
|
|
42
|
-
ProductionZurich = "https://eu-central-2.apiv2.emil.de"
|
|
42
|
+
ProductionZurich = "https://eu-central-2.apiv2.emil.de",
|
|
43
|
+
StagingZurich = "https://eu-central-2.apiv2-staging.emil.de"
|
|
43
44
|
}
|
|
44
45
|
export declare function resetRetry(): void;
|
|
45
46
|
/**
|
package/dist/base.js
CHANGED
|
@@ -132,6 +132,7 @@ var Environment;
|
|
|
132
132
|
Environment["Staging"] = "https://apiv2-staging.emil.de";
|
|
133
133
|
Environment["Development"] = "https://apiv2-dev.emil.de";
|
|
134
134
|
Environment["ProductionZurich"] = "https://eu-central-2.apiv2.emil.de";
|
|
135
|
+
Environment["StagingZurich"] = "https://eu-central-2.apiv2-staging.emil.de";
|
|
135
136
|
})(Environment = exports.Environment || (exports.Environment = {}));
|
|
136
137
|
var _retry_count = 0;
|
|
137
138
|
var _retry = null;
|
package/dist/common.d.ts
CHANGED
|
@@ -63,7 +63,7 @@ export declare const toPathString: (url: URL) => string;
|
|
|
63
63
|
*
|
|
64
64
|
* @export
|
|
65
65
|
*/
|
|
66
|
-
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) => <T = unknown, R = AxiosResponse<T, any, {}>>(axios?: AxiosInstance, basePath?: string) => Promise<R>;
|
|
66
|
+
export declare const createRequestFunction: (axiosArgs: RequestArgs, globalAxios: AxiosInstance, BASE_PATH: string, configuration?: Configuration) => <T = unknown, R = AxiosResponse<T, any, {}, any>>(axios?: AxiosInstance, basePath?: string) => Promise<R>;
|
|
67
67
|
/**
|
|
68
68
|
* EMIL Webhookservice
|
|
69
69
|
* The EMIL Webhookservice API description
|
package/dist/common.js
CHANGED
|
@@ -234,6 +234,7 @@ exports.toPathString = toPathString;
|
|
|
234
234
|
* @export
|
|
235
235
|
*/
|
|
236
236
|
var createRequestFunction = function (axiosArgs, globalAxios, BASE_PATH, configuration) {
|
|
237
|
+
// Typed by hand: since axios 1.20, request() returns an internal axios type that SDK declarations cannot name.
|
|
237
238
|
return function (axios, basePath) {
|
|
238
239
|
if (axios === void 0) { axios = globalAxios; }
|
|
239
240
|
if (basePath === void 0) { basePath = BASE_PATH; }
|
|
@@ -27,17 +27,17 @@ export interface ListInboundWebhookResponseClass {
|
|
|
27
27
|
* @type {string}
|
|
28
28
|
* @memberof ListInboundWebhookResponseClass
|
|
29
29
|
*/
|
|
30
|
-
'nextPageToken'
|
|
30
|
+
'nextPageToken'?: string;
|
|
31
31
|
/**
|
|
32
32
|
* Number of items per page
|
|
33
33
|
* @type {number}
|
|
34
34
|
* @memberof ListInboundWebhookResponseClass
|
|
35
35
|
*/
|
|
36
|
-
'itemsPerPage'
|
|
36
|
+
'itemsPerPage'?: number;
|
|
37
37
|
/**
|
|
38
38
|
* Total number of items
|
|
39
39
|
* @type {number}
|
|
40
40
|
* @memberof ListInboundWebhookResponseClass
|
|
41
41
|
*/
|
|
42
|
-
'totalItems'
|
|
42
|
+
'totalItems'?: number;
|
|
43
43
|
}
|
|
@@ -27,17 +27,17 @@ export interface ListWebhookRequestsResponseClass {
|
|
|
27
27
|
* @type {string}
|
|
28
28
|
* @memberof ListWebhookRequestsResponseClass
|
|
29
29
|
*/
|
|
30
|
-
'nextPageToken'
|
|
30
|
+
'nextPageToken'?: string;
|
|
31
31
|
/**
|
|
32
32
|
* Number of items per page
|
|
33
33
|
* @type {number}
|
|
34
34
|
* @memberof ListWebhookRequestsResponseClass
|
|
35
35
|
*/
|
|
36
|
-
'itemsPerPage'
|
|
36
|
+
'itemsPerPage'?: number;
|
|
37
37
|
/**
|
|
38
38
|
* Total number of items
|
|
39
39
|
* @type {number}
|
|
40
40
|
* @memberof ListWebhookRequestsResponseClass
|
|
41
41
|
*/
|
|
42
|
-
'totalItems'
|
|
42
|
+
'totalItems'?: number;
|
|
43
43
|
}
|
|
@@ -32,18 +32,18 @@ export interface ListInboundWebhookResponseClass {
|
|
|
32
32
|
* @type {string}
|
|
33
33
|
* @memberof ListInboundWebhookResponseClass
|
|
34
34
|
*/
|
|
35
|
-
'nextPageToken'
|
|
35
|
+
'nextPageToken'?: string;
|
|
36
36
|
/**
|
|
37
37
|
* Number of items per page
|
|
38
38
|
* @type {number}
|
|
39
39
|
* @memberof ListInboundWebhookResponseClass
|
|
40
40
|
*/
|
|
41
|
-
'itemsPerPage'
|
|
41
|
+
'itemsPerPage'?: number;
|
|
42
42
|
/**
|
|
43
43
|
* Total number of items
|
|
44
44
|
* @type {number}
|
|
45
45
|
* @memberof ListInboundWebhookResponseClass
|
|
46
46
|
*/
|
|
47
|
-
'totalItems'
|
|
47
|
+
'totalItems'?: number;
|
|
48
48
|
}
|
|
49
49
|
|
|
@@ -32,18 +32,18 @@ export interface ListWebhookRequestsResponseClass {
|
|
|
32
32
|
* @type {string}
|
|
33
33
|
* @memberof ListWebhookRequestsResponseClass
|
|
34
34
|
*/
|
|
35
|
-
'nextPageToken'
|
|
35
|
+
'nextPageToken'?: string;
|
|
36
36
|
/**
|
|
37
37
|
* Number of items per page
|
|
38
38
|
* @type {number}
|
|
39
39
|
* @memberof ListWebhookRequestsResponseClass
|
|
40
40
|
*/
|
|
41
|
-
'itemsPerPage'
|
|
41
|
+
'itemsPerPage'?: number;
|
|
42
42
|
/**
|
|
43
43
|
* Total number of items
|
|
44
44
|
* @type {number}
|
|
45
45
|
* @memberof ListWebhookRequestsResponseClass
|
|
46
46
|
*/
|
|
47
|
-
'totalItems'
|
|
47
|
+
'totalItems'?: number;
|
|
48
48
|
}
|
|
49
49
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@emilgroup/webhook-sdk-node",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.1-beta.12",
|
|
4
4
|
"description": "OpenAPI client for @emilgroup/webhook-sdk-node",
|
|
5
5
|
"author": "OpenAPI-Generator Contributors",
|
|
6
6
|
"keywords": [
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
"prepare": "npm run build"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"axios": "1.
|
|
21
|
+
"axios": "1.20.0",
|
|
22
22
|
"form-data": "^4.0.0",
|
|
23
23
|
"url": "^0.11.0"
|
|
24
24
|
},
|