@zyphr-dev/node-sdk 0.1.56 → 0.1.58

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.
Files changed (45) hide show
  1. package/dist/index.cjs +1879 -317
  2. package/dist/index.cjs.map +1 -1
  3. package/dist/index.d.cts +8 -10
  4. package/dist/index.d.ts +8 -10
  5. package/dist/index.js +1879 -317
  6. package/dist/index.js.map +1 -1
  7. package/package.json +1 -1
  8. package/src/clientAuth.ts +15 -4
  9. package/src/src/apis/AuthApplicationApi.ts +32 -4
  10. package/src/src/apis/AuthEmailOTPApi.ts +72 -9
  11. package/src/src/apis/AuthEmailTemplatesApi.ts +160 -20
  12. package/src/src/apis/AuthEmailVerificationApi.ts +52 -10
  13. package/src/src/apis/AuthLoginApi.ts +16 -2
  14. package/src/src/apis/AuthMFAApi.ts +112 -14
  15. package/src/src/apis/AuthMagicLinksApi.ts +32 -4
  16. package/src/src/apis/AuthOAuthApi.ts +88 -11
  17. package/src/src/apis/AuthOrganizationsApi.ts +176 -22
  18. package/src/src/apis/AuthPasswordResetApi.ts +48 -6
  19. package/src/src/apis/AuthPhoneApi.ts +72 -9
  20. package/src/src/apis/AuthRegistrationApi.ts +40 -5
  21. package/src/src/apis/AuthSessionsApi.ts +56 -7
  22. package/src/src/apis/AuthUserDirectoryApi.ts +144 -18
  23. package/src/src/apis/AuthUserProfileApi.ts +32 -4
  24. package/src/src/apis/AuthWebAuthnApi.ts +96 -12
  25. package/src/src/apis/DevicesApi.ts +52 -10
  26. package/src/src/apis/DomainsApi.ts +56 -7
  27. package/src/src/apis/EmailsApi.ts +48 -6
  28. package/src/src/apis/ExecutionsApi.ts +24 -3
  29. package/src/src/apis/InboundEmailApi.ts +24 -3
  30. package/src/src/apis/InboxApi.ts +88 -11
  31. package/src/src/apis/PushApi.ts +72 -9
  32. package/src/src/apis/SMSApi.ts +80 -10
  33. package/src/src/apis/SlackApi.ts +24 -3
  34. package/src/src/apis/SubscribersApi.ts +160 -20
  35. package/src/src/apis/TemplatesApi.ts +48 -6
  36. package/src/src/apis/TopicsApi.ts +72 -9
  37. package/src/src/apis/UtilityApi.ts +16 -2
  38. package/src/src/apis/WaaSApplicationsApi.ts +48 -6
  39. package/src/src/apis/WaaSDeliveriesApi.ts +32 -4
  40. package/src/src/apis/WaaSEndpointsApi.ts +72 -9
  41. package/src/src/apis/WaaSEventTypesApi.ts +48 -6
  42. package/src/src/apis/WaaSEventsApi.ts +16 -2
  43. package/src/src/apis/WaaSPortalApi.ts +8 -1
  44. package/src/src/apis/WebhooksApi.ts +176 -22
  45. package/src/src/apis/WorkflowsApi.ts +96 -12
@@ -57,7 +57,7 @@ export interface AuthEmailVerificationApiSendEmailVerificationOperationRequest {
57
57
  */
58
58
  export interface AuthEmailVerificationApiInterface {
59
59
  /**
60
- * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
60
+ * Verify the user\'s email using the token from the emailed link. Zyphr does NOT host auth pages and never redeems the token itself. The emailed link points at YOUR `redirect_url` with `?token=<raw>`; your app reads that token and posts it here. Nothing is verified until this call. This endpoint is idempotent: re-posting an already-redeemed token returns `200` with `already_verified: true` rather than an error, so a double submit or a link opened twice is safe. Only a genuinely invalid / expired / unknown token returns `400`. Note `redirect_url` is REQUIRED (snake_case) when sending the verification email — there is no hosted fallback page.
61
61
  * @summary Confirm email verification
62
62
  * @param {ConfirmEmailVerificationRequest} confirmEmailVerificationRequest
63
63
  * @param {*} [options] Override http request option.
@@ -67,7 +67,7 @@ export interface AuthEmailVerificationApiInterface {
67
67
  confirmEmailVerificationRaw(requestParameters: AuthEmailVerificationApiConfirmEmailVerificationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ConfirmEmailVerificationResponse>>;
68
68
 
69
69
  /**
70
- * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
70
+ * Verify the user\'s email using the token from the emailed link. Zyphr does NOT host auth pages and never redeems the token itself. The emailed link points at YOUR `redirect_url` with `?token=<raw>`; your app reads that token and posts it here. Nothing is verified until this call. This endpoint is idempotent: re-posting an already-redeemed token returns `200` with `already_verified: true` rather than an error, so a double submit or a link opened twice is safe. Only a genuinely invalid / expired / unknown token returns `400`. Note `redirect_url` is REQUIRED (snake_case) when sending the verification email — there is no hosted fallback page.
71
71
  * Confirm email verification
72
72
  */
73
73
  confirmEmailVerification(confirmEmailVerificationRequest: ConfirmEmailVerificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ConfirmEmailVerificationResponse>;
@@ -112,7 +112,7 @@ export interface AuthEmailVerificationApiInterface {
112
112
  export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEmailVerificationApiInterface {
113
113
 
114
114
  /**
115
- * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
115
+ * Verify the user\'s email using the token from the emailed link. Zyphr does NOT host auth pages and never redeems the token itself. The emailed link points at YOUR `redirect_url` with `?token=<raw>`; your app reads that token and posts it here. Nothing is verified until this call. This endpoint is idempotent: re-posting an already-redeemed token returns `200` with `already_verified: true` rather than an error, so a double submit or a link opened twice is safe. Only a genuinely invalid / expired / unknown token returns `400`. Note `redirect_url` is REQUIRED (snake_case) when sending the verification email — there is no hosted fallback page.
116
116
  * Confirm email verification
117
117
  */
118
118
  async confirmEmailVerificationRaw(requestParameters: AuthEmailVerificationApiConfirmEmailVerificationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ConfirmEmailVerificationResponse>> {
@@ -130,11 +130,25 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
130
130
  headerParameters['Content-Type'] = 'application/json';
131
131
 
132
132
  if (this.configuration && this.configuration.apiKey) {
133
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
133
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
134
+ {
135
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
136
+
137
+ if (apiKeyValue) {
138
+ headerParameters["X-Application-Secret"] = apiKeyValue;
139
+ }
140
+ }
134
141
  }
135
142
 
136
143
  if (this.configuration && this.configuration.apiKey) {
137
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
144
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
145
+ {
146
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
147
+
148
+ if (apiKeyValue) {
149
+ headerParameters["X-Application-Key"] = apiKeyValue;
150
+ }
151
+ }
138
152
  }
139
153
 
140
154
  const response = await this.request({
@@ -149,7 +163,7 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
149
163
  }
150
164
 
151
165
  /**
152
- * Verify the user\'s email using a token you collected yourself. IMPORTANT: the emailed verification LINK verifies the address server-side **on click** and then redirects to `redirect_url`. So if you take the token off that redirect and post it here, it is already redeemed — and this endpoint treats that as an idempotent **success** (`200` with `already_verified: true`), not an error. Only a genuinely invalid / expired / unknown token returns `400`. `send` / `confirm` / `resend` are NOT a mandatory matched set — `confirm` is for flows where you collect the token directly rather than landing the hosted redirect. Recommended pattern for the redirect landing: call `confirm`, ignore its result, then read the user\'s verified state back and report that — correct whether or not the link already consumed the token.
166
+ * Verify the user\'s email using the token from the emailed link. Zyphr does NOT host auth pages and never redeems the token itself. The emailed link points at YOUR `redirect_url` with `?token=<raw>`; your app reads that token and posts it here. Nothing is verified until this call. This endpoint is idempotent: re-posting an already-redeemed token returns `200` with `already_verified: true` rather than an error, so a double submit or a link opened twice is safe. Only a genuinely invalid / expired / unknown token returns `400`. Note `redirect_url` is REQUIRED (snake_case) when sending the verification email — there is no hosted fallback page.
153
167
  * Confirm email verification
154
168
  */
155
169
  async confirmEmailVerification(confirmEmailVerificationRequest: ConfirmEmailVerificationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ConfirmEmailVerificationResponse> {
@@ -169,7 +183,14 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
169
183
  headerParameters['Content-Type'] = 'application/json';
170
184
 
171
185
  if (this.configuration && this.configuration.apiKey) {
172
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
186
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
187
+ {
188
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
189
+
190
+ if (apiKeyValue) {
191
+ headerParameters["X-Application-Secret"] = apiKeyValue;
192
+ }
193
+ }
173
194
  }
174
195
 
175
196
  if (this.configuration && this.configuration.accessToken) {
@@ -181,7 +202,14 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
181
202
  }
182
203
  }
183
204
  if (this.configuration && this.configuration.apiKey) {
184
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
205
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
206
+ {
207
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
208
+
209
+ if (apiKeyValue) {
210
+ headerParameters["X-Application-Key"] = apiKeyValue;
211
+ }
212
+ }
185
213
  }
186
214
 
187
215
  const response = await this.request({
@@ -216,7 +244,14 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
216
244
  headerParameters['Content-Type'] = 'application/json';
217
245
 
218
246
  if (this.configuration && this.configuration.apiKey) {
219
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
247
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
248
+ {
249
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
250
+
251
+ if (apiKeyValue) {
252
+ headerParameters["X-Application-Secret"] = apiKeyValue;
253
+ }
254
+ }
220
255
  }
221
256
 
222
257
  if (this.configuration && this.configuration.accessToken) {
@@ -228,7 +263,14 @@ export class AuthEmailVerificationApi extends runtime.BaseAPI implements AuthEma
228
263
  }
229
264
  }
230
265
  if (this.configuration && this.configuration.apiKey) {
231
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
266
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
267
+ {
268
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
269
+
270
+ if (apiKeyValue) {
271
+ headerParameters["X-Application-Key"] = apiKeyValue;
272
+ }
273
+ }
232
274
  }
233
275
 
234
276
  const response = await this.request({
@@ -81,11 +81,25 @@ export class AuthLoginApi extends runtime.BaseAPI implements AuthLoginApiInterfa
81
81
  headerParameters['Content-Type'] = 'application/json';
82
82
 
83
83
  if (this.configuration && this.configuration.apiKey) {
84
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
84
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
85
+ {
86
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
87
+
88
+ if (apiKeyValue) {
89
+ headerParameters["X-Application-Secret"] = apiKeyValue;
90
+ }
91
+ }
85
92
  }
86
93
 
87
94
  if (this.configuration && this.configuration.apiKey) {
88
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
95
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
96
+ {
97
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
98
+
99
+ if (apiKeyValue) {
100
+ headerParameters["X-Application-Key"] = apiKeyValue;
101
+ }
102
+ }
89
103
  }
90
104
 
91
105
  const response = await this.request({
@@ -234,11 +234,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
234
234
  headerParameters['Content-Type'] = 'application/json';
235
235
 
236
236
  if (this.configuration && this.configuration.apiKey) {
237
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
237
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
238
+ {
239
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
240
+
241
+ if (apiKeyValue) {
242
+ headerParameters["X-Application-Secret"] = apiKeyValue;
243
+ }
244
+ }
238
245
  }
239
246
 
240
247
  if (this.configuration && this.configuration.apiKey) {
241
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
248
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
249
+ {
250
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
251
+
252
+ if (apiKeyValue) {
253
+ headerParameters["X-Application-Key"] = apiKeyValue;
254
+ }
255
+ }
242
256
  }
243
257
 
244
258
  const response = await this.request({
@@ -278,11 +292,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
278
292
  const headerParameters: runtime.HTTPHeaders = {};
279
293
 
280
294
  if (this.configuration && this.configuration.apiKey) {
281
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
295
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
296
+ {
297
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
298
+
299
+ if (apiKeyValue) {
300
+ headerParameters["X-Application-Secret"] = apiKeyValue;
301
+ }
302
+ }
282
303
  }
283
304
 
284
305
  if (this.configuration && this.configuration.apiKey) {
285
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
306
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
307
+ {
308
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
309
+
310
+ if (apiKeyValue) {
311
+ headerParameters["X-Application-Key"] = apiKeyValue;
312
+ }
313
+ }
286
314
  }
287
315
 
288
316
  const response = await this.request({
@@ -323,11 +351,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
323
351
  headerParameters['Content-Type'] = 'application/json';
324
352
 
325
353
  if (this.configuration && this.configuration.apiKey) {
326
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
354
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
355
+ {
356
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
357
+
358
+ if (apiKeyValue) {
359
+ headerParameters["X-Application-Secret"] = apiKeyValue;
360
+ }
361
+ }
327
362
  }
328
363
 
329
364
  if (this.configuration && this.configuration.apiKey) {
330
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
365
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
366
+ {
367
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
368
+
369
+ if (apiKeyValue) {
370
+ headerParameters["X-Application-Key"] = apiKeyValue;
371
+ }
372
+ }
331
373
  }
332
374
 
333
375
  const response = await this.request({
@@ -369,11 +411,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
369
411
  headerParameters['Content-Type'] = 'application/json';
370
412
 
371
413
  if (this.configuration && this.configuration.apiKey) {
372
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
414
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
415
+ {
416
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
417
+
418
+ if (apiKeyValue) {
419
+ headerParameters["X-Application-Secret"] = apiKeyValue;
420
+ }
421
+ }
373
422
  }
374
423
 
375
424
  if (this.configuration && this.configuration.apiKey) {
376
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
425
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
426
+ {
427
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
428
+
429
+ if (apiKeyValue) {
430
+ headerParameters["X-Application-Key"] = apiKeyValue;
431
+ }
432
+ }
377
433
  }
378
434
 
379
435
  const response = await this.request({
@@ -415,11 +471,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
415
471
  headerParameters['Content-Type'] = 'application/json';
416
472
 
417
473
  if (this.configuration && this.configuration.apiKey) {
418
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
474
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
475
+ {
476
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
477
+
478
+ if (apiKeyValue) {
479
+ headerParameters["X-Application-Secret"] = apiKeyValue;
480
+ }
481
+ }
419
482
  }
420
483
 
421
484
  if (this.configuration && this.configuration.apiKey) {
422
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
485
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
486
+ {
487
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
488
+
489
+ if (apiKeyValue) {
490
+ headerParameters["X-Application-Key"] = apiKeyValue;
491
+ }
492
+ }
423
493
  }
424
494
 
425
495
  const response = await this.request({
@@ -461,11 +531,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
461
531
  headerParameters['Content-Type'] = 'application/json';
462
532
 
463
533
  if (this.configuration && this.configuration.apiKey) {
464
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
534
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
535
+ {
536
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
537
+
538
+ if (apiKeyValue) {
539
+ headerParameters["X-Application-Secret"] = apiKeyValue;
540
+ }
541
+ }
465
542
  }
466
543
 
467
544
  if (this.configuration && this.configuration.apiKey) {
468
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
545
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
546
+ {
547
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
548
+
549
+ if (apiKeyValue) {
550
+ headerParameters["X-Application-Key"] = apiKeyValue;
551
+ }
552
+ }
469
553
  }
470
554
 
471
555
  const response = await this.request({
@@ -507,11 +591,25 @@ export class AuthMFAApi extends runtime.BaseAPI implements AuthMFAApiInterface {
507
591
  headerParameters['Content-Type'] = 'application/json';
508
592
 
509
593
  if (this.configuration && this.configuration.apiKey) {
510
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
594
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
595
+ {
596
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
597
+
598
+ if (apiKeyValue) {
599
+ headerParameters["X-Application-Secret"] = apiKeyValue;
600
+ }
601
+ }
511
602
  }
512
603
 
513
604
  if (this.configuration && this.configuration.apiKey) {
514
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
605
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
606
+ {
607
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
608
+
609
+ if (apiKeyValue) {
610
+ headerParameters["X-Application-Key"] = apiKeyValue;
611
+ }
612
+ }
515
613
  }
516
614
 
517
615
  const response = await this.request({
@@ -107,11 +107,25 @@ export class AuthMagicLinksApi extends runtime.BaseAPI implements AuthMagicLinks
107
107
  headerParameters['Content-Type'] = 'application/json';
108
108
 
109
109
  if (this.configuration && this.configuration.apiKey) {
110
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
110
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
111
+ {
112
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
113
+
114
+ if (apiKeyValue) {
115
+ headerParameters["X-Application-Secret"] = apiKeyValue;
116
+ }
117
+ }
111
118
  }
112
119
 
113
120
  if (this.configuration && this.configuration.apiKey) {
114
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
121
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
122
+ {
123
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
124
+
125
+ if (apiKeyValue) {
126
+ headerParameters["X-Application-Key"] = apiKeyValue;
127
+ }
128
+ }
115
129
  }
116
130
 
117
131
  const response = await this.request({
@@ -153,11 +167,25 @@ export class AuthMagicLinksApi extends runtime.BaseAPI implements AuthMagicLinks
153
167
  headerParameters['Content-Type'] = 'application/json';
154
168
 
155
169
  if (this.configuration && this.configuration.apiKey) {
156
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
170
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
171
+ {
172
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
173
+
174
+ if (apiKeyValue) {
175
+ headerParameters["X-Application-Secret"] = apiKeyValue;
176
+ }
177
+ }
157
178
  }
158
179
 
159
180
  if (this.configuration && this.configuration.apiKey) {
160
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
181
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
182
+ {
183
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
184
+
185
+ if (apiKeyValue) {
186
+ headerParameters["X-Application-Key"] = apiKeyValue;
187
+ }
188
+ }
161
189
  }
162
190
 
163
191
  const response = await this.request({
@@ -311,7 +311,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
311
311
  }
312
312
  }
313
313
  if (this.configuration && this.configuration.apiKey) {
314
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
314
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
315
+ {
316
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
317
+
318
+ if (apiKeyValue) {
319
+ headerParameters["X-Application-Key"] = apiKeyValue;
320
+ }
321
+ }
315
322
  }
316
323
 
317
324
  const response = await this.request({
@@ -359,7 +366,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
359
366
  }
360
367
  }
361
368
  if (this.configuration && this.configuration.apiKey) {
362
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
369
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
370
+ {
371
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
372
+
373
+ if (apiKeyValue) {
374
+ headerParameters["X-Application-Key"] = apiKeyValue;
375
+ }
376
+ }
363
377
  }
364
378
 
365
379
  const response = await this.request({
@@ -409,7 +423,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
409
423
  const headerParameters: runtime.HTTPHeaders = {};
410
424
 
411
425
  if (this.configuration && this.configuration.apiKey) {
412
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
426
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
427
+ {
428
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
429
+
430
+ if (apiKeyValue) {
431
+ headerParameters["X-Application-Key"] = apiKeyValue;
432
+ }
433
+ }
413
434
  }
414
435
 
415
436
  const response = await this.request({
@@ -456,7 +477,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
456
477
  }
457
478
  }
458
479
  if (this.configuration && this.configuration.apiKey) {
459
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
480
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
481
+ {
482
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
483
+
484
+ if (apiKeyValue) {
485
+ headerParameters["X-Application-Key"] = apiKeyValue;
486
+ }
487
+ }
460
488
  }
461
489
 
462
490
  const response = await this.request({
@@ -506,11 +534,25 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
506
534
  const headerParameters: runtime.HTTPHeaders = {};
507
535
 
508
536
  if (this.configuration && this.configuration.apiKey) {
509
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
537
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
538
+ {
539
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
540
+
541
+ if (apiKeyValue) {
542
+ headerParameters["X-Application-Secret"] = apiKeyValue;
543
+ }
544
+ }
510
545
  }
511
546
 
512
547
  if (this.configuration && this.configuration.apiKey) {
513
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
548
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
549
+ {
550
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
551
+
552
+ if (apiKeyValue) {
553
+ headerParameters["X-Application-Key"] = apiKeyValue;
554
+ }
555
+ }
514
556
  }
515
557
 
516
558
  const response = await this.request({
@@ -595,7 +637,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
595
637
  }
596
638
  }
597
639
  if (this.configuration && this.configuration.apiKey) {
598
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
640
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
641
+ {
642
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
643
+
644
+ if (apiKeyValue) {
645
+ headerParameters["X-Application-Key"] = apiKeyValue;
646
+ }
647
+ }
599
648
  }
600
649
 
601
650
  const response = await this.request({
@@ -627,7 +676,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
627
676
  const headerParameters: runtime.HTTPHeaders = {};
628
677
 
629
678
  if (this.configuration && this.configuration.apiKey) {
630
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
679
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
680
+ {
681
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
682
+
683
+ if (apiKeyValue) {
684
+ headerParameters["X-Application-Key"] = apiKeyValue;
685
+ }
686
+ }
631
687
  }
632
688
 
633
689
  const response = await this.request({
@@ -675,11 +731,25 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
675
731
  headerParameters['Content-Type'] = 'application/json';
676
732
 
677
733
  if (this.configuration && this.configuration.apiKey) {
678
- headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
734
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
735
+ {
736
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Secret"); // ApplicationSecret authentication
737
+
738
+ if (apiKeyValue) {
739
+ headerParameters["X-Application-Secret"] = apiKeyValue;
740
+ }
741
+ }
679
742
  }
680
743
 
681
744
  if (this.configuration && this.configuration.apiKey) {
682
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
745
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
746
+ {
747
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
748
+
749
+ if (apiKeyValue) {
750
+ headerParameters["X-Application-Key"] = apiKeyValue;
751
+ }
752
+ }
683
753
  }
684
754
 
685
755
  const response = await this.request({
@@ -738,7 +808,14 @@ export class AuthOAuthApi extends runtime.BaseAPI implements AuthOAuthApiInterfa
738
808
  }
739
809
  }
740
810
  if (this.configuration && this.configuration.apiKey) {
741
- headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
811
+ // An unresolved credential must produce NO header, not an empty one (sc-8162).
812
+ {
813
+ const apiKeyValue = await this.configuration.apiKey("X-Application-Key"); // ApplicationPublicKey authentication
814
+
815
+ if (apiKeyValue) {
816
+ headerParameters["X-Application-Key"] = apiKeyValue;
817
+ }
818
+ }
742
819
  }
743
820
 
744
821
  const response = await this.request({