kleisterjs 2.5.1 → 2.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/.github/RELEASE +1 -1
  2. package/.github/workflows/flake.yml +1 -1
  3. package/.github/workflows/general.yml +1 -1
  4. package/.github/workflows/openapi.yml +1 -1
  5. package/.github/workflows/release.yml +1 -1
  6. package/.openapi-generator/FILES +56 -55
  7. package/CHANGELOG.md +12 -0
  8. package/README.md +2 -2
  9. package/api/auth-api.ts +251 -147
  10. package/api/fabric-api.ts +47 -67
  11. package/api/forge-api.ts +47 -67
  12. package/api/{team-api.ts → group-api.ts} +921 -936
  13. package/api/minecraft-api.ts +44 -67
  14. package/api/mod-api.ts +1016 -461
  15. package/api/neoforge-api.ts +47 -67
  16. package/api/pack-api.ts +378 -419
  17. package/api/profile-api.ts +18 -21
  18. package/api/quilt-api.ts +48 -68
  19. package/api/user-api.ts +554 -580
  20. package/api.ts +1 -1
  21. package/flake.lock +9 -9
  22. package/model/attach-build-to-version-request.ts +33 -0
  23. package/model/attach-minecraft-to-build-request.ts +33 -0
  24. package/model/build.ts +0 -6
  25. package/model/create-build-request.ts +87 -0
  26. package/model/{quilt-build-params.ts → create-group-request.ts} +7 -7
  27. package/model/{pack-icon.ts → create-mod-request.ts} +19 -25
  28. package/model/create-pack-request.ts +45 -0
  29. package/model/create-user-request.ts +57 -0
  30. package/model/create-version-request.ts +39 -0
  31. package/model/delete-group-from-mod-request.ts +27 -0
  32. package/model/delete-group-from-pack-request.ts +27 -0
  33. package/model/delete-pack-from-group-request.ts +27 -0
  34. package/model/delete-pack-from-user-request.ts +27 -0
  35. package/model/{team-mod.ts → group-mod.ts} +19 -19
  36. package/model/{team-pack.ts → group-pack.ts} +19 -19
  37. package/model/{team.ts → group.ts} +8 -8
  38. package/model/index.ts +55 -54
  39. package/model/{build-versions.ts → list-build-versions200-response.ts} +25 -13
  40. package/model/{builds.ts → list-builds200-response.ts} +20 -8
  41. package/model/{fabric-builds.ts → list-fabric-builds200-response.ts} +22 -10
  42. package/model/{fabrics.ts → list-fabrics200-response.ts} +19 -7
  43. package/model/{forge-builds.ts → list-forge-builds200-response.ts} +22 -10
  44. package/model/{forges.ts → list-forges200-response.ts} +19 -7
  45. package/model/list-group-mods200-response.ts +58 -0
  46. package/model/list-group-packs200-response.ts +58 -0
  47. package/model/list-group-users200-response.ts +58 -0
  48. package/model/list-groups200-response.ts +49 -0
  49. package/model/{minecraft-builds.ts → list-minecraft-builds200-response.ts} +22 -10
  50. package/model/{minecrafts.ts → list-minecrafts200-response.ts} +19 -7
  51. package/model/{mod-teams.ts → list-mod-groups200-response.ts} +25 -13
  52. package/model/{mod-users.ts → list-mod-users200-response.ts} +22 -10
  53. package/model/{mods.ts → list-mods200-response.ts} +19 -7
  54. package/model/{neoforge-builds.ts → list-neoforge-builds200-response.ts} +22 -10
  55. package/model/{neoforges.ts → list-neoforges200-response.ts} +19 -7
  56. package/model/{pack-teams.ts → list-pack-groups200-response.ts} +25 -13
  57. package/model/{pack-users.ts → list-pack-users200-response.ts} +22 -10
  58. package/model/{packs.ts → list-packs200-response.ts} +19 -7
  59. package/model/{providers.ts → list-providers200-response.ts} +7 -7
  60. package/model/{quilt-builds.ts → list-quilt-builds200-response.ts} +22 -10
  61. package/model/{quilts.ts → list-quilts200-response.ts} +19 -7
  62. package/model/{user-teams.ts → list-user-groups200-response.ts} +24 -12
  63. package/model/{user-mods.ts → list-user-mods200-response.ts} +22 -10
  64. package/model/{user-packs.ts → list-user-packs200-response.ts} +22 -10
  65. package/model/{users.ts → list-users200-response.ts} +19 -7
  66. package/model/{version-builds.ts → list-version-builds200-response.ts} +25 -13
  67. package/model/{versions.ts → list-versions200-response.ts} +20 -8
  68. package/model/{auth-login.ts → login-auth-request.ts} +4 -4
  69. package/model/mod-avatar.ts +45 -0
  70. package/model/mod.ts +10 -0
  71. package/model/pack-avatar.ts +45 -0
  72. package/model/pack.ts +3 -21
  73. package/model/{build-version-params.ts → permit-group-mod-request.ts} +6 -6
  74. package/model/{forge-build-params.ts → permit-group-pack-request.ts} +6 -6
  75. package/model/{fabric-build-params.ts → permit-pack-group-request.ts} +7 -7
  76. package/model/permit-pack-user-request.ts +33 -0
  77. package/model/profile.ts +9 -9
  78. package/model/redirect-auth-request.ts +27 -0
  79. package/model/update-profile-request.ts +45 -0
  80. package/model/update-user-request.ts +57 -0
  81. package/model/{user-team.ts → user-group.ts} +19 -19
  82. package/model/version-file.ts +0 -12
  83. package/model/version.ts +0 -6
  84. package/openapi.yml +1 -1
  85. package/package.json +1 -1
  86. package/model/minecraft-build-params.ts +0 -33
  87. package/model/mod-team-params.ts +0 -42
  88. package/model/mod-user-params.ts +0 -42
  89. package/model/neoforge-build-params.ts +0 -33
  90. package/model/pack-back.ts +0 -75
  91. package/model/pack-logo.ts +0 -75
  92. package/model/pack-team-params.ts +0 -42
  93. package/model/pack-user-params.ts +0 -42
  94. package/model/team-mod-params.ts +0 -42
  95. package/model/team-mods.ts +0 -46
  96. package/model/team-pack-params.ts +0 -42
  97. package/model/team-packs.ts +0 -46
  98. package/model/team-user-params.ts +0 -42
  99. package/model/team-users.ts +0 -46
  100. package/model/teams.ts +0 -37
  101. package/model/user-mod-params.ts +0 -42
  102. package/model/user-pack-params.ts +0 -42
  103. package/model/user-team-params.ts +0 -42
  104. package/model/version-build-params.ts +0 -33
package/api/auth-api.ts CHANGED
@@ -42,15 +42,17 @@ import {
42
42
  operationServerMap,
43
43
  } from "../base";
44
44
  // @ts-ignore
45
- import type { AuthLogin } from "../model";
46
- // @ts-ignore
47
45
  import type { AuthToken } from "../model";
48
46
  // @ts-ignore
49
47
  import type { AuthVerify } from "../model";
50
48
  // @ts-ignore
49
+ import type { ListProviders200Response } from "../model";
50
+ // @ts-ignore
51
+ import type { LoginAuthRequest } from "../model";
52
+ // @ts-ignore
51
53
  import type { Notification } from "../model";
52
54
  // @ts-ignore
53
- import type { Providers } from "../model";
55
+ import type { RedirectAuthRequest } from "../model";
54
56
  /**
55
57
  * AuthApi - axios parameter creator
56
58
  * @export
@@ -61,21 +63,21 @@ export const AuthApiAxiosParamCreator = function (
61
63
  return {
62
64
  /**
63
65
  *
64
- * @summary Callback for external authentication
66
+ * @summary Callback to parse the defined provider
65
67
  * @param {string} provider An identifier for the auth provider
66
68
  * @param {string} [state] Auth state
67
69
  * @param {string} [code] Auth code
68
70
  * @param {*} [options] Override http request option.
69
71
  * @throws {RequiredError}
70
72
  */
71
- externalCallback: async (
73
+ callbackProvider: async (
72
74
  provider: string,
73
75
  state?: string,
74
76
  code?: string,
75
77
  options: RawAxiosRequestConfig = {},
76
78
  ): Promise<RequestArgs> => {
77
79
  // verify required parameter 'provider' is not null or undefined
78
- assertParamExists("externalCallback", "provider", provider);
80
+ assertParamExists("callbackProvider", "provider", provider);
79
81
  const localVarPath = `/auth/{provider}/callback`.replace(
80
82
  `{${"provider"}}`,
81
83
  encodeURIComponent(String(provider)),
@@ -119,23 +121,14 @@ export const AuthApiAxiosParamCreator = function (
119
121
  },
120
122
  /**
121
123
  *
122
- * @summary Initialize the external authentication
123
- * @param {string} provider An identifier for the auth provider
124
- * @param {string} [state] Auth state
124
+ * @summary Fetch the available auth providers
125
125
  * @param {*} [options] Override http request option.
126
126
  * @throws {RequiredError}
127
127
  */
128
- externalInitialize: async (
129
- provider: string,
130
- state?: string,
128
+ listProviders: async (
131
129
  options: RawAxiosRequestConfig = {},
132
130
  ): Promise<RequestArgs> => {
133
- // verify required parameter 'provider' is not null or undefined
134
- assertParamExists("externalInitialize", "provider", provider);
135
- const localVarPath = `/auth/{provider}/initialize`.replace(
136
- `{${"provider"}}`,
137
- encodeURIComponent(String(provider)),
138
- );
131
+ const localVarPath = `/auth/providers`;
139
132
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
140
133
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
141
134
  let baseOptions;
@@ -151,10 +144,6 @@ export const AuthApiAxiosParamCreator = function (
151
144
  const localVarHeaderParameter = {} as any;
152
145
  const localVarQueryParameter = {} as any;
153
146
 
154
- if (state !== undefined) {
155
- localVarQueryParameter["state"] = state;
156
- }
157
-
158
147
  setSearchParams(localVarUrlObj, localVarQueryParameter);
159
148
  let headersFromBaseOptions =
160
149
  baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -171,14 +160,18 @@ export const AuthApiAxiosParamCreator = function (
171
160
  },
172
161
  /**
173
162
  *
174
- * @summary Fetch the available auth providers
163
+ * @summary Authenticate an user by credentials
164
+ * @param {LoginAuthRequest} loginAuthRequest The credentials to authenticate
175
165
  * @param {*} [options] Override http request option.
176
166
  * @throws {RequiredError}
177
167
  */
178
- externalProviders: async (
168
+ loginAuth: async (
169
+ loginAuthRequest: LoginAuthRequest,
179
170
  options: RawAxiosRequestConfig = {},
180
171
  ): Promise<RequestArgs> => {
181
- const localVarPath = `/auth/providers`;
172
+ // verify required parameter 'loginAuthRequest' is not null or undefined
173
+ assertParamExists("loginAuth", "loginAuthRequest", loginAuthRequest);
174
+ const localVarPath = `/auth/login`;
182
175
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
183
176
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
184
177
  let baseOptions;
@@ -187,13 +180,15 @@ export const AuthApiAxiosParamCreator = function (
187
180
  }
188
181
 
189
182
  const localVarRequestOptions = {
190
- method: "GET",
183
+ method: "POST",
191
184
  ...baseOptions,
192
185
  ...options,
193
186
  };
194
187
  const localVarHeaderParameter = {} as any;
195
188
  const localVarQueryParameter = {} as any;
196
189
 
190
+ localVarHeaderParameter["Content-Type"] = "application/json";
191
+
197
192
  setSearchParams(localVarUrlObj, localVarQueryParameter);
198
193
  let headersFromBaseOptions =
199
194
  baseOptions && baseOptions.headers ? baseOptions.headers : {};
@@ -202,6 +197,11 @@ export const AuthApiAxiosParamCreator = function (
202
197
  ...headersFromBaseOptions,
203
198
  ...options.headers,
204
199
  };
200
+ localVarRequestOptions.data = serializeDataIfNeeded(
201
+ loginAuthRequest,
202
+ localVarRequestOptions,
203
+ configuration,
204
+ );
205
205
 
206
206
  return {
207
207
  url: toPathString(localVarUrlObj),
@@ -210,18 +210,22 @@ export const AuthApiAxiosParamCreator = function (
210
210
  },
211
211
  /**
212
212
  *
213
- * @summary Authenticate an user by credentials
214
- * @param {AuthLogin} authLogin The credentials to authenticate
213
+ * @summary Retrieve real token after redirect
214
+ * @param {RedirectAuthRequest} redirectAuthRequest The redirect token to authenticate
215
215
  * @param {*} [options] Override http request option.
216
216
  * @throws {RequiredError}
217
217
  */
218
- loginAuth: async (
219
- authLogin: AuthLogin,
218
+ redirectAuth: async (
219
+ redirectAuthRequest: RedirectAuthRequest,
220
220
  options: RawAxiosRequestConfig = {},
221
221
  ): Promise<RequestArgs> => {
222
- // verify required parameter 'authLogin' is not null or undefined
223
- assertParamExists("loginAuth", "authLogin", authLogin);
224
- const localVarPath = `/auth/login`;
222
+ // verify required parameter 'redirectAuthRequest' is not null or undefined
223
+ assertParamExists(
224
+ "redirectAuth",
225
+ "redirectAuthRequest",
226
+ redirectAuthRequest,
227
+ );
228
+ const localVarPath = `/auth/redirect`;
225
229
  // use dummy base URL string because the URL constructor only accepts absolute URLs.
226
230
  const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
227
231
  let baseOptions;
@@ -248,7 +252,7 @@ export const AuthApiAxiosParamCreator = function (
248
252
  ...options.headers,
249
253
  };
250
254
  localVarRequestOptions.data = serializeDataIfNeeded(
251
- authLogin,
255
+ redirectAuthRequest,
252
256
  localVarRequestOptions,
253
257
  configuration,
254
258
  );
@@ -283,9 +287,6 @@ export const AuthApiAxiosParamCreator = function (
283
287
  const localVarHeaderParameter = {} as any;
284
288
  const localVarQueryParameter = {} as any;
285
289
 
286
- // authentication Cookie required
287
- await setApiKeyToObject(localVarHeaderParameter, "Cookie", configuration);
288
-
289
290
  // authentication Basic required
290
291
  // http basic authentication required
291
292
  setBasicAuthToObject(localVarRequestOptions, configuration);
@@ -315,6 +316,52 @@ export const AuthApiAxiosParamCreator = function (
315
316
  options: localVarRequestOptions,
316
317
  };
317
318
  },
319
+ /**
320
+ *
321
+ * @summary Request the redirect to defined provider
322
+ * @param {string} provider An identifier for the auth provider
323
+ * @param {*} [options] Override http request option.
324
+ * @throws {RequiredError}
325
+ */
326
+ requestProvider: async (
327
+ provider: string,
328
+ options: RawAxiosRequestConfig = {},
329
+ ): Promise<RequestArgs> => {
330
+ // verify required parameter 'provider' is not null or undefined
331
+ assertParamExists("requestProvider", "provider", provider);
332
+ const localVarPath = `/auth/{provider}/request`.replace(
333
+ `{${"provider"}}`,
334
+ encodeURIComponent(String(provider)),
335
+ );
336
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
337
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
338
+ let baseOptions;
339
+ if (configuration) {
340
+ baseOptions = configuration.baseOptions;
341
+ }
342
+
343
+ const localVarRequestOptions = {
344
+ method: "GET",
345
+ ...baseOptions,
346
+ ...options,
347
+ };
348
+ const localVarHeaderParameter = {} as any;
349
+ const localVarQueryParameter = {} as any;
350
+
351
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
352
+ let headersFromBaseOptions =
353
+ baseOptions && baseOptions.headers ? baseOptions.headers : {};
354
+ localVarRequestOptions.headers = {
355
+ ...localVarHeaderParameter,
356
+ ...headersFromBaseOptions,
357
+ ...options.headers,
358
+ };
359
+
360
+ return {
361
+ url: toPathString(localVarUrlObj),
362
+ options: localVarRequestOptions,
363
+ };
364
+ },
318
365
  /**
319
366
  *
320
367
  * @summary Verify validity for an authentication token
@@ -340,9 +387,6 @@ export const AuthApiAxiosParamCreator = function (
340
387
  const localVarHeaderParameter = {} as any;
341
388
  const localVarQueryParameter = {} as any;
342
389
 
343
- // authentication Cookie required
344
- await setApiKeyToObject(localVarHeaderParameter, "Cookie", configuration);
345
-
346
390
  // authentication Basic required
347
391
  // http basic authentication required
348
392
  setBasicAuthToObject(localVarRequestOptions, configuration);
@@ -384,23 +428,23 @@ export const AuthApiFp = function (configuration?: Configuration) {
384
428
  return {
385
429
  /**
386
430
  *
387
- * @summary Callback for external authentication
431
+ * @summary Callback to parse the defined provider
388
432
  * @param {string} provider An identifier for the auth provider
389
433
  * @param {string} [state] Auth state
390
434
  * @param {string} [code] Auth code
391
435
  * @param {*} [options] Override http request option.
392
436
  * @throws {RequiredError}
393
437
  */
394
- async externalCallback(
438
+ async callbackProvider(
395
439
  provider: string,
396
440
  state?: string,
397
441
  code?: string,
398
442
  options?: RawAxiosRequestConfig,
399
443
  ): Promise<
400
- (axios?: AxiosInstance, basePath?: string) => AxiosPromise<Notification>
444
+ (axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>
401
445
  > {
402
446
  const localVarAxiosArgs =
403
- await localVarAxiosParamCreator.externalCallback(
447
+ await localVarAxiosParamCreator.callbackProvider(
404
448
  provider,
405
449
  state,
406
450
  code,
@@ -408,7 +452,7 @@ export const AuthApiFp = function (configuration?: Configuration) {
408
452
  );
409
453
  const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
410
454
  const localVarOperationServerBasePath =
411
- operationServerMap["AuthApi.externalCallback"]?.[
455
+ operationServerMap["AuthApi.callbackProvider"]?.[
412
456
  localVarOperationServerIndex
413
457
  ]?.url;
414
458
  return (axios, basePath) =>
@@ -421,28 +465,23 @@ export const AuthApiFp = function (configuration?: Configuration) {
421
465
  },
422
466
  /**
423
467
  *
424
- * @summary Initialize the external authentication
425
- * @param {string} provider An identifier for the auth provider
426
- * @param {string} [state] Auth state
468
+ * @summary Fetch the available auth providers
427
469
  * @param {*} [options] Override http request option.
428
470
  * @throws {RequiredError}
429
471
  */
430
- async externalInitialize(
431
- provider: string,
432
- state?: string,
472
+ async listProviders(
433
473
  options?: RawAxiosRequestConfig,
434
474
  ): Promise<
435
- (axios?: AxiosInstance, basePath?: string) => AxiosPromise<Notification>
475
+ (
476
+ axios?: AxiosInstance,
477
+ basePath?: string,
478
+ ) => AxiosPromise<ListProviders200Response>
436
479
  > {
437
480
  const localVarAxiosArgs =
438
- await localVarAxiosParamCreator.externalInitialize(
439
- provider,
440
- state,
441
- options,
442
- );
481
+ await localVarAxiosParamCreator.listProviders(options);
443
482
  const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
444
483
  const localVarOperationServerBasePath =
445
- operationServerMap["AuthApi.externalInitialize"]?.[
484
+ operationServerMap["AuthApi.listProviders"]?.[
446
485
  localVarOperationServerIndex
447
486
  ]?.url;
448
487
  return (axios, basePath) =>
@@ -455,22 +494,25 @@ export const AuthApiFp = function (configuration?: Configuration) {
455
494
  },
456
495
  /**
457
496
  *
458
- * @summary Fetch the available auth providers
497
+ * @summary Authenticate an user by credentials
498
+ * @param {LoginAuthRequest} loginAuthRequest The credentials to authenticate
459
499
  * @param {*} [options] Override http request option.
460
500
  * @throws {RequiredError}
461
501
  */
462
- async externalProviders(
502
+ async loginAuth(
503
+ loginAuthRequest: LoginAuthRequest,
463
504
  options?: RawAxiosRequestConfig,
464
505
  ): Promise<
465
- (axios?: AxiosInstance, basePath?: string) => AxiosPromise<Providers>
506
+ (axios?: AxiosInstance, basePath?: string) => AxiosPromise<AuthToken>
466
507
  > {
467
- const localVarAxiosArgs =
468
- await localVarAxiosParamCreator.externalProviders(options);
508
+ const localVarAxiosArgs = await localVarAxiosParamCreator.loginAuth(
509
+ loginAuthRequest,
510
+ options,
511
+ );
469
512
  const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
470
513
  const localVarOperationServerBasePath =
471
- operationServerMap["AuthApi.externalProviders"]?.[
472
- localVarOperationServerIndex
473
- ]?.url;
514
+ operationServerMap["AuthApi.loginAuth"]?.[localVarOperationServerIndex]
515
+ ?.url;
474
516
  return (axios, basePath) =>
475
517
  createRequestFunction(
476
518
  localVarAxiosArgs,
@@ -481,25 +523,26 @@ export const AuthApiFp = function (configuration?: Configuration) {
481
523
  },
482
524
  /**
483
525
  *
484
- * @summary Authenticate an user by credentials
485
- * @param {AuthLogin} authLogin The credentials to authenticate
526
+ * @summary Retrieve real token after redirect
527
+ * @param {RedirectAuthRequest} redirectAuthRequest The redirect token to authenticate
486
528
  * @param {*} [options] Override http request option.
487
529
  * @throws {RequiredError}
488
530
  */
489
- async loginAuth(
490
- authLogin: AuthLogin,
531
+ async redirectAuth(
532
+ redirectAuthRequest: RedirectAuthRequest,
491
533
  options?: RawAxiosRequestConfig,
492
534
  ): Promise<
493
535
  (axios?: AxiosInstance, basePath?: string) => AxiosPromise<AuthToken>
494
536
  > {
495
- const localVarAxiosArgs = await localVarAxiosParamCreator.loginAuth(
496
- authLogin,
537
+ const localVarAxiosArgs = await localVarAxiosParamCreator.redirectAuth(
538
+ redirectAuthRequest,
497
539
  options,
498
540
  );
499
541
  const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
500
542
  const localVarOperationServerBasePath =
501
- operationServerMap["AuthApi.loginAuth"]?.[localVarOperationServerIndex]
502
- ?.url;
543
+ operationServerMap["AuthApi.redirectAuth"]?.[
544
+ localVarOperationServerIndex
545
+ ]?.url;
503
546
  return (axios, basePath) =>
504
547
  createRequestFunction(
505
548
  localVarAxiosArgs,
@@ -534,6 +577,36 @@ export const AuthApiFp = function (configuration?: Configuration) {
534
577
  configuration,
535
578
  )(axios, localVarOperationServerBasePath || basePath);
536
579
  },
580
+ /**
581
+ *
582
+ * @summary Request the redirect to defined provider
583
+ * @param {string} provider An identifier for the auth provider
584
+ * @param {*} [options] Override http request option.
585
+ * @throws {RequiredError}
586
+ */
587
+ async requestProvider(
588
+ provider: string,
589
+ options?: RawAxiosRequestConfig,
590
+ ): Promise<
591
+ (axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>
592
+ > {
593
+ const localVarAxiosArgs = await localVarAxiosParamCreator.requestProvider(
594
+ provider,
595
+ options,
596
+ );
597
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
598
+ const localVarOperationServerBasePath =
599
+ operationServerMap["AuthApi.requestProvider"]?.[
600
+ localVarOperationServerIndex
601
+ ]?.url;
602
+ return (axios, basePath) =>
603
+ createRequestFunction(
604
+ localVarAxiosArgs,
605
+ globalAxios,
606
+ BASE_PATH,
607
+ configuration,
608
+ )(axios, localVarOperationServerBasePath || basePath);
609
+ },
537
610
  /**
538
611
  *
539
612
  * @summary Verify validity for an authentication token
@@ -575,17 +648,17 @@ export const AuthApiFactory = function (
575
648
  return {
576
649
  /**
577
650
  *
578
- * @summary Callback for external authentication
579
- * @param {AuthApiExternalCallbackRequest} requestParameters Request parameters.
651
+ * @summary Callback to parse the defined provider
652
+ * @param {AuthApiCallbackProviderRequest} requestParameters Request parameters.
580
653
  * @param {*} [options] Override http request option.
581
654
  * @throws {RequiredError}
582
655
  */
583
- externalCallback(
584
- requestParameters: AuthApiExternalCallbackRequest,
656
+ callbackProvider(
657
+ requestParameters: AuthApiCallbackProviderRequest,
585
658
  options?: RawAxiosRequestConfig,
586
- ): AxiosPromise<Notification> {
659
+ ): AxiosPromise<void> {
587
660
  return localVarFp
588
- .externalCallback(
661
+ .callbackProvider(
589
662
  requestParameters.provider,
590
663
  requestParameters.state,
591
664
  requestParameters.code,
@@ -595,49 +668,45 @@ export const AuthApiFactory = function (
595
668
  },
596
669
  /**
597
670
  *
598
- * @summary Initialize the external authentication
599
- * @param {AuthApiExternalInitializeRequest} requestParameters Request parameters.
671
+ * @summary Fetch the available auth providers
600
672
  * @param {*} [options] Override http request option.
601
673
  * @throws {RequiredError}
602
674
  */
603
- externalInitialize(
604
- requestParameters: AuthApiExternalInitializeRequest,
675
+ listProviders(
605
676
  options?: RawAxiosRequestConfig,
606
- ): AxiosPromise<Notification> {
677
+ ): AxiosPromise<ListProviders200Response> {
607
678
  return localVarFp
608
- .externalInitialize(
609
- requestParameters.provider,
610
- requestParameters.state,
611
- options,
612
- )
679
+ .listProviders(options)
613
680
  .then((request) => request(axios, basePath));
614
681
  },
615
682
  /**
616
683
  *
617
- * @summary Fetch the available auth providers
684
+ * @summary Authenticate an user by credentials
685
+ * @param {AuthApiLoginAuthRequest} requestParameters Request parameters.
618
686
  * @param {*} [options] Override http request option.
619
687
  * @throws {RequiredError}
620
688
  */
621
- externalProviders(
689
+ loginAuth(
690
+ requestParameters: AuthApiLoginAuthRequest,
622
691
  options?: RawAxiosRequestConfig,
623
- ): AxiosPromise<Providers> {
692
+ ): AxiosPromise<AuthToken> {
624
693
  return localVarFp
625
- .externalProviders(options)
694
+ .loginAuth(requestParameters.loginAuthRequest, options)
626
695
  .then((request) => request(axios, basePath));
627
696
  },
628
697
  /**
629
698
  *
630
- * @summary Authenticate an user by credentials
631
- * @param {AuthApiLoginAuthRequest} requestParameters Request parameters.
699
+ * @summary Retrieve real token after redirect
700
+ * @param {AuthApiRedirectAuthRequest} requestParameters Request parameters.
632
701
  * @param {*} [options] Override http request option.
633
702
  * @throws {RequiredError}
634
703
  */
635
- loginAuth(
636
- requestParameters: AuthApiLoginAuthRequest,
704
+ redirectAuth(
705
+ requestParameters: AuthApiRedirectAuthRequest,
637
706
  options?: RawAxiosRequestConfig,
638
707
  ): AxiosPromise<AuthToken> {
639
708
  return localVarFp
640
- .loginAuth(requestParameters.authLogin, options)
709
+ .redirectAuth(requestParameters.redirectAuthRequest, options)
641
710
  .then((request) => request(axios, basePath));
642
711
  },
643
712
  /**
@@ -651,6 +720,21 @@ export const AuthApiFactory = function (
651
720
  .refreshAuth(options)
652
721
  .then((request) => request(axios, basePath));
653
722
  },
723
+ /**
724
+ *
725
+ * @summary Request the redirect to defined provider
726
+ * @param {AuthApiRequestProviderRequest} requestParameters Request parameters.
727
+ * @param {*} [options] Override http request option.
728
+ * @throws {RequiredError}
729
+ */
730
+ requestProvider(
731
+ requestParameters: AuthApiRequestProviderRequest,
732
+ options?: RawAxiosRequestConfig,
733
+ ): AxiosPromise<void> {
734
+ return localVarFp
735
+ .requestProvider(requestParameters.provider, options)
736
+ .then((request) => request(axios, basePath));
737
+ },
654
738
  /**
655
739
  *
656
740
  * @summary Verify validity for an authentication token
@@ -666,66 +750,73 @@ export const AuthApiFactory = function (
666
750
  };
667
751
 
668
752
  /**
669
- * Request parameters for externalCallback operation in AuthApi.
753
+ * Request parameters for callbackProvider operation in AuthApi.
670
754
  * @export
671
- * @interface AuthApiExternalCallbackRequest
755
+ * @interface AuthApiCallbackProviderRequest
672
756
  */
673
- export interface AuthApiExternalCallbackRequest {
757
+ export interface AuthApiCallbackProviderRequest {
674
758
  /**
675
759
  * An identifier for the auth provider
676
760
  * @type {string}
677
- * @memberof AuthApiExternalCallback
761
+ * @memberof AuthApiCallbackProvider
678
762
  */
679
763
  readonly provider: string;
680
764
 
681
765
  /**
682
766
  * Auth state
683
767
  * @type {string}
684
- * @memberof AuthApiExternalCallback
768
+ * @memberof AuthApiCallbackProvider
685
769
  */
686
770
  readonly state?: string;
687
771
 
688
772
  /**
689
773
  * Auth code
690
774
  * @type {string}
691
- * @memberof AuthApiExternalCallback
775
+ * @memberof AuthApiCallbackProvider
692
776
  */
693
777
  readonly code?: string;
694
778
  }
695
779
 
696
780
  /**
697
- * Request parameters for externalInitialize operation in AuthApi.
781
+ * Request parameters for loginAuth operation in AuthApi.
698
782
  * @export
699
- * @interface AuthApiExternalInitializeRequest
783
+ * @interface AuthApiLoginAuthRequest
700
784
  */
701
- export interface AuthApiExternalInitializeRequest {
785
+ export interface AuthApiLoginAuthRequest {
702
786
  /**
703
- * An identifier for the auth provider
704
- * @type {string}
705
- * @memberof AuthApiExternalInitialize
787
+ * The credentials to authenticate
788
+ * @type {LoginAuthRequest}
789
+ * @memberof AuthApiLoginAuth
706
790
  */
707
- readonly provider: string;
791
+ readonly loginAuthRequest: LoginAuthRequest;
792
+ }
708
793
 
794
+ /**
795
+ * Request parameters for redirectAuth operation in AuthApi.
796
+ * @export
797
+ * @interface AuthApiRedirectAuthRequest
798
+ */
799
+ export interface AuthApiRedirectAuthRequest {
709
800
  /**
710
- * Auth state
711
- * @type {string}
712
- * @memberof AuthApiExternalInitialize
801
+ * The redirect token to authenticate
802
+ * @type {RedirectAuthRequest}
803
+ * @memberof AuthApiRedirectAuth
713
804
  */
714
- readonly state?: string;
805
+ readonly redirectAuthRequest: RedirectAuthRequest;
715
806
  }
716
807
 
717
808
  /**
718
- * Request parameters for loginAuth operation in AuthApi.
809
+ * Request parameters for requestProvider operation in AuthApi.
719
810
  * @export
720
- * @interface AuthApiLoginAuthRequest
811
+ * @interface AuthApiRequestProviderRequest
721
812
  */
722
- export interface AuthApiLoginAuthRequest {
813
+ export interface AuthApiRequestProviderRequest {
723
814
  /**
724
- * The credentials to authenticate
725
- * @type {AuthLogin}
726
- * @memberof AuthApiLoginAuth
815
+ * An identifier for the auth provider
816
+ * @type {string}
817
+ * @memberof AuthApiRequestProvider
727
818
  */
728
- readonly authLogin: AuthLogin;
819
+ readonly provider: string;
729
820
  }
730
821
 
731
822
  /**
@@ -737,18 +828,18 @@ export interface AuthApiLoginAuthRequest {
737
828
  export class AuthApi extends BaseAPI {
738
829
  /**
739
830
  *
740
- * @summary Callback for external authentication
741
- * @param {AuthApiExternalCallbackRequest} requestParameters Request parameters.
831
+ * @summary Callback to parse the defined provider
832
+ * @param {AuthApiCallbackProviderRequest} requestParameters Request parameters.
742
833
  * @param {*} [options] Override http request option.
743
834
  * @throws {RequiredError}
744
835
  * @memberof AuthApi
745
836
  */
746
- public externalCallback(
747
- requestParameters: AuthApiExternalCallbackRequest,
837
+ public callbackProvider(
838
+ requestParameters: AuthApiCallbackProviderRequest,
748
839
  options?: RawAxiosRequestConfig,
749
840
  ) {
750
841
  return AuthApiFp(this.configuration)
751
- .externalCallback(
842
+ .callbackProvider(
752
843
  requestParameters.provider,
753
844
  requestParameters.state,
754
845
  requestParameters.code,
@@ -759,52 +850,48 @@ export class AuthApi extends BaseAPI {
759
850
 
760
851
  /**
761
852
  *
762
- * @summary Initialize the external authentication
763
- * @param {AuthApiExternalInitializeRequest} requestParameters Request parameters.
853
+ * @summary Fetch the available auth providers
764
854
  * @param {*} [options] Override http request option.
765
855
  * @throws {RequiredError}
766
856
  * @memberof AuthApi
767
857
  */
768
- public externalInitialize(
769
- requestParameters: AuthApiExternalInitializeRequest,
770
- options?: RawAxiosRequestConfig,
771
- ) {
858
+ public listProviders(options?: RawAxiosRequestConfig) {
772
859
  return AuthApiFp(this.configuration)
773
- .externalInitialize(
774
- requestParameters.provider,
775
- requestParameters.state,
776
- options,
777
- )
860
+ .listProviders(options)
778
861
  .then((request) => request(this.axios, this.basePath));
779
862
  }
780
863
 
781
864
  /**
782
865
  *
783
- * @summary Fetch the available auth providers
866
+ * @summary Authenticate an user by credentials
867
+ * @param {AuthApiLoginAuthRequest} requestParameters Request parameters.
784
868
  * @param {*} [options] Override http request option.
785
869
  * @throws {RequiredError}
786
870
  * @memberof AuthApi
787
871
  */
788
- public externalProviders(options?: RawAxiosRequestConfig) {
872
+ public loginAuth(
873
+ requestParameters: AuthApiLoginAuthRequest,
874
+ options?: RawAxiosRequestConfig,
875
+ ) {
789
876
  return AuthApiFp(this.configuration)
790
- .externalProviders(options)
877
+ .loginAuth(requestParameters.loginAuthRequest, options)
791
878
  .then((request) => request(this.axios, this.basePath));
792
879
  }
793
880
 
794
881
  /**
795
882
  *
796
- * @summary Authenticate an user by credentials
797
- * @param {AuthApiLoginAuthRequest} requestParameters Request parameters.
883
+ * @summary Retrieve real token after redirect
884
+ * @param {AuthApiRedirectAuthRequest} requestParameters Request parameters.
798
885
  * @param {*} [options] Override http request option.
799
886
  * @throws {RequiredError}
800
887
  * @memberof AuthApi
801
888
  */
802
- public loginAuth(
803
- requestParameters: AuthApiLoginAuthRequest,
889
+ public redirectAuth(
890
+ requestParameters: AuthApiRedirectAuthRequest,
804
891
  options?: RawAxiosRequestConfig,
805
892
  ) {
806
893
  return AuthApiFp(this.configuration)
807
- .loginAuth(requestParameters.authLogin, options)
894
+ .redirectAuth(requestParameters.redirectAuthRequest, options)
808
895
  .then((request) => request(this.axios, this.basePath));
809
896
  }
810
897
 
@@ -821,6 +908,23 @@ export class AuthApi extends BaseAPI {
821
908
  .then((request) => request(this.axios, this.basePath));
822
909
  }
823
910
 
911
+ /**
912
+ *
913
+ * @summary Request the redirect to defined provider
914
+ * @param {AuthApiRequestProviderRequest} requestParameters Request parameters.
915
+ * @param {*} [options] Override http request option.
916
+ * @throws {RequiredError}
917
+ * @memberof AuthApi
918
+ */
919
+ public requestProvider(
920
+ requestParameters: AuthApiRequestProviderRequest,
921
+ options?: RawAxiosRequestConfig,
922
+ ) {
923
+ return AuthApiFp(this.configuration)
924
+ .requestProvider(requestParameters.provider, options)
925
+ .then((request) => request(this.axios, this.basePath));
926
+ }
927
+
824
928
  /**
825
929
  *
826
930
  * @summary Verify validity for an authentication token