@emilgroup/auth-sdk-node 1.15.1-beta.0 → 1.17.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.
@@ -16,6 +16,7 @@ models/create-user-request-dto.ts
16
16
  models/create-user-response-class.ts
17
17
  models/custom-schema-class.ts
18
18
  models/forgot-password-request-dto.ts
19
+ models/get-saml-login-link-request-dto.ts
19
20
  models/index.ts
20
21
  models/inline-response200.ts
21
22
  models/inline-response503.ts
@@ -29,6 +30,7 @@ models/refresh-token-dto.ts
29
30
  models/reset-password-request-dto.ts
30
31
  models/role-class.ts
31
32
  models/user-class.ts
33
+ models/verify-org-invitation-request-dto.ts
32
34
  models/verify-org-invitation-response-class.ts
33
35
  package.json
34
36
  tsconfig.json
package/README.md CHANGED
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
17
17
  Navigate to the folder of your consuming project and run one of the following commands:
18
18
 
19
19
  ```
20
- npm install @emilgroup/auth-sdk-node@1.15.1-beta.0 --save
20
+ npm install @emilgroup/auth-sdk-node@1.17.1 --save
21
21
  ```
22
22
  or
23
23
  ```
24
- yarn add @emilgroup/auth-sdk-node@1.15.1-beta.0
24
+ yarn add @emilgroup/auth-sdk-node@1.17.1
25
25
  ```
26
26
 
27
27
  And then you can import ``.
@@ -35,7 +35,7 @@ const FormData = require('form-data');
35
35
  export const DefaultApiAxiosParamCreator = function (configuration?: Configuration) {
36
36
  return {
37
37
  /**
38
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
38
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
39
39
  * @summary Health Check
40
40
  * @param {*} [options] Override http request option.
41
41
  * @throws {RequiredError}
@@ -77,7 +77,7 @@ export const DefaultApiFp = function(configuration?: Configuration) {
77
77
  const localVarAxiosParamCreator = DefaultApiAxiosParamCreator(configuration)
78
78
  return {
79
79
  /**
80
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
80
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
81
81
  * @summary Health Check
82
82
  * @param {*} [options] Override http request option.
83
83
  * @throws {RequiredError}
@@ -97,7 +97,7 @@ export const DefaultApiFactory = function (configuration?: Configuration, basePa
97
97
  const localVarFp = DefaultApiFp(configuration)
98
98
  return {
99
99
  /**
100
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
100
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
101
101
  * @summary Health Check
102
102
  * @param {*} [options] Override http request option.
103
103
  * @throws {RequiredError}
@@ -116,7 +116,7 @@ export const DefaultApiFactory = function (configuration?: Configuration, basePa
116
116
  */
117
117
  export class DefaultApi extends BaseAPI {
118
118
  /**
119
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
119
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
120
120
  * @summary Health Check
121
121
  * @param {*} [options] Override http request option.
122
122
  * @throws {RequiredError}
package/base.ts CHANGED
@@ -225,7 +225,7 @@ export class BaseAPI {
225
225
  const tokenString = await this.refreshTokenInternal();
226
226
  const accessToken = `Bearer ${tokenString}`;
227
227
 
228
- originalConfig.headers['Authorization'] = `Bearer ${accessToken}`
228
+ originalConfig.headers['Authorization'] = accessToken;
229
229
 
230
230
  this.configuration.accessToken = accessToken;
231
231
 
package/common.ts CHANGED
@@ -66,7 +66,7 @@ export const setBearerAuthToObject = async function (object: any, configuration?
66
66
  const accessToken = typeof configuration.accessToken === 'function'
67
67
  ? await configuration.accessToken()
68
68
  : await configuration.accessToken;
69
- object["Authorization"] = "Bearer " + accessToken;
69
+ object["Authorization"] = configuration.getBearerToken(accessToken);
70
70
  }
71
71
  }
72
72
 
@@ -79,7 +79,7 @@ export const setOAuthToObject = async function (object: any, name: string, scope
79
79
  const localVarAccessTokenValue = typeof configuration.accessToken === 'function'
80
80
  ? await configuration.accessToken(name, scopes)
81
81
  : await configuration.accessToken;
82
- object["Authorization"] = "Bearer " + localVarAccessTokenValue;
82
+ object["Authorization"] = configuration.getBearerToken(localVarAccessTokenValue);
83
83
  }
84
84
  }
85
85
 
package/configuration.ts CHANGED
@@ -106,4 +106,13 @@ export class Configuration {
106
106
  const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
107
107
  return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
108
108
  }
109
+
110
+ /**
111
+ * Returns "Bearer" token.
112
+ * @param token - access token.
113
+ * @return Bearer token.
114
+ */
115
+ public getBearerToken(token?: string): string {
116
+ return ('' + token).startsWith("Bearer") ? token : "Bearer " + token;
117
+ }
109
118
  }
@@ -19,7 +19,7 @@ import { InlineResponse200 } from '../models';
19
19
  */
20
20
  export declare const DefaultApiAxiosParamCreator: (configuration?: Configuration) => {
21
21
  /**
22
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
22
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
23
23
  * @summary Health Check
24
24
  * @param {*} [options] Override http request option.
25
25
  * @throws {RequiredError}
@@ -32,7 +32,7 @@ export declare const DefaultApiAxiosParamCreator: (configuration?: Configuration
32
32
  */
33
33
  export declare const DefaultApiFp: (configuration?: Configuration) => {
34
34
  /**
35
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
35
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
36
36
  * @summary Health Check
37
37
  * @param {*} [options] Override http request option.
38
38
  * @throws {RequiredError}
@@ -45,7 +45,7 @@ export declare const DefaultApiFp: (configuration?: Configuration) => {
45
45
  */
46
46
  export declare const DefaultApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
47
47
  /**
48
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
48
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
49
49
  * @summary Health Check
50
50
  * @param {*} [options] Override http request option.
51
51
  * @throws {RequiredError}
@@ -60,7 +60,7 @@ export declare const DefaultApiFactory: (configuration?: Configuration, basePath
60
60
  */
61
61
  export declare class DefaultApi extends BaseAPI {
62
62
  /**
63
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
63
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
64
64
  * @summary Health Check
65
65
  * @param {*} [options] Override http request option.
66
66
  * @throws {RequiredError}
@@ -97,7 +97,7 @@ var DefaultApiAxiosParamCreator = function (configuration) {
97
97
  var _this = this;
98
98
  return {
99
99
  /**
100
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
100
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
101
101
  * @summary Health Check
102
102
  * @param {*} [options] Override http request option.
103
103
  * @throws {RequiredError}
@@ -137,7 +137,7 @@ var DefaultApiFp = function (configuration) {
137
137
  var localVarAxiosParamCreator = (0, exports.DefaultApiAxiosParamCreator)(configuration);
138
138
  return {
139
139
  /**
140
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
140
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
141
141
  * @summary Health Check
142
142
  * @param {*} [options] Override http request option.
143
143
  * @throws {RequiredError}
@@ -166,7 +166,7 @@ var DefaultApiFactory = function (configuration, basePath, axios) {
166
166
  var localVarFp = (0, exports.DefaultApiFp)(configuration);
167
167
  return {
168
168
  /**
169
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
169
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
170
170
  * @summary Health Check
171
171
  * @param {*} [options] Override http request option.
172
172
  * @throws {RequiredError}
@@ -189,7 +189,7 @@ var DefaultApi = /** @class */ (function (_super) {
189
189
  return _super !== null && _super.apply(this, arguments) || this;
190
190
  }
191
191
  /**
192
- * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
192
+ * Returns the health status of the auth service. This endpoint is used to monitor the operational status of the auth service. It typically returns a simple status indicator, such as \'UP\' or \'OK\', confirming that the service is operational and available.
193
193
  * @summary Health Check
194
194
  * @param {*} [options] Override http request option.
195
195
  * @throws {RequiredError}
package/dist/base.js CHANGED
@@ -330,7 +330,7 @@ var BaseAPI = /** @class */ (function () {
330
330
  case 2:
331
331
  tokenString = _a.sent();
332
332
  accessToken = "Bearer ".concat(tokenString);
333
- originalConfig.headers['Authorization'] = "Bearer ".concat(accessToken);
333
+ originalConfig.headers['Authorization'] = accessToken;
334
334
  this.configuration.accessToken = accessToken;
335
335
  return [2 /*return*/, axios.request(originalConfig)];
336
336
  case 3:
package/dist/common.js CHANGED
@@ -141,7 +141,7 @@ var setBearerAuthToObject = function (object, configuration) {
141
141
  _b.label = 4;
142
142
  case 4:
143
143
  accessToken = _a;
144
- object["Authorization"] = "Bearer " + accessToken;
144
+ object["Authorization"] = configuration.getBearerToken(accessToken);
145
145
  _b.label = 5;
146
146
  case 5: return [2 /*return*/];
147
147
  }
@@ -171,7 +171,7 @@ var setOAuthToObject = function (object, name, scopes, configuration) {
171
171
  _b.label = 4;
172
172
  case 4:
173
173
  localVarAccessTokenValue = _a;
174
- object["Authorization"] = "Bearer " + localVarAccessTokenValue;
174
+ object["Authorization"] = configuration.getBearerToken(localVarAccessTokenValue);
175
175
  _b.label = 5;
176
176
  case 5: return [2 /*return*/];
177
177
  }
@@ -87,4 +87,10 @@ export declare class Configuration {
87
87
  * @return True if the given MIME is JSON, false otherwise.
88
88
  */
89
89
  isJsonMime(mime: string): boolean;
90
+ /**
91
+ * Returns "Bearer" token.
92
+ * @param token - access token.
93
+ * @return Bearer token.
94
+ */
95
+ getBearerToken(token?: string): string;
90
96
  }
@@ -39,6 +39,14 @@ var Configuration = /** @class */ (function () {
39
39
  var jsonMime = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i');
40
40
  return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json');
41
41
  };
42
+ /**
43
+ * Returns "Bearer" token.
44
+ * @param token - access token.
45
+ * @return Bearer token.
46
+ */
47
+ Configuration.prototype.getBearerToken = function (token) {
48
+ return ('' + token).startsWith("Bearer") ? token : "Bearer " + token;
49
+ };
42
50
  return Configuration;
43
51
  }());
44
52
  exports.Configuration = Configuration;
@@ -0,0 +1,24 @@
1
+ /**
2
+ * EMIL AuthService
3
+ * The EMIL AuthService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
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 GetSamlLoginLinkRequestDto
16
+ */
17
+ export interface GetSamlLoginLinkRequestDto {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof GetSamlLoginLinkRequestDto
22
+ */
23
+ 'tenantSlug': string;
24
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * EMIL AuthService
6
+ * The EMIL AuthService API description
7
+ *
8
+ * The version of the OpenAPI document: 1.0
9
+ * Contact: kontakt@emil.de
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 });
@@ -4,6 +4,7 @@ export * from './create-user-request-dto';
4
4
  export * from './create-user-response-class';
5
5
  export * from './custom-schema-class';
6
6
  export * from './forgot-password-request-dto';
7
+ export * from './get-saml-login-link-request-dto';
7
8
  export * from './inline-response200';
8
9
  export * from './inline-response503';
9
10
  export * from './login-by-saml-request-dto';
@@ -16,4 +17,5 @@ export * from './refresh-token-dto';
16
17
  export * from './reset-password-request-dto';
17
18
  export * from './role-class';
18
19
  export * from './user-class';
20
+ export * from './verify-org-invitation-request-dto';
19
21
  export * from './verify-org-invitation-response-class';
@@ -20,6 +20,7 @@ __exportStar(require("./create-user-request-dto"), exports);
20
20
  __exportStar(require("./create-user-response-class"), exports);
21
21
  __exportStar(require("./custom-schema-class"), exports);
22
22
  __exportStar(require("./forgot-password-request-dto"), exports);
23
+ __exportStar(require("./get-saml-login-link-request-dto"), exports);
23
24
  __exportStar(require("./inline-response200"), exports);
24
25
  __exportStar(require("./inline-response503"), exports);
25
26
  __exportStar(require("./login-by-saml-request-dto"), exports);
@@ -32,4 +33,5 @@ __exportStar(require("./refresh-token-dto"), exports);
32
33
  __exportStar(require("./reset-password-request-dto"), exports);
33
34
  __exportStar(require("./role-class"), exports);
34
35
  __exportStar(require("./user-class"), exports);
36
+ __exportStar(require("./verify-org-invitation-request-dto"), exports);
35
37
  __exportStar(require("./verify-org-invitation-response-class"), exports);
@@ -0,0 +1,24 @@
1
+ /**
2
+ * EMIL AuthService
3
+ * The EMIL AuthService API description
4
+ *
5
+ * The version of the OpenAPI document: 1.0
6
+ * Contact: kontakt@emil.de
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 VerifyOrgInvitationRequestDto
16
+ */
17
+ export interface VerifyOrgInvitationRequestDto {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof VerifyOrgInvitationRequestDto
22
+ */
23
+ 'invitationToken': string;
24
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * EMIL AuthService
6
+ * The EMIL AuthService API description
7
+ *
8
+ * The version of the OpenAPI document: 1.0
9
+ * Contact: kontakt@emil.de
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 });
@@ -0,0 +1,30 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL AuthService
5
+ * The EMIL AuthService API description
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
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
+
17
+ /**
18
+ *
19
+ * @export
20
+ * @interface GetSamlLoginLinkRequestDto
21
+ */
22
+ export interface GetSamlLoginLinkRequestDto {
23
+ /**
24
+ *
25
+ * @type {string}
26
+ * @memberof GetSamlLoginLinkRequestDto
27
+ */
28
+ 'tenantSlug': string;
29
+ }
30
+
package/models/index.ts CHANGED
@@ -4,6 +4,7 @@ export * from './create-user-request-dto';
4
4
  export * from './create-user-response-class';
5
5
  export * from './custom-schema-class';
6
6
  export * from './forgot-password-request-dto';
7
+ export * from './get-saml-login-link-request-dto';
7
8
  export * from './inline-response200';
8
9
  export * from './inline-response503';
9
10
  export * from './login-by-saml-request-dto';
@@ -16,4 +17,5 @@ export * from './refresh-token-dto';
16
17
  export * from './reset-password-request-dto';
17
18
  export * from './role-class';
18
19
  export * from './user-class';
20
+ export * from './verify-org-invitation-request-dto';
19
21
  export * from './verify-org-invitation-response-class';
@@ -0,0 +1,30 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * EMIL AuthService
5
+ * The EMIL AuthService API description
6
+ *
7
+ * The version of the OpenAPI document: 1.0
8
+ * Contact: kontakt@emil.de
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
+
17
+ /**
18
+ *
19
+ * @export
20
+ * @interface VerifyOrgInvitationRequestDto
21
+ */
22
+ export interface VerifyOrgInvitationRequestDto {
23
+ /**
24
+ *
25
+ * @type {string}
26
+ * @memberof VerifyOrgInvitationRequestDto
27
+ */
28
+ 'invitationToken': string;
29
+ }
30
+
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@emilgroup/auth-sdk-node",
3
- "version": "1.15.1-beta.0",
3
+ "version": "1.17.1",
4
4
  "description": "OpenAPI client for @emilgroup/auth-sdk-node",
5
5
  "author": "OpenAPI-Generator Contributors",
6
6
  "keywords": [