@sonatype/nexus-repo-api-client 3.96.0 → 3.96.1

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.
@@ -0,0 +1,134 @@
1
+ /**
2
+ * Sonatype Nexus Repository Manager
3
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
4
+ *
5
+ * The version of the OpenAPI document: 3.96.0-09
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 OAuth2OidcConfigurationXO
16
+ */
17
+ export interface OAuth2OidcConfigurationXO {
18
+ /**
19
+ *
20
+ * @type {{ [key: string]: string; }}
21
+ * @memberof OAuth2OidcConfigurationXO
22
+ */
23
+ authorizationCustomParams?: {
24
+ [key: string]: string;
25
+ };
26
+ /**
27
+ *
28
+ * @type {string}
29
+ * @memberof OAuth2OidcConfigurationXO
30
+ */
31
+ clientId?: string;
32
+ /**
33
+ *
34
+ * @type {string}
35
+ * @memberof OAuth2OidcConfigurationXO
36
+ */
37
+ clientSecret?: string;
38
+ /**
39
+ *
40
+ * @type {string}
41
+ * @memberof OAuth2OidcConfigurationXO
42
+ */
43
+ emailClaim?: string;
44
+ /**
45
+ *
46
+ * @type {{ [key: string]: string; }}
47
+ * @memberof OAuth2OidcConfigurationXO
48
+ */
49
+ exactMatchClaims?: {
50
+ [key: string]: string;
51
+ };
52
+ /**
53
+ *
54
+ * @type {string}
55
+ * @memberof OAuth2OidcConfigurationXO
56
+ */
57
+ firstNameClaim?: string;
58
+ /**
59
+ *
60
+ * @type {string}
61
+ * @memberof OAuth2OidcConfigurationXO
62
+ */
63
+ groupsClaim?: string;
64
+ /**
65
+ *
66
+ * @type {string}
67
+ * @memberof OAuth2OidcConfigurationXO
68
+ */
69
+ idpAuthorizationUrl?: string;
70
+ /**
71
+ *
72
+ * @type {string}
73
+ * @memberof OAuth2OidcConfigurationXO
74
+ */
75
+ idpJwks?: string;
76
+ /**
77
+ *
78
+ * @type {string}
79
+ * @memberof OAuth2OidcConfigurationXO
80
+ */
81
+ idpJwksUrl?: string;
82
+ /**
83
+ *
84
+ * @type {string}
85
+ * @memberof OAuth2OidcConfigurationXO
86
+ */
87
+ idpJwsAlgorithm: string;
88
+ /**
89
+ *
90
+ * @type {string}
91
+ * @memberof OAuth2OidcConfigurationXO
92
+ */
93
+ idpLogoutUrl?: string;
94
+ /**
95
+ *
96
+ * @type {string}
97
+ * @memberof OAuth2OidcConfigurationXO
98
+ */
99
+ idpTokenUrl?: string;
100
+ /**
101
+ *
102
+ * @type {string}
103
+ * @memberof OAuth2OidcConfigurationXO
104
+ */
105
+ lastNameClaim?: string;
106
+ /**
107
+ *
108
+ * @type {{ [key: string]: string; }}
109
+ * @memberof OAuth2OidcConfigurationXO
110
+ */
111
+ tokenRequestCustomParams?: {
112
+ [key: string]: string;
113
+ };
114
+ /**
115
+ *
116
+ * @type {boolean}
117
+ * @memberof OAuth2OidcConfigurationXO
118
+ */
119
+ useTrustStore?: boolean;
120
+ /**
121
+ *
122
+ * @type {string}
123
+ * @memberof OAuth2OidcConfigurationXO
124
+ */
125
+ usernameClaim: string;
126
+ }
127
+ /**
128
+ * Check if a given object implements the OAuth2OidcConfigurationXO interface.
129
+ */
130
+ export declare function instanceOfOAuth2OidcConfigurationXO(value: object): value is OAuth2OidcConfigurationXO;
131
+ export declare function OAuth2OidcConfigurationXOFromJSON(json: any): OAuth2OidcConfigurationXO;
132
+ export declare function OAuth2OidcConfigurationXOFromJSONTyped(json: any, ignoreDiscriminator: boolean): OAuth2OidcConfigurationXO;
133
+ export declare function OAuth2OidcConfigurationXOToJSON(json: any): OAuth2OidcConfigurationXO;
134
+ export declare function OAuth2OidcConfigurationXOToJSONTyped(value?: OAuth2OidcConfigurationXO | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,77 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sonatype Nexus Repository Manager
5
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
6
+ *
7
+ * The version of the OpenAPI document: 3.96.0-09
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 OAuth2OidcConfigurationXO interface.
16
+ */
17
+ export function instanceOfOAuth2OidcConfigurationXO(value) {
18
+ if (!('idpJwsAlgorithm' in value) || value['idpJwsAlgorithm'] === undefined)
19
+ return false;
20
+ if (!('usernameClaim' in value) || value['usernameClaim'] === undefined)
21
+ return false;
22
+ return true;
23
+ }
24
+ export function OAuth2OidcConfigurationXOFromJSON(json) {
25
+ return OAuth2OidcConfigurationXOFromJSONTyped(json, false);
26
+ }
27
+ export function OAuth2OidcConfigurationXOFromJSONTyped(json, ignoreDiscriminator) {
28
+ if (json == null) {
29
+ return json;
30
+ }
31
+ return {
32
+ 'authorizationCustomParams': json['authorizationCustomParams'] == null ? undefined : json['authorizationCustomParams'],
33
+ 'clientId': json['clientId'] == null ? undefined : json['clientId'],
34
+ 'clientSecret': json['clientSecret'] == null ? undefined : json['clientSecret'],
35
+ 'emailClaim': json['emailClaim'] == null ? undefined : json['emailClaim'],
36
+ 'exactMatchClaims': json['exactMatchClaims'] == null ? undefined : json['exactMatchClaims'],
37
+ 'firstNameClaim': json['firstNameClaim'] == null ? undefined : json['firstNameClaim'],
38
+ 'groupsClaim': json['groupsClaim'] == null ? undefined : json['groupsClaim'],
39
+ 'idpAuthorizationUrl': json['idpAuthorizationUrl'] == null ? undefined : json['idpAuthorizationUrl'],
40
+ 'idpJwks': json['idpJwks'] == null ? undefined : json['idpJwks'],
41
+ 'idpJwksUrl': json['idpJwksUrl'] == null ? undefined : json['idpJwksUrl'],
42
+ 'idpJwsAlgorithm': json['idpJwsAlgorithm'],
43
+ 'idpLogoutUrl': json['idpLogoutUrl'] == null ? undefined : json['idpLogoutUrl'],
44
+ 'idpTokenUrl': json['idpTokenUrl'] == null ? undefined : json['idpTokenUrl'],
45
+ 'lastNameClaim': json['lastNameClaim'] == null ? undefined : json['lastNameClaim'],
46
+ 'tokenRequestCustomParams': json['tokenRequestCustomParams'] == null ? undefined : json['tokenRequestCustomParams'],
47
+ 'useTrustStore': json['useTrustStore'] == null ? undefined : json['useTrustStore'],
48
+ 'usernameClaim': json['usernameClaim'],
49
+ };
50
+ }
51
+ export function OAuth2OidcConfigurationXOToJSON(json) {
52
+ return OAuth2OidcConfigurationXOToJSONTyped(json, false);
53
+ }
54
+ export function OAuth2OidcConfigurationXOToJSONTyped(value, ignoreDiscriminator = false) {
55
+ if (value == null) {
56
+ return value;
57
+ }
58
+ return {
59
+ 'authorizationCustomParams': value['authorizationCustomParams'],
60
+ 'clientId': value['clientId'],
61
+ 'clientSecret': value['clientSecret'],
62
+ 'emailClaim': value['emailClaim'],
63
+ 'exactMatchClaims': value['exactMatchClaims'],
64
+ 'firstNameClaim': value['firstNameClaim'],
65
+ 'groupsClaim': value['groupsClaim'],
66
+ 'idpAuthorizationUrl': value['idpAuthorizationUrl'],
67
+ 'idpJwks': value['idpJwks'],
68
+ 'idpJwksUrl': value['idpJwksUrl'],
69
+ 'idpJwsAlgorithm': value['idpJwsAlgorithm'],
70
+ 'idpLogoutUrl': value['idpLogoutUrl'],
71
+ 'idpTokenUrl': value['idpTokenUrl'],
72
+ 'lastNameClaim': value['lastNameClaim'],
73
+ 'tokenRequestCustomParams': value['tokenRequestCustomParams'],
74
+ 'useTrustStore': value['useTrustStore'],
75
+ 'usernameClaim': value['usernameClaim'],
76
+ };
77
+ }
@@ -201,6 +201,7 @@ export * from './NugetHostedApiRepository';
201
201
  export * from './NugetHostedRepositoryApiRequest';
202
202
  export * from './NugetProxyApiRepository';
203
203
  export * from './NugetProxyRepositoryApiRequest';
204
+ export * from './OAuth2OidcConfigurationXO';
204
205
  export * from './OciAttributes';
205
206
  export * from './OciCosignConfiguration';
206
207
  export * from './OciGroupApiRepository';
@@ -203,6 +203,7 @@ export * from './NugetHostedApiRepository';
203
203
  export * from './NugetHostedRepositoryApiRequest';
204
204
  export * from './NugetProxyApiRepository';
205
205
  export * from './NugetProxyRepositoryApiRequest';
206
+ export * from './OAuth2OidcConfigurationXO';
206
207
  export * from './OciAttributes';
207
208
  export * from './OciCosignConfiguration';
208
209
  export * from './OciGroupApiRepository';
@@ -0,0 +1,134 @@
1
+ /**
2
+ * Sonatype Nexus Repository Manager
3
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
4
+ *
5
+ * The version of the OpenAPI document: 3.96.0-09
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 OAuth2OidcConfigurationXO
16
+ */
17
+ export interface OAuth2OidcConfigurationXO {
18
+ /**
19
+ *
20
+ * @type {{ [key: string]: string; }}
21
+ * @memberof OAuth2OidcConfigurationXO
22
+ */
23
+ authorizationCustomParams?: {
24
+ [key: string]: string;
25
+ };
26
+ /**
27
+ *
28
+ * @type {string}
29
+ * @memberof OAuth2OidcConfigurationXO
30
+ */
31
+ clientId?: string;
32
+ /**
33
+ *
34
+ * @type {string}
35
+ * @memberof OAuth2OidcConfigurationXO
36
+ */
37
+ clientSecret?: string;
38
+ /**
39
+ *
40
+ * @type {string}
41
+ * @memberof OAuth2OidcConfigurationXO
42
+ */
43
+ emailClaim?: string;
44
+ /**
45
+ *
46
+ * @type {{ [key: string]: string; }}
47
+ * @memberof OAuth2OidcConfigurationXO
48
+ */
49
+ exactMatchClaims?: {
50
+ [key: string]: string;
51
+ };
52
+ /**
53
+ *
54
+ * @type {string}
55
+ * @memberof OAuth2OidcConfigurationXO
56
+ */
57
+ firstNameClaim?: string;
58
+ /**
59
+ *
60
+ * @type {string}
61
+ * @memberof OAuth2OidcConfigurationXO
62
+ */
63
+ groupsClaim?: string;
64
+ /**
65
+ *
66
+ * @type {string}
67
+ * @memberof OAuth2OidcConfigurationXO
68
+ */
69
+ idpAuthorizationUrl?: string;
70
+ /**
71
+ *
72
+ * @type {string}
73
+ * @memberof OAuth2OidcConfigurationXO
74
+ */
75
+ idpJwks?: string;
76
+ /**
77
+ *
78
+ * @type {string}
79
+ * @memberof OAuth2OidcConfigurationXO
80
+ */
81
+ idpJwksUrl?: string;
82
+ /**
83
+ *
84
+ * @type {string}
85
+ * @memberof OAuth2OidcConfigurationXO
86
+ */
87
+ idpJwsAlgorithm: string;
88
+ /**
89
+ *
90
+ * @type {string}
91
+ * @memberof OAuth2OidcConfigurationXO
92
+ */
93
+ idpLogoutUrl?: string;
94
+ /**
95
+ *
96
+ * @type {string}
97
+ * @memberof OAuth2OidcConfigurationXO
98
+ */
99
+ idpTokenUrl?: string;
100
+ /**
101
+ *
102
+ * @type {string}
103
+ * @memberof OAuth2OidcConfigurationXO
104
+ */
105
+ lastNameClaim?: string;
106
+ /**
107
+ *
108
+ * @type {{ [key: string]: string; }}
109
+ * @memberof OAuth2OidcConfigurationXO
110
+ */
111
+ tokenRequestCustomParams?: {
112
+ [key: string]: string;
113
+ };
114
+ /**
115
+ *
116
+ * @type {boolean}
117
+ * @memberof OAuth2OidcConfigurationXO
118
+ */
119
+ useTrustStore?: boolean;
120
+ /**
121
+ *
122
+ * @type {string}
123
+ * @memberof OAuth2OidcConfigurationXO
124
+ */
125
+ usernameClaim: string;
126
+ }
127
+ /**
128
+ * Check if a given object implements the OAuth2OidcConfigurationXO interface.
129
+ */
130
+ export declare function instanceOfOAuth2OidcConfigurationXO(value: object): value is OAuth2OidcConfigurationXO;
131
+ export declare function OAuth2OidcConfigurationXOFromJSON(json: any): OAuth2OidcConfigurationXO;
132
+ export declare function OAuth2OidcConfigurationXOFromJSONTyped(json: any, ignoreDiscriminator: boolean): OAuth2OidcConfigurationXO;
133
+ export declare function OAuth2OidcConfigurationXOToJSON(json: any): OAuth2OidcConfigurationXO;
134
+ export declare function OAuth2OidcConfigurationXOToJSONTyped(value?: OAuth2OidcConfigurationXO | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,84 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Sonatype Nexus Repository Manager
6
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
7
+ *
8
+ * The version of the OpenAPI document: 3.96.0-09
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.instanceOfOAuth2OidcConfigurationXO = instanceOfOAuth2OidcConfigurationXO;
17
+ exports.OAuth2OidcConfigurationXOFromJSON = OAuth2OidcConfigurationXOFromJSON;
18
+ exports.OAuth2OidcConfigurationXOFromJSONTyped = OAuth2OidcConfigurationXOFromJSONTyped;
19
+ exports.OAuth2OidcConfigurationXOToJSON = OAuth2OidcConfigurationXOToJSON;
20
+ exports.OAuth2OidcConfigurationXOToJSONTyped = OAuth2OidcConfigurationXOToJSONTyped;
21
+ /**
22
+ * Check if a given object implements the OAuth2OidcConfigurationXO interface.
23
+ */
24
+ function instanceOfOAuth2OidcConfigurationXO(value) {
25
+ if (!('idpJwsAlgorithm' in value) || value['idpJwsAlgorithm'] === undefined)
26
+ return false;
27
+ if (!('usernameClaim' in value) || value['usernameClaim'] === undefined)
28
+ return false;
29
+ return true;
30
+ }
31
+ function OAuth2OidcConfigurationXOFromJSON(json) {
32
+ return OAuth2OidcConfigurationXOFromJSONTyped(json, false);
33
+ }
34
+ function OAuth2OidcConfigurationXOFromJSONTyped(json, ignoreDiscriminator) {
35
+ if (json == null) {
36
+ return json;
37
+ }
38
+ return {
39
+ 'authorizationCustomParams': json['authorizationCustomParams'] == null ? undefined : json['authorizationCustomParams'],
40
+ 'clientId': json['clientId'] == null ? undefined : json['clientId'],
41
+ 'clientSecret': json['clientSecret'] == null ? undefined : json['clientSecret'],
42
+ 'emailClaim': json['emailClaim'] == null ? undefined : json['emailClaim'],
43
+ 'exactMatchClaims': json['exactMatchClaims'] == null ? undefined : json['exactMatchClaims'],
44
+ 'firstNameClaim': json['firstNameClaim'] == null ? undefined : json['firstNameClaim'],
45
+ 'groupsClaim': json['groupsClaim'] == null ? undefined : json['groupsClaim'],
46
+ 'idpAuthorizationUrl': json['idpAuthorizationUrl'] == null ? undefined : json['idpAuthorizationUrl'],
47
+ 'idpJwks': json['idpJwks'] == null ? undefined : json['idpJwks'],
48
+ 'idpJwksUrl': json['idpJwksUrl'] == null ? undefined : json['idpJwksUrl'],
49
+ 'idpJwsAlgorithm': json['idpJwsAlgorithm'],
50
+ 'idpLogoutUrl': json['idpLogoutUrl'] == null ? undefined : json['idpLogoutUrl'],
51
+ 'idpTokenUrl': json['idpTokenUrl'] == null ? undefined : json['idpTokenUrl'],
52
+ 'lastNameClaim': json['lastNameClaim'] == null ? undefined : json['lastNameClaim'],
53
+ 'tokenRequestCustomParams': json['tokenRequestCustomParams'] == null ? undefined : json['tokenRequestCustomParams'],
54
+ 'useTrustStore': json['useTrustStore'] == null ? undefined : json['useTrustStore'],
55
+ 'usernameClaim': json['usernameClaim'],
56
+ };
57
+ }
58
+ function OAuth2OidcConfigurationXOToJSON(json) {
59
+ return OAuth2OidcConfigurationXOToJSONTyped(json, false);
60
+ }
61
+ function OAuth2OidcConfigurationXOToJSONTyped(value, ignoreDiscriminator = false) {
62
+ if (value == null) {
63
+ return value;
64
+ }
65
+ return {
66
+ 'authorizationCustomParams': value['authorizationCustomParams'],
67
+ 'clientId': value['clientId'],
68
+ 'clientSecret': value['clientSecret'],
69
+ 'emailClaim': value['emailClaim'],
70
+ 'exactMatchClaims': value['exactMatchClaims'],
71
+ 'firstNameClaim': value['firstNameClaim'],
72
+ 'groupsClaim': value['groupsClaim'],
73
+ 'idpAuthorizationUrl': value['idpAuthorizationUrl'],
74
+ 'idpJwks': value['idpJwks'],
75
+ 'idpJwksUrl': value['idpJwksUrl'],
76
+ 'idpJwsAlgorithm': value['idpJwsAlgorithm'],
77
+ 'idpLogoutUrl': value['idpLogoutUrl'],
78
+ 'idpTokenUrl': value['idpTokenUrl'],
79
+ 'lastNameClaim': value['lastNameClaim'],
80
+ 'tokenRequestCustomParams': value['tokenRequestCustomParams'],
81
+ 'useTrustStore': value['useTrustStore'],
82
+ 'usernameClaim': value['usernameClaim'],
83
+ };
84
+ }
@@ -201,6 +201,7 @@ export * from './NugetHostedApiRepository';
201
201
  export * from './NugetHostedRepositoryApiRequest';
202
202
  export * from './NugetProxyApiRepository';
203
203
  export * from './NugetProxyRepositoryApiRequest';
204
+ export * from './OAuth2OidcConfigurationXO';
204
205
  export * from './OciAttributes';
205
206
  export * from './OciCosignConfiguration';
206
207
  export * from './OciGroupApiRepository';
@@ -219,6 +219,7 @@ __exportStar(require("./NugetHostedApiRepository"), exports);
219
219
  __exportStar(require("./NugetHostedRepositoryApiRequest"), exports);
220
220
  __exportStar(require("./NugetProxyApiRepository"), exports);
221
221
  __exportStar(require("./NugetProxyRepositoryApiRequest"), exports);
222
+ __exportStar(require("./OAuth2OidcConfigurationXO"), exports);
222
223
  __exportStar(require("./OciAttributes"), exports);
223
224
  __exportStar(require("./OciCosignConfiguration"), exports);
224
225
  __exportStar(require("./OciGroupApiRepository"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sonatype/nexus-repo-api-client",
3
- "version": "3.96.0",
3
+ "version": "3.96.1",
4
4
  "description": "OpenAPI client for @sonatype/nexus-repo-api-client",
5
5
  "author": "OpenAPI-Generator",
6
6
  "repository": {
@@ -0,0 +1,54 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sonatype Nexus Repository Manager
5
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
6
+ *
7
+ * The version of the OpenAPI document: 3.96.0-09
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
+
16
+ import * as runtime from '../runtime';
17
+
18
+ /**
19
+ *
20
+ */
21
+ export class SecurityManagementJWTApi extends runtime.BaseAPI {
22
+
23
+ /**
24
+ * Reset JWT secret (note that session will be expired for the all logged-in users)
25
+ */
26
+ async updateSecurityJwtRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
27
+ const queryParameters: any = {};
28
+
29
+ const headerParameters: runtime.HTTPHeaders = {};
30
+
31
+ if (this.configuration && (this.configuration.username !== undefined || this.configuration.password !== undefined)) {
32
+ headerParameters["Authorization"] = "Basic " + btoa(this.configuration.username + ":" + this.configuration.password);
33
+ }
34
+
35
+ let urlPath = `/v1/security/jwt`;
36
+
37
+ const response = await this.request({
38
+ path: urlPath,
39
+ method: 'PUT',
40
+ headers: headerParameters,
41
+ query: queryParameters,
42
+ }, initOverrides);
43
+
44
+ return new runtime.VoidApiResponse(response);
45
+ }
46
+
47
+ /**
48
+ * Reset JWT secret (note that session will be expired for the all logged-in users)
49
+ */
50
+ async updateSecurityJwt(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
51
+ await this.updateSecurityJwtRaw(initOverrides);
52
+ }
53
+
54
+ }
@@ -0,0 +1,138 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sonatype Nexus Repository Manager
5
+ * This documents the available APIs into [Sonatype Nexus Repository Manager](https://www.sonatype.com/products/sonatype-nexus-repository) as of version 3.96.0-09.
6
+ *
7
+ * The version of the OpenAPI document: 3.96.0-09
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
+
16
+ import * as runtime from '../runtime';
17
+ import type {
18
+ OAuth2OidcConfigurationXO,
19
+ } from '../models/index';
20
+ import {
21
+ OAuth2OidcConfigurationXOFromJSON,
22
+ OAuth2OidcConfigurationXOToJSON,
23
+ } from '../models/index';
24
+
25
+ export interface SecurityOAuth2OIDCApiUpdateSecurityOauth2Request {
26
+ oAuth2OidcConfigurationXO: OAuth2OidcConfigurationXO;
27
+ }
28
+
29
+ /**
30
+ *
31
+ */
32
+ export class SecurityOAuth2OIDCApi extends runtime.BaseAPI {
33
+
34
+ /**
35
+ * Remove OAuth2/OIDC configuration
36
+ */
37
+ async deleteSecurityOauth2Raw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
38
+ const queryParameters: any = {};
39
+
40
+ const headerParameters: runtime.HTTPHeaders = {};
41
+
42
+ if (this.configuration && (this.configuration.username !== undefined || this.configuration.password !== undefined)) {
43
+ headerParameters["Authorization"] = "Basic " + btoa(this.configuration.username + ":" + this.configuration.password);
44
+ }
45
+
46
+ let urlPath = `/v1/security/oauth2`;
47
+
48
+ const response = await this.request({
49
+ path: urlPath,
50
+ method: 'DELETE',
51
+ headers: headerParameters,
52
+ query: queryParameters,
53
+ }, initOverrides);
54
+
55
+ return new runtime.VoidApiResponse(response);
56
+ }
57
+
58
+ /**
59
+ * Remove OAuth2/OIDC configuration
60
+ */
61
+ async deleteSecurityOauth2(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
62
+ await this.deleteSecurityOauth2Raw(initOverrides);
63
+ }
64
+
65
+ /**
66
+ * Retrieve the current OAuth2/OIDC configuration
67
+ */
68
+ async listSecurityOauth2Raw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<OAuth2OidcConfigurationXO>> {
69
+ const queryParameters: any = {};
70
+
71
+ const headerParameters: runtime.HTTPHeaders = {};
72
+
73
+ if (this.configuration && (this.configuration.username !== undefined || this.configuration.password !== undefined)) {
74
+ headerParameters["Authorization"] = "Basic " + btoa(this.configuration.username + ":" + this.configuration.password);
75
+ }
76
+
77
+ let urlPath = `/v1/security/oauth2`;
78
+
79
+ const response = await this.request({
80
+ path: urlPath,
81
+ method: 'GET',
82
+ headers: headerParameters,
83
+ query: queryParameters,
84
+ }, initOverrides);
85
+
86
+ return new runtime.JSONApiResponse(response, (jsonValue) => OAuth2OidcConfigurationXOFromJSON(jsonValue));
87
+ }
88
+
89
+ /**
90
+ * Retrieve the current OAuth2/OIDC configuration
91
+ */
92
+ async listSecurityOauth2(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<OAuth2OidcConfigurationXO> {
93
+ const response = await this.listSecurityOauth2Raw(initOverrides);
94
+ return await response.value();
95
+ }
96
+
97
+ /**
98
+ * Create or update OAuth2/OIDC configuration
99
+ */
100
+ async updateSecurityOauth2Raw(requestParameters: SecurityOAuth2OIDCApiUpdateSecurityOauth2Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>> {
101
+ if (requestParameters['oAuth2OidcConfigurationXO'] == null) {
102
+ throw new runtime.RequiredError(
103
+ 'oAuth2OidcConfigurationXO',
104
+ 'Required parameter "oAuth2OidcConfigurationXO" was null or undefined when calling updateSecurityOauth2().'
105
+ );
106
+ }
107
+
108
+ const queryParameters: any = {};
109
+
110
+ const headerParameters: runtime.HTTPHeaders = {};
111
+
112
+ headerParameters['Content-Type'] = 'application/json';
113
+
114
+ if (this.configuration && (this.configuration.username !== undefined || this.configuration.password !== undefined)) {
115
+ headerParameters["Authorization"] = "Basic " + btoa(this.configuration.username + ":" + this.configuration.password);
116
+ }
117
+
118
+ let urlPath = `/v1/security/oauth2`;
119
+
120
+ const response = await this.request({
121
+ path: urlPath,
122
+ method: 'PUT',
123
+ headers: headerParameters,
124
+ query: queryParameters,
125
+ body: OAuth2OidcConfigurationXOToJSON(requestParameters['oAuth2OidcConfigurationXO']),
126
+ }, initOverrides);
127
+
128
+ return new runtime.VoidApiResponse(response);
129
+ }
130
+
131
+ /**
132
+ * Create or update OAuth2/OIDC configuration
133
+ */
134
+ async updateSecurityOauth2(requestParameters: SecurityOAuth2OIDCApiUpdateSecurityOauth2Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void> {
135
+ await this.updateSecurityOauth2Raw(requestParameters, initOverrides);
136
+ }
137
+
138
+ }
package/src/apis/index.ts CHANGED
@@ -33,6 +33,7 @@ export * from './SecurityManagementApi';
33
33
  export * from './SecurityManagementAPIAccessApi';
34
34
  export * from './SecurityManagementAnonymousAccessApi';
35
35
  export * from './SecurityManagementApiKeysPrincipalsEncryptionApi';
36
+ export * from './SecurityManagementJWTApi';
36
37
  export * from './SecurityManagementLDAPApi';
37
38
  export * from './SecurityManagementPrivilegesApi';
38
39
  export * from './SecurityManagementRealmsApi';
@@ -44,6 +45,7 @@ export * from './SecurityManagementSSRFProtectionApi';
44
45
  export * from './SecurityManagementSecretsEncryptionApi';
45
46
  export * from './SecurityManagementUserTokensApi';
46
47
  export * from './SecurityManagementUsersApi';
48
+ export * from './SecurityOAuth2OIDCApi';
47
49
  export * from './StagingApi';
48
50
  export * from './StatusApi';
49
51
  export * from './SupportApi';