Skip to content

Commit 2f928fb

Browse files
updating apis based on postman response
1 parent b2ccbe1 commit 2f928fb

12 files changed

+990
-614
lines changed

api/defaultApi.ts

Lines changed: 34 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ import { VerifyFactorSaml200Response } from "../model/verifyFactorSaml200Respons
8686
import { VerifyFactorSamlRequest } from "../model/verifyFactorSamlRequest";
8787
import { VerifyFactorVoice200ResponseInner } from "../model/verifyFactorVoice200ResponseInner";
8888

89-
9089
import {
9190
ObjectSerializer,
9291
Authentication,
@@ -95,7 +94,8 @@ import {
9594
} from "../model/models";
9695

9796
import { HttpError, RequestFile } from "./apis";
98-
97+
import { RoleAppResponse } from "../model/RoleAppResponse";
98+
import { listUserResponse } from "../model/listUserResponse";
9999

100100
let defaultBasePath = "https://onelogininc.onelogin.com";
101101

@@ -5470,7 +5470,7 @@ export class DefaultApi {
54705470
cursor?: string,
54715471
assigned?: boolean,
54725472
options: { headers: { [name: string]: string } } = { headers: {} }
5473-
): Promise<{ response: http.IncomingMessage; body: Array<Schema> }> {
5473+
): Promise<{ response: http.IncomingMessage; body: Array<RoleAppResponse> }> {
54745474
const localVarPath =
54755475
this.basePath +
54765476
"/api/2/roles/{role_id}/apps".replace(
@@ -5572,7 +5572,7 @@ export class DefaultApi {
55725572
}
55735573
return new Promise<{
55745574
response: http.IncomingMessage;
5575-
body: Array<Schema>;
5575+
body: Array<RoleAppResponse>;
55765576
}>((resolve, reject) => {
55775577
localVarRequest(localVarRequestOptions, (error, response, body) => {
55785578
if (error) {
@@ -5583,7 +5583,10 @@ export class DefaultApi {
55835583
response.statusCode >= 200 &&
55845584
response.statusCode <= 299
55855585
) {
5586-
body = ObjectSerializer.deserialize(body, "Array<Schema>");
5586+
body = ObjectSerializer.deserialize(
5587+
body,
5588+
"Array<RoleAppResponse>"
5589+
);
55875590
resolve({ response: response, body: body });
55885591
} else {
55895592
reject(new HttpError(response, body, response.statusCode));
@@ -8810,7 +8813,10 @@ export class DefaultApi {
88108813
customAttributesAttributeName?: string,
88118814
fields?: string,
88128815
options: { headers: { [name: string]: string } } = { headers: {} }
8813-
): Promise<{ response: http.IncomingMessage; body: Array<User> }> {
8816+
): Promise<{
8817+
response: http.IncomingMessage;
8818+
body: Array<listUserResponse>;
8819+
}> {
88148820
const localVarPath = this.basePath + "/api/2/users";
88158821
let localVarQueryParameters: any = {};
88168822
let localVarHeaderParams: any = (<any>Object).assign(
@@ -9008,26 +9014,30 @@ export class DefaultApi {
90089014
localVarRequestOptions.form = localVarFormParams;
90099015
}
90109016
}
9011-
return new Promise<{ response: http.IncomingMessage; body: Array<User> }>(
9012-
(resolve, reject) => {
9013-
localVarRequest(localVarRequestOptions, (error, response, body) => {
9014-
if (error) {
9015-
reject(error);
9017+
return new Promise<{
9018+
response: http.IncomingMessage;
9019+
body: Array<listUserResponse>;
9020+
}>((resolve, reject) => {
9021+
localVarRequest(localVarRequestOptions, (error, response, body) => {
9022+
if (error) {
9023+
reject(error);
9024+
} else {
9025+
if (
9026+
response.statusCode &&
9027+
response.statusCode >= 200 &&
9028+
response.statusCode <= 299
9029+
) {
9030+
body = ObjectSerializer.deserialize(
9031+
body,
9032+
"Array<listUserResponse>"
9033+
);
9034+
resolve({ response: response, body: body });
90169035
} else {
9017-
if (
9018-
response.statusCode &&
9019-
response.statusCode >= 200 &&
9020-
response.statusCode <= 299
9021-
) {
9022-
body = ObjectSerializer.deserialize(body, "Array<User>");
9023-
resolve({ response: response, body: body });
9024-
} else {
9025-
reject(new HttpError(response, body, response.statusCode));
9026-
}
9036+
reject(new HttpError(response, body, response.statusCode));
90279037
}
9028-
});
9029-
}
9030-
);
9038+
}
9039+
});
9040+
});
90319041
});
90329042
}
90339043
/**

model/RoleAppResponse.ts

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
/**
2+
* OneLogin API
3+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4+
*
5+
* The version of the OpenAPI document: 3.0.0-alpha.1
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+
export class RoleAppResponse {
14+
/**
15+
* Apps unique ID in OneLogin.
16+
*/
17+
"id"?: number;
18+
/**
19+
* App name.
20+
*/
21+
"name"?: string;
22+
/**
23+
* A link to the apps icon url.
24+
*/
25+
"iconUrl"?: string;
26+
27+
static discriminator: string | undefined = undefined;
28+
29+
static attributeTypeMap: Array<{
30+
name: string;
31+
baseName: string;
32+
type: string;
33+
}> = [
34+
{
35+
name: "id",
36+
baseName: "id",
37+
type: "number",
38+
},
39+
{
40+
name: "name",
41+
baseName: "name",
42+
type: "string",
43+
},
44+
{
45+
name: "iconUrl",
46+
baseName: "icon_url",
47+
type: "string",
48+
},
49+
];
50+
51+
static getAttributeTypeMap() {
52+
return RoleAppResponse.attributeTypeMap;
53+
}
54+
}

model/getAuthorizationServer200Response.ts

Lines changed: 43 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -3,48 +3,58 @@
33
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
44
*
55
* The version of the OpenAPI document: 3.0.0-alpha.1
6-
*
6+
*
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
99
* https://openapi-generator.tech
1010
* Do not edit the class manually.
1111
*/
1212

13-
import { RequestFile } from './models';
14-
import { AuthServerConfiguration } from './authServerConfiguration';
13+
import { AuthServerConfiguration } from "./authServerConfiguration";
14+
import { RequestFile } from "./models";
1515

1616
export class GetAuthorizationServer200Response {
17-
'configuration'?: AuthServerConfiguration;
18-
'id'?: number;
19-
'description'?: string;
20-
'name'?: string;
17+
"configuration"?: AuthServerConfiguration;
18+
"id"?: number;
19+
"description"?: string;
20+
"name"?: string;
21+
"onelogin"?: boolean;
2122

22-
static discriminator: string | undefined = undefined;
23+
static discriminator: string | undefined = undefined;
2324

24-
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
25-
{
26-
"name": "configuration",
27-
"baseName": "configuration",
28-
"type": "AuthServerConfiguration"
29-
},
30-
{
31-
"name": "id",
32-
"baseName": "id",
33-
"type": "number"
34-
},
35-
{
36-
"name": "description",
37-
"baseName": "description",
38-
"type": "string"
39-
},
40-
{
41-
"name": "name",
42-
"baseName": "name",
43-
"type": "string"
44-
} ];
25+
static attributeTypeMap: Array<{
26+
name: string;
27+
baseName: string;
28+
type: string;
29+
}> = [
30+
{
31+
name: "configuration",
32+
baseName: "configuration",
33+
type: "AuthServerConfiguration",
34+
},
35+
{
36+
name: "id",
37+
baseName: "id",
38+
type: "number",
39+
},
40+
{
41+
name: "description",
42+
baseName: "description",
43+
type: "string",
44+
},
45+
{
46+
name: "name",
47+
baseName: "name",
48+
type: "string",
49+
},
50+
{
51+
name: "onelogin",
52+
baseName: "onelogin",
53+
type: "boolean",
54+
},
55+
];
4556

46-
static getAttributeTypeMap() {
47-
return GetAuthorizationServer200Response.attributeTypeMap;
48-
}
57+
static getAttributeTypeMap() {
58+
return GetAuthorizationServer200Response.attributeTypeMap;
59+
}
4960
}
50-

model/getClientApps200ResponseInnerScopesInner.ts

Lines changed: 36 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,41 +3,51 @@
33
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
44
*
55
* The version of the OpenAPI document: 3.0.0-alpha.1
6-
*
6+
*
77
*
88
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
99
* https://openapi-generator.tech
1010
* Do not edit the class manually.
1111
*/
1212

13-
import { RequestFile } from './models';
13+
import { RequestFile } from "./models";
1414

1515
export class GetClientApps200ResponseInnerScopesInner {
16-
'description'?: string;
17-
'value'?: string;
18-
'id'?: number;
16+
"description"?: string;
17+
"value"?: string;
18+
"id"?: number;
19+
"inherited"?: boolean;
1920

20-
static discriminator: string | undefined = undefined;
21+
static discriminator: string | undefined = undefined;
2122

22-
static attributeTypeMap: Array<{name: string, baseName: string, type: string}> = [
23-
{
24-
"name": "description",
25-
"baseName": "description",
26-
"type": "string"
27-
},
28-
{
29-
"name": "value",
30-
"baseName": "value",
31-
"type": "string"
32-
},
33-
{
34-
"name": "id",
35-
"baseName": "id",
36-
"type": "number"
37-
} ];
23+
static attributeTypeMap: Array<{
24+
name: string;
25+
baseName: string;
26+
type: string;
27+
}> = [
28+
{
29+
name: "description",
30+
baseName: "description",
31+
type: "string",
32+
},
33+
{
34+
name: "value",
35+
baseName: "value",
36+
type: "string",
37+
},
38+
{
39+
name: "id",
40+
baseName: "id",
41+
type: "number",
42+
},
43+
{
44+
name: "inherited",
45+
baseName: "inherited",
46+
type: "boolean",
47+
},
48+
];
3849

39-
static getAttributeTypeMap() {
40-
return GetClientApps200ResponseInnerScopesInner.attributeTypeMap;
41-
}
50+
static getAttributeTypeMap() {
51+
return GetClientApps200ResponseInnerScopesInner.attributeTypeMap;
52+
}
4253
}
43-

0 commit comments

Comments
 (0)