@knowledge-stack/ksapi 1.27.2 → 1.28.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.
@@ -84,6 +84,7 @@ docs/PipelineStatus.md
84
84
  docs/Polygon.md
85
85
  docs/PolygonReference.md
86
86
  docs/RootResponse.md
87
+ docs/SSOInitiateResponse.md
87
88
  docs/ScoredChunkResponse.md
88
89
  docs/SectionContentItem.md
89
90
  docs/SectionContentItemOrChunkContentItem.md
@@ -218,6 +219,7 @@ src/models/PipelineStatus.ts
218
219
  src/models/Polygon.ts
219
220
  src/models/PolygonReference.ts
220
221
  src/models/RootResponse.ts
222
+ src/models/SSOInitiateResponse.ts
221
223
  src/models/ScoredChunkResponse.ts
222
224
  src/models/SectionContentItem.ts
223
225
  src/models/SectionContentItemOrChunkContentItem.ts
package/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # @knowledge-stack/ksapi@1.27.2
1
+ # @knowledge-stack/ksapi@1.28.0
2
2
 
3
3
  A TypeScript SDK client for the localhost API.
4
4
 
@@ -215,6 +215,7 @@ All URIs are relative to *http://localhost:8000*
215
215
  - [Polygon](docs/Polygon.md)
216
216
  - [PolygonReference](docs/PolygonReference.md)
217
217
  - [RootResponse](docs/RootResponse.md)
218
+ - [SSOInitiateResponse](docs/SSOInitiateResponse.md)
218
219
  - [ScoredChunkResponse](docs/ScoredChunkResponse.md)
219
220
  - [SectionContentItem](docs/SectionContentItem.md)
220
221
  - [SectionContentItemOrChunkContentItem](docs/SectionContentItemOrChunkContentItem.md)
@@ -261,7 +262,7 @@ and is automatically generated by the
261
262
  [OpenAPI Generator](https://openapi-generator.tech) project:
262
263
 
263
264
  - API version: `0.1.0`
264
- - Package version: `1.27.2`
265
+ - Package version: `1.28.0`
265
266
  - Generator version: `7.20.0`
266
267
  - Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
267
268
 
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { CreatePasswordUserRequest, EmailSentResponse, EmailVerificationRequest, IdpType, PasswordResetRequest, PasswordResetWithTokenRequest, SignInRequest, UserResponse } from '../models/index';
13
+ import type { CreatePasswordUserRequest, EmailSentResponse, EmailVerificationRequest, IdpType, PasswordResetRequest, PasswordResetWithTokenRequest, SSOInitiateResponse, SignInRequest, UserResponse } from '../models/index';
14
14
  export interface CreatePasswordUserOperationRequest {
15
15
  createPasswordUserRequest: CreatePasswordUserRequest;
16
16
  }
@@ -90,12 +90,12 @@ export interface AuthApiInterface {
90
90
  * @throws {RequiredError}
91
91
  * @memberof AuthApiInterface
92
92
  */
93
- initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
93
+ initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>>;
94
94
  /**
95
95
  * Initiate SSO with the given provider and tenant ID.
96
96
  * Initiate Sso Handler
97
97
  */
98
- initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
98
+ initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse>;
99
99
  /**
100
100
  * Creates request options for oauth2Callback without sending the request
101
101
  * @param {IdpType} provider Provider to initiate SSO with
@@ -299,12 +299,12 @@ export declare class AuthApi extends runtime.BaseAPI implements AuthApiInterface
299
299
  * Initiate SSO with the given provider and tenant ID.
300
300
  * Initiate Sso Handler
301
301
  */
302
- initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
302
+ initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>>;
303
303
  /**
304
304
  * Initiate SSO with the given provider and tenant ID.
305
305
  * Initiate Sso Handler
306
306
  */
307
- initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
307
+ initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse>;
308
308
  /**
309
309
  * Creates request options for oauth2Callback without sending the request
310
310
  */
@@ -102,12 +102,7 @@ class AuthApi extends runtime.BaseAPI {
102
102
  return __awaiter(this, void 0, void 0, function* () {
103
103
  const requestOptions = yield this.initiateSsoRequestOpts(requestParameters);
104
104
  const response = yield this.request(requestOptions, initOverrides);
105
- if (this.isJsonMime(response.headers.get('content-type'))) {
106
- return new runtime.JSONApiResponse(response);
107
- }
108
- else {
109
- return new runtime.TextApiResponse(response);
110
- }
105
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.SSOInitiateResponseFromJSON)(jsonValue));
111
106
  });
112
107
  }
113
108
  /**
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { CreatePasswordUserRequest, EmailSentResponse, EmailVerificationRequest, IdpType, PasswordResetRequest, PasswordResetWithTokenRequest, SignInRequest, UserResponse } from '../models/index';
13
+ import type { CreatePasswordUserRequest, EmailSentResponse, EmailVerificationRequest, IdpType, PasswordResetRequest, PasswordResetWithTokenRequest, SSOInitiateResponse, SignInRequest, UserResponse } from '../models/index';
14
14
  export interface CreatePasswordUserOperationRequest {
15
15
  createPasswordUserRequest: CreatePasswordUserRequest;
16
16
  }
@@ -90,12 +90,12 @@ export interface AuthApiInterface {
90
90
  * @throws {RequiredError}
91
91
  * @memberof AuthApiInterface
92
92
  */
93
- initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
93
+ initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>>;
94
94
  /**
95
95
  * Initiate SSO with the given provider and tenant ID.
96
96
  * Initiate Sso Handler
97
97
  */
98
- initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
98
+ initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse>;
99
99
  /**
100
100
  * Creates request options for oauth2Callback without sending the request
101
101
  * @param {IdpType} provider Provider to initiate SSO with
@@ -299,12 +299,12 @@ export declare class AuthApi extends runtime.BaseAPI implements AuthApiInterface
299
299
  * Initiate SSO with the given provider and tenant ID.
300
300
  * Initiate Sso Handler
301
301
  */
302
- initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
302
+ initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>>;
303
303
  /**
304
304
  * Initiate SSO with the given provider and tenant ID.
305
305
  * Initiate Sso Handler
306
306
  */
307
- initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
307
+ initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse>;
308
308
  /**
309
309
  * Creates request options for oauth2Callback without sending the request
310
310
  */
@@ -21,7 +21,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
21
21
  });
22
22
  };
23
23
  import * as runtime from '../runtime';
24
- import { CreatePasswordUserRequestToJSON, EmailSentResponseFromJSON, EmailVerificationRequestToJSON, PasswordResetRequestToJSON, PasswordResetWithTokenRequestToJSON, SignInRequestToJSON, UserResponseFromJSON, } from '../models/index';
24
+ import { CreatePasswordUserRequestToJSON, EmailSentResponseFromJSON, EmailVerificationRequestToJSON, PasswordResetRequestToJSON, PasswordResetWithTokenRequestToJSON, SSOInitiateResponseFromJSON, SignInRequestToJSON, UserResponseFromJSON, } from '../models/index';
25
25
  /**
26
26
  *
27
27
  */
@@ -99,12 +99,7 @@ export class AuthApi extends runtime.BaseAPI {
99
99
  return __awaiter(this, void 0, void 0, function* () {
100
100
  const requestOptions = yield this.initiateSsoRequestOpts(requestParameters);
101
101
  const response = yield this.request(requestOptions, initOverrides);
102
- if (this.isJsonMime(response.headers.get('content-type'))) {
103
- return new runtime.JSONApiResponse(response);
104
- }
105
- else {
106
- return new runtime.TextApiResponse(response);
107
- }
102
+ return new runtime.JSONApiResponse(response, (jsonValue) => SSOInitiateResponseFromJSON(jsonValue));
108
103
  });
109
104
  }
110
105
  /**
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SSOInitiateResponse
16
+ */
17
+ export interface SSOInitiateResponse {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof SSOInitiateResponse
22
+ */
23
+ redirectUrl: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the SSOInitiateResponse interface.
27
+ */
28
+ export declare function instanceOfSSOInitiateResponse(value: object): value is SSOInitiateResponse;
29
+ export declare function SSOInitiateResponseFromJSON(json: any): SSOInitiateResponse;
30
+ export declare function SSOInitiateResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SSOInitiateResponse;
31
+ export declare function SSOInitiateResponseToJSON(json: any): SSOInitiateResponse;
32
+ export declare function SSOInitiateResponseToJSONTyped(value?: SSOInitiateResponse | null, ignoreDiscriminator?: boolean): any;
33
+ export declare const SSOInitiateResponsePropertyValidationAttributesMap: {
34
+ [property: string]: {
35
+ maxLength?: number;
36
+ minLength?: number;
37
+ pattern?: string;
38
+ maximum?: number;
39
+ exclusiveMaximum?: boolean;
40
+ minimum?: number;
41
+ exclusiveMinimum?: boolean;
42
+ multipleOf?: number;
43
+ maxItems?: number;
44
+ minItems?: number;
45
+ uniqueItems?: boolean;
46
+ };
47
+ };
@@ -0,0 +1,44 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Knowledge Stack API
5
+ * Knowledge Stack backend API for authentication and knowledge management
6
+ *
7
+ * The version of the OpenAPI document: 0.1.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the SSOInitiateResponse interface.
16
+ */
17
+ export function instanceOfSSOInitiateResponse(value) {
18
+ if (!('redirectUrl' in value) || value['redirectUrl'] === undefined)
19
+ return false;
20
+ return true;
21
+ }
22
+ export function SSOInitiateResponseFromJSON(json) {
23
+ return SSOInitiateResponseFromJSONTyped(json, false);
24
+ }
25
+ export function SSOInitiateResponseFromJSONTyped(json, ignoreDiscriminator) {
26
+ if (json == null) {
27
+ return json;
28
+ }
29
+ return {
30
+ 'redirectUrl': json['redirect_url'],
31
+ };
32
+ }
33
+ export function SSOInitiateResponseToJSON(json) {
34
+ return SSOInitiateResponseToJSONTyped(json, false);
35
+ }
36
+ export function SSOInitiateResponseToJSONTyped(value, ignoreDiscriminator = false) {
37
+ if (value == null) {
38
+ return value;
39
+ }
40
+ return {
41
+ 'redirect_url': value['redirectUrl'],
42
+ };
43
+ }
44
+ export const SSOInitiateResponsePropertyValidationAttributesMap = {};
@@ -71,6 +71,7 @@ export * from './PipelineStatus';
71
71
  export * from './Polygon';
72
72
  export * from './PolygonReference';
73
73
  export * from './RootResponse';
74
+ export * from './SSOInitiateResponse';
74
75
  export * from './ScoredChunkResponse';
75
76
  export * from './SectionContentItem';
76
77
  export * from './SectionContentItemOrChunkContentItem';
@@ -73,6 +73,7 @@ export * from './PipelineStatus';
73
73
  export * from './Polygon';
74
74
  export * from './PolygonReference';
75
75
  export * from './RootResponse';
76
+ export * from './SSOInitiateResponse';
76
77
  export * from './ScoredChunkResponse';
77
78
  export * from './SectionContentItem';
78
79
  export * from './SectionContentItemOrChunkContentItem';
@@ -0,0 +1,47 @@
1
+ /**
2
+ * Knowledge Stack API
3
+ * Knowledge Stack backend API for authentication and knowledge management
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SSOInitiateResponse
16
+ */
17
+ export interface SSOInitiateResponse {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof SSOInitiateResponse
22
+ */
23
+ redirectUrl: string;
24
+ }
25
+ /**
26
+ * Check if a given object implements the SSOInitiateResponse interface.
27
+ */
28
+ export declare function instanceOfSSOInitiateResponse(value: object): value is SSOInitiateResponse;
29
+ export declare function SSOInitiateResponseFromJSON(json: any): SSOInitiateResponse;
30
+ export declare function SSOInitiateResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SSOInitiateResponse;
31
+ export declare function SSOInitiateResponseToJSON(json: any): SSOInitiateResponse;
32
+ export declare function SSOInitiateResponseToJSONTyped(value?: SSOInitiateResponse | null, ignoreDiscriminator?: boolean): any;
33
+ export declare const SSOInitiateResponsePropertyValidationAttributesMap: {
34
+ [property: string]: {
35
+ maxLength?: number;
36
+ minLength?: number;
37
+ pattern?: string;
38
+ maximum?: number;
39
+ exclusiveMaximum?: boolean;
40
+ minimum?: number;
41
+ exclusiveMinimum?: boolean;
42
+ multipleOf?: number;
43
+ maxItems?: number;
44
+ minItems?: number;
45
+ uniqueItems?: boolean;
46
+ };
47
+ };
@@ -0,0 +1,52 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Knowledge Stack API
6
+ * Knowledge Stack backend API for authentication and knowledge management
7
+ *
8
+ * The version of the OpenAPI document: 0.1.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.SSOInitiateResponsePropertyValidationAttributesMap = void 0;
17
+ exports.instanceOfSSOInitiateResponse = instanceOfSSOInitiateResponse;
18
+ exports.SSOInitiateResponseFromJSON = SSOInitiateResponseFromJSON;
19
+ exports.SSOInitiateResponseFromJSONTyped = SSOInitiateResponseFromJSONTyped;
20
+ exports.SSOInitiateResponseToJSON = SSOInitiateResponseToJSON;
21
+ exports.SSOInitiateResponseToJSONTyped = SSOInitiateResponseToJSONTyped;
22
+ /**
23
+ * Check if a given object implements the SSOInitiateResponse interface.
24
+ */
25
+ function instanceOfSSOInitiateResponse(value) {
26
+ if (!('redirectUrl' in value) || value['redirectUrl'] === undefined)
27
+ return false;
28
+ return true;
29
+ }
30
+ function SSOInitiateResponseFromJSON(json) {
31
+ return SSOInitiateResponseFromJSONTyped(json, false);
32
+ }
33
+ function SSOInitiateResponseFromJSONTyped(json, ignoreDiscriminator) {
34
+ if (json == null) {
35
+ return json;
36
+ }
37
+ return {
38
+ 'redirectUrl': json['redirect_url'],
39
+ };
40
+ }
41
+ function SSOInitiateResponseToJSON(json) {
42
+ return SSOInitiateResponseToJSONTyped(json, false);
43
+ }
44
+ function SSOInitiateResponseToJSONTyped(value, ignoreDiscriminator = false) {
45
+ if (value == null) {
46
+ return value;
47
+ }
48
+ return {
49
+ 'redirect_url': value['redirectUrl'],
50
+ };
51
+ }
52
+ exports.SSOInitiateResponsePropertyValidationAttributesMap = {};
@@ -71,6 +71,7 @@ export * from './PipelineStatus';
71
71
  export * from './Polygon';
72
72
  export * from './PolygonReference';
73
73
  export * from './RootResponse';
74
+ export * from './SSOInitiateResponse';
74
75
  export * from './ScoredChunkResponse';
75
76
  export * from './SectionContentItem';
76
77
  export * from './SectionContentItemOrChunkContentItem';
@@ -89,6 +89,7 @@ __exportStar(require("./PipelineStatus"), exports);
89
89
  __exportStar(require("./Polygon"), exports);
90
90
  __exportStar(require("./PolygonReference"), exports);
91
91
  __exportStar(require("./RootResponse"), exports);
92
+ __exportStar(require("./SSOInitiateResponse"), exports);
92
93
  __exportStar(require("./ScoredChunkResponse"), exports);
93
94
  __exportStar(require("./SectionContentItem"), exports);
94
95
  __exportStar(require("./SectionContentItemOrChunkContentItem"), exports);
package/docs/AuthApi.md CHANGED
@@ -85,7 +85,7 @@ No authorization required
85
85
 
86
86
  ## initiateSso
87
87
 
88
- > any initiateSso(provider, tenantId)
88
+ > SSOInitiateResponse initiateSso(provider, tenantId)
89
89
 
90
90
  Initiate Sso Handler
91
91
 
@@ -133,7 +133,7 @@ example().catch(console.error);
133
133
 
134
134
  ### Return type
135
135
 
136
- **any**
136
+ [**SSOInitiateResponse**](SSOInitiateResponse.md)
137
137
 
138
138
  ### Authorization
139
139
 
@@ -0,0 +1,34 @@
1
+
2
+ # SSOInitiateResponse
3
+
4
+
5
+ ## Properties
6
+
7
+ Name | Type
8
+ ------------ | -------------
9
+ `redirectUrl` | string
10
+
11
+ ## Example
12
+
13
+ ```typescript
14
+ import type { SSOInitiateResponse } from '@knowledge-stack/ksapi'
15
+
16
+ // TODO: Update the object below with actual values
17
+ const example = {
18
+ "redirectUrl": null,
19
+ } satisfies SSOInitiateResponse
20
+
21
+ console.log(example)
22
+
23
+ // Convert the instance to a JSON string
24
+ const exampleJSON: string = JSON.stringify(example)
25
+ console.log(exampleJSON)
26
+
27
+ // Parse the JSON string back to an object
28
+ const exampleParsed = JSON.parse(exampleJSON) as SSOInitiateResponse
29
+ console.log(exampleParsed)
30
+ ```
31
+
32
+ [[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
33
+
34
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@knowledge-stack/ksapi",
3
- "version": "1.27.2",
3
+ "version": "1.28.0",
4
4
  "description": "OpenAPI client for @knowledge-stack/ksapi",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -22,6 +22,7 @@ import type {
22
22
  IdpType,
23
23
  PasswordResetRequest,
24
24
  PasswordResetWithTokenRequest,
25
+ SSOInitiateResponse,
25
26
  SignInRequest,
26
27
  UserResponse,
27
28
  } from '../models/index';
@@ -40,6 +41,8 @@ import {
40
41
  PasswordResetRequestToJSON,
41
42
  PasswordResetWithTokenRequestFromJSON,
42
43
  PasswordResetWithTokenRequestToJSON,
44
+ SSOInitiateResponseFromJSON,
45
+ SSOInitiateResponseToJSON,
43
46
  SignInRequestFromJSON,
44
47
  SignInRequestToJSON,
45
48
  UserResponseFromJSON,
@@ -138,13 +141,13 @@ export interface AuthApiInterface {
138
141
  * @throws {RequiredError}
139
142
  * @memberof AuthApiInterface
140
143
  */
141
- initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>>;
144
+ initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>>;
142
145
 
143
146
  /**
144
147
  * Initiate SSO with the given provider and tenant ID.
145
148
  * Initiate Sso Handler
146
149
  */
147
- initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any>;
150
+ initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse>;
148
151
 
149
152
  /**
150
153
  * Creates request options for oauth2Callback without sending the request
@@ -440,22 +443,18 @@ export class AuthApi extends runtime.BaseAPI implements AuthApiInterface {
440
443
  * Initiate SSO with the given provider and tenant ID.
441
444
  * Initiate Sso Handler
442
445
  */
443
- async initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<any>> {
446
+ async initiateSsoRaw(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SSOInitiateResponse>> {
444
447
  const requestOptions = await this.initiateSsoRequestOpts(requestParameters);
445
448
  const response = await this.request(requestOptions, initOverrides);
446
449
 
447
- if (this.isJsonMime(response.headers.get('content-type'))) {
448
- return new runtime.JSONApiResponse<any>(response);
449
- } else {
450
- return new runtime.TextApiResponse(response) as any;
451
- }
450
+ return new runtime.JSONApiResponse(response, (jsonValue) => SSOInitiateResponseFromJSON(jsonValue));
452
451
  }
453
452
 
454
453
  /**
455
454
  * Initiate SSO with the given provider and tenant ID.
456
455
  * Initiate Sso Handler
457
456
  */
458
- async initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<any> {
457
+ async initiateSso(requestParameters: InitiateSsoRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SSOInitiateResponse> {
459
458
  const response = await this.initiateSsoRaw(requestParameters, initOverrides);
460
459
  return await response.value();
461
460
  }
@@ -0,0 +1,83 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Knowledge Stack API
5
+ * Knowledge Stack backend API for authentication and knowledge management
6
+ *
7
+ * The version of the OpenAPI document: 0.1.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface SSOInitiateResponse
20
+ */
21
+ export interface SSOInitiateResponse {
22
+ /**
23
+ *
24
+ * @type {string}
25
+ * @memberof SSOInitiateResponse
26
+ */
27
+ redirectUrl: string;
28
+ }
29
+
30
+ /**
31
+ * Check if a given object implements the SSOInitiateResponse interface.
32
+ */
33
+ export function instanceOfSSOInitiateResponse(value: object): value is SSOInitiateResponse {
34
+ if (!('redirectUrl' in value) || value['redirectUrl'] === undefined) return false;
35
+ return true;
36
+ }
37
+
38
+ export function SSOInitiateResponseFromJSON(json: any): SSOInitiateResponse {
39
+ return SSOInitiateResponseFromJSONTyped(json, false);
40
+ }
41
+
42
+ export function SSOInitiateResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SSOInitiateResponse {
43
+ if (json == null) {
44
+ return json;
45
+ }
46
+ return {
47
+
48
+ 'redirectUrl': json['redirect_url'],
49
+ };
50
+ }
51
+
52
+ export function SSOInitiateResponseToJSON(json: any): SSOInitiateResponse {
53
+ return SSOInitiateResponseToJSONTyped(json, false);
54
+ }
55
+
56
+ export function SSOInitiateResponseToJSONTyped(value?: SSOInitiateResponse | null, ignoreDiscriminator: boolean = false): any {
57
+ if (value == null) {
58
+ return value;
59
+ }
60
+
61
+ return {
62
+
63
+ 'redirect_url': value['redirectUrl'],
64
+ };
65
+ }
66
+
67
+ export const SSOInitiateResponsePropertyValidationAttributesMap: {
68
+ [property: string]: {
69
+ maxLength?: number,
70
+ minLength?: number,
71
+ pattern?: string,
72
+ maximum?: number,
73
+ exclusiveMaximum?: boolean,
74
+ minimum?: number,
75
+ exclusiveMinimum?: boolean,
76
+ multipleOf?: number,
77
+ maxItems?: number,
78
+ minItems?: number,
79
+ uniqueItems?: boolean
80
+ }
81
+ } = {
82
+ }
83
+
@@ -73,6 +73,7 @@ export * from './PipelineStatus';
73
73
  export * from './Polygon';
74
74
  export * from './PolygonReference';
75
75
  export * from './RootResponse';
76
+ export * from './SSOInitiateResponse';
76
77
  export * from './ScoredChunkResponse';
77
78
  export * from './SectionContentItem';
78
79
  export * from './SectionContentItemOrChunkContentItem';