@emilgroup/auth-sdk-node 1.4.0 → 1.9.1-beta.2
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.
- package/.openapi-generator/FILES +2 -2
- package/README.md +2 -2
- package/api/authservice-api.ts +29 -29
- package/api/default-api.ts +8 -4
- package/dist/api/authservice-api.d.ts +613 -0
- package/dist/api/authservice-api.js +1069 -0
- package/dist/api/default-api.d.ts +70 -0
- package/dist/api/default-api.js +204 -0
- package/dist/api.d.ts +13 -0
- package/dist/api.js +31 -0
- package/dist/base.d.ts +78 -0
- package/dist/base.js +394 -0
- package/dist/common.d.ts +92 -0
- package/dist/common.js +277 -0
- package/dist/configuration.d.ts +90 -0
- package/dist/configuration.js +44 -0
- package/dist/index.d.ts +15 -0
- package/dist/index.js +36 -0
- package/dist/models/create-org-and-user-request-dto.d.ts +84 -0
- package/dist/models/create-org-and-user-request-dto.js +15 -0
- package/dist/models/create-org-and-user-response-class.d.ts +32 -0
- package/dist/models/create-org-and-user-response-class.js +15 -0
- package/dist/models/create-user-request-dto.d.ts +54 -0
- package/dist/models/create-user-request-dto.js +15 -0
- package/dist/models/create-user-response-class.d.ts +25 -0
- package/dist/models/create-user-response-class.js +15 -0
- package/dist/models/custom-schema-class.d.ts +66 -0
- package/dist/models/custom-schema-class.js +15 -0
- package/dist/models/forgot-password-request-dto.d.ts +24 -0
- package/dist/models/forgot-password-request-dto.js +15 -0
- package/dist/models/get-saml-login-link-request-dto.d.ts +24 -0
- package/dist/models/get-saml-login-link-request-dto.js +15 -0
- package/dist/models/index.d.ts +21 -0
- package/dist/models/index.js +37 -0
- package/dist/models/inline-response200.d.ts +54 -0
- package/dist/models/inline-response200.js +15 -0
- package/dist/models/inline-response503.d.ts +54 -0
- package/dist/models/inline-response503.js +15 -0
- package/dist/models/login-by-saml-request-dto.d.ts +30 -0
- package/dist/models/login-by-saml-request-dto.js +15 -0
- package/dist/models/login-class.d.ts +30 -0
- package/dist/models/login-class.js +15 -0
- package/dist/models/login-request-dto.d.ts +30 -0
- package/dist/models/login-request-dto.js +15 -0
- package/dist/models/logout-request-dto.d.ts +24 -0
- package/dist/models/logout-request-dto.js +15 -0
- package/dist/models/org-invitation-class.d.ts +109 -0
- package/dist/models/org-invitation-class.js +15 -0
- package/dist/models/organization-class.d.ts +114 -0
- package/dist/models/organization-class.js +15 -0
- package/dist/models/refresh-token-dto.d.ts +24 -0
- package/dist/models/refresh-token-dto.js +15 -0
- package/dist/models/reset-password-request-dto.d.ts +36 -0
- package/dist/models/reset-password-request-dto.js +15 -0
- package/dist/models/role-class.d.ts +54 -0
- package/dist/models/role-class.js +15 -0
- package/dist/models/user-class.d.ts +85 -0
- package/dist/models/user-class.js +15 -0
- package/dist/models/verify-org-invitation-request-dto.d.ts +24 -0
- package/dist/models/verify-org-invitation-request-dto.js +15 -0
- package/dist/models/verify-org-invitation-response-class.d.ts +32 -0
- package/dist/models/verify-org-invitation-response-class.js +15 -0
- package/models/{get-samllogin-link-request-dto.ts → get-saml-login-link-request-dto.ts} +3 -3
- package/models/index.ts +2 -2
- package/models/inline-response200.ts +6 -6
- package/models/inline-response503.ts +6 -6
- package/models/{login-by-samlrequest-dto.ts → login-by-saml-request-dto.ts} +4 -4
- package/package.json +1 -1
|
@@ -0,0 +1,1069 @@
|
|
|
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
|
+
var __extends = (this && this.__extends) || (function () {
|
|
16
|
+
var extendStatics = function (d, b) {
|
|
17
|
+
extendStatics = Object.setPrototypeOf ||
|
|
18
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
19
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
20
|
+
return extendStatics(d, b);
|
|
21
|
+
};
|
|
22
|
+
return function (d, b) {
|
|
23
|
+
if (typeof b !== "function" && b !== null)
|
|
24
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
25
|
+
extendStatics(d, b);
|
|
26
|
+
function __() { this.constructor = d; }
|
|
27
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
28
|
+
};
|
|
29
|
+
})();
|
|
30
|
+
var __assign = (this && this.__assign) || function () {
|
|
31
|
+
__assign = Object.assign || function(t) {
|
|
32
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
33
|
+
s = arguments[i];
|
|
34
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
35
|
+
t[p] = s[p];
|
|
36
|
+
}
|
|
37
|
+
return t;
|
|
38
|
+
};
|
|
39
|
+
return __assign.apply(this, arguments);
|
|
40
|
+
};
|
|
41
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
42
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
43
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
44
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
45
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
46
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
47
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
48
|
+
});
|
|
49
|
+
};
|
|
50
|
+
var __generator = (this && this.__generator) || function (thisArg, body) {
|
|
51
|
+
var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
|
|
52
|
+
return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
|
|
53
|
+
function verb(n) { return function (v) { return step([n, v]); }; }
|
|
54
|
+
function step(op) {
|
|
55
|
+
if (f) throw new TypeError("Generator is already executing.");
|
|
56
|
+
while (g && (g = 0, op[0] && (_ = 0)), _) try {
|
|
57
|
+
if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
|
|
58
|
+
if (y = 0, t) op = [op[0] & 2, t.value];
|
|
59
|
+
switch (op[0]) {
|
|
60
|
+
case 0: case 1: t = op; break;
|
|
61
|
+
case 4: _.label++; return { value: op[1], done: false };
|
|
62
|
+
case 5: _.label++; y = op[1]; op = [0]; continue;
|
|
63
|
+
case 7: op = _.ops.pop(); _.trys.pop(); continue;
|
|
64
|
+
default:
|
|
65
|
+
if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
|
|
66
|
+
if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
|
|
67
|
+
if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
|
|
68
|
+
if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
|
|
69
|
+
if (t[2]) _.ops.pop();
|
|
70
|
+
_.trys.pop(); continue;
|
|
71
|
+
}
|
|
72
|
+
op = body.call(thisArg, _);
|
|
73
|
+
} catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
|
|
74
|
+
if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
|
|
75
|
+
}
|
|
76
|
+
};
|
|
77
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
78
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
79
|
+
};
|
|
80
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
81
|
+
exports.AuthserviceApi = exports.AuthserviceApiFactory = exports.AuthserviceApiFp = exports.AuthserviceApiAxiosParamCreator = void 0;
|
|
82
|
+
var axios_1 = __importDefault(require("axios"));
|
|
83
|
+
// Some imports not used depending on template conditions
|
|
84
|
+
// @ts-ignore
|
|
85
|
+
var common_1 = require("../common");
|
|
86
|
+
// @ts-ignore
|
|
87
|
+
var base_1 = require("../base");
|
|
88
|
+
// URLSearchParams not necessarily used
|
|
89
|
+
// @ts-ignore
|
|
90
|
+
var url_1 = require("url");
|
|
91
|
+
var FormData = require('form-data');
|
|
92
|
+
/**
|
|
93
|
+
* AuthserviceApi - axios parameter creator
|
|
94
|
+
* @export
|
|
95
|
+
*/
|
|
96
|
+
var AuthserviceApiAxiosParamCreator = function (configuration) {
|
|
97
|
+
var _this = this;
|
|
98
|
+
return {
|
|
99
|
+
/**
|
|
100
|
+
* Register a new organization with appropriate hierarchy and create a user for that organization.
|
|
101
|
+
* @summary Register Organization and User using invitation token
|
|
102
|
+
* @param {CreateOrgAndUserRequestDto} createOrgAndUserRequestDto
|
|
103
|
+
* @param {*} [options] Override http request option.
|
|
104
|
+
* @throws {RequiredError}
|
|
105
|
+
*/
|
|
106
|
+
createOrgAndUser: function (createOrgAndUserRequestDto, options) {
|
|
107
|
+
if (options === void 0) { options = {}; }
|
|
108
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
109
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
110
|
+
return __generator(this, function (_a) {
|
|
111
|
+
// verify required parameter 'createOrgAndUserRequestDto' is not null or undefined
|
|
112
|
+
(0, common_1.assertParamExists)('createOrgAndUser', 'createOrgAndUserRequestDto', createOrgAndUserRequestDto);
|
|
113
|
+
localVarPath = "/authservice/v1/create-org-and-user";
|
|
114
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
115
|
+
if (configuration) {
|
|
116
|
+
baseOptions = configuration.baseOptions;
|
|
117
|
+
baseAccessToken = configuration.accessToken;
|
|
118
|
+
}
|
|
119
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
120
|
+
localVarHeaderParameter = {};
|
|
121
|
+
localVarQueryParameter = {};
|
|
122
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
123
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
124
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
125
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
126
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createOrgAndUserRequestDto, localVarRequestOptions, configuration);
|
|
127
|
+
return [2 /*return*/, {
|
|
128
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
129
|
+
options: localVarRequestOptions,
|
|
130
|
+
}];
|
|
131
|
+
});
|
|
132
|
+
});
|
|
133
|
+
},
|
|
134
|
+
/**
|
|
135
|
+
* Register a tenant user using the invite token sent to the tenant user\'s email address.
|
|
136
|
+
* @summary Register tenant user after invite
|
|
137
|
+
* @param {CreateUserRequestDto} createUserRequestDto
|
|
138
|
+
* @param {*} [options] Override http request option.
|
|
139
|
+
* @throws {RequiredError}
|
|
140
|
+
*/
|
|
141
|
+
createUser: function (createUserRequestDto, options) {
|
|
142
|
+
if (options === void 0) { options = {}; }
|
|
143
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
144
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
145
|
+
return __generator(this, function (_a) {
|
|
146
|
+
// verify required parameter 'createUserRequestDto' is not null or undefined
|
|
147
|
+
(0, common_1.assertParamExists)('createUser', 'createUserRequestDto', createUserRequestDto);
|
|
148
|
+
localVarPath = "/authservice/v1/create-user";
|
|
149
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
150
|
+
if (configuration) {
|
|
151
|
+
baseOptions = configuration.baseOptions;
|
|
152
|
+
baseAccessToken = configuration.accessToken;
|
|
153
|
+
}
|
|
154
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
155
|
+
localVarHeaderParameter = {};
|
|
156
|
+
localVarQueryParameter = {};
|
|
157
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
158
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
159
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
160
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
161
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createUserRequestDto, localVarRequestOptions, configuration);
|
|
162
|
+
return [2 /*return*/, {
|
|
163
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
164
|
+
options: localVarRequestOptions,
|
|
165
|
+
}];
|
|
166
|
+
});
|
|
167
|
+
});
|
|
168
|
+
},
|
|
169
|
+
/**
|
|
170
|
+
* Send a tenant user a reset-password token via email.
|
|
171
|
+
* @summary Forgot password by tenant
|
|
172
|
+
* @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
|
|
173
|
+
* @param {*} [options] Override http request option.
|
|
174
|
+
* @throws {RequiredError}
|
|
175
|
+
*/
|
|
176
|
+
forgotPassword: function (forgotPasswordRequestDto, options) {
|
|
177
|
+
if (options === void 0) { options = {}; }
|
|
178
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
179
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
180
|
+
return __generator(this, function (_a) {
|
|
181
|
+
// verify required parameter 'forgotPasswordRequestDto' is not null or undefined
|
|
182
|
+
(0, common_1.assertParamExists)('forgotPassword', 'forgotPasswordRequestDto', forgotPasswordRequestDto);
|
|
183
|
+
localVarPath = "/authservice/v1/forgot-password";
|
|
184
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
185
|
+
if (configuration) {
|
|
186
|
+
baseOptions = configuration.baseOptions;
|
|
187
|
+
baseAccessToken = configuration.accessToken;
|
|
188
|
+
}
|
|
189
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
190
|
+
localVarHeaderParameter = {};
|
|
191
|
+
localVarQueryParameter = {};
|
|
192
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
193
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
194
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
195
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
196
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(forgotPasswordRequestDto, localVarRequestOptions, configuration);
|
|
197
|
+
return [2 /*return*/, {
|
|
198
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
199
|
+
options: localVarRequestOptions,
|
|
200
|
+
}];
|
|
201
|
+
});
|
|
202
|
+
});
|
|
203
|
+
},
|
|
204
|
+
/**
|
|
205
|
+
* Get SAML login link configured for the tenant in cognito as well as tenant settings
|
|
206
|
+
* @summary Get SAML login link for tenant
|
|
207
|
+
* @param {string} tenantSlug
|
|
208
|
+
* @param {*} [options] Override http request option.
|
|
209
|
+
* @throws {RequiredError}
|
|
210
|
+
*/
|
|
211
|
+
getSamlLoginLink: function (tenantSlug, options) {
|
|
212
|
+
if (options === void 0) { options = {}; }
|
|
213
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
214
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
215
|
+
return __generator(this, function (_a) {
|
|
216
|
+
// verify required parameter 'tenantSlug' is not null or undefined
|
|
217
|
+
(0, common_1.assertParamExists)('getSamlLoginLink', 'tenantSlug', tenantSlug);
|
|
218
|
+
localVarPath = "/authservice/v1/saml-login-link";
|
|
219
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
220
|
+
if (configuration) {
|
|
221
|
+
baseOptions = configuration.baseOptions;
|
|
222
|
+
baseAccessToken = configuration.accessToken;
|
|
223
|
+
}
|
|
224
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
225
|
+
localVarHeaderParameter = {};
|
|
226
|
+
localVarQueryParameter = {};
|
|
227
|
+
if (tenantSlug !== undefined) {
|
|
228
|
+
localVarQueryParameter['tenantSlug'] = tenantSlug;
|
|
229
|
+
}
|
|
230
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
231
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
232
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
233
|
+
return [2 /*return*/, {
|
|
234
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
235
|
+
options: localVarRequestOptions,
|
|
236
|
+
}];
|
|
237
|
+
});
|
|
238
|
+
});
|
|
239
|
+
},
|
|
240
|
+
/**
|
|
241
|
+
* Get new access token, refresh token after successful login.
|
|
242
|
+
* @summary Login by tenant
|
|
243
|
+
* @param {LoginRequestDto} loginRequestDto
|
|
244
|
+
* @param {*} [options] Override http request option.
|
|
245
|
+
* @throws {RequiredError}
|
|
246
|
+
*/
|
|
247
|
+
login: function (loginRequestDto, options) {
|
|
248
|
+
if (options === void 0) { options = {}; }
|
|
249
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
250
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
251
|
+
return __generator(this, function (_a) {
|
|
252
|
+
// verify required parameter 'loginRequestDto' is not null or undefined
|
|
253
|
+
(0, common_1.assertParamExists)('login', 'loginRequestDto', loginRequestDto);
|
|
254
|
+
localVarPath = "/authservice/v1/login";
|
|
255
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
256
|
+
if (configuration) {
|
|
257
|
+
baseOptions = configuration.baseOptions;
|
|
258
|
+
baseAccessToken = configuration.accessToken;
|
|
259
|
+
}
|
|
260
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
261
|
+
localVarHeaderParameter = {};
|
|
262
|
+
localVarQueryParameter = {};
|
|
263
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
264
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
265
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
266
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
267
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(loginRequestDto, localVarRequestOptions, configuration);
|
|
268
|
+
return [2 /*return*/, {
|
|
269
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
270
|
+
options: localVarRequestOptions,
|
|
271
|
+
}];
|
|
272
|
+
});
|
|
273
|
+
});
|
|
274
|
+
},
|
|
275
|
+
/**
|
|
276
|
+
* Get new access token, refresh token after successful login. This api also creates a tenant user if user does not exist
|
|
277
|
+
* @summary Login by SAML idp provider such as ADFS
|
|
278
|
+
* @param {LoginBySamlRequestDto} loginBySamlRequestDto
|
|
279
|
+
* @param {*} [options] Override http request option.
|
|
280
|
+
* @throws {RequiredError}
|
|
281
|
+
*/
|
|
282
|
+
loginBySaml: function (loginBySamlRequestDto, options) {
|
|
283
|
+
if (options === void 0) { options = {}; }
|
|
284
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
285
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
286
|
+
return __generator(this, function (_a) {
|
|
287
|
+
// verify required parameter 'loginBySamlRequestDto' is not null or undefined
|
|
288
|
+
(0, common_1.assertParamExists)('loginBySaml', 'loginBySamlRequestDto', loginBySamlRequestDto);
|
|
289
|
+
localVarPath = "/authservice/v1/login/saml";
|
|
290
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
291
|
+
if (configuration) {
|
|
292
|
+
baseOptions = configuration.baseOptions;
|
|
293
|
+
baseAccessToken = configuration.accessToken;
|
|
294
|
+
}
|
|
295
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
296
|
+
localVarHeaderParameter = {};
|
|
297
|
+
localVarQueryParameter = {};
|
|
298
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
299
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
300
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
301
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
302
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(loginBySamlRequestDto, localVarRequestOptions, configuration);
|
|
303
|
+
return [2 /*return*/, {
|
|
304
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
305
|
+
options: localVarRequestOptions,
|
|
306
|
+
}];
|
|
307
|
+
});
|
|
308
|
+
});
|
|
309
|
+
},
|
|
310
|
+
/**
|
|
311
|
+
* Sign tenant user out.
|
|
312
|
+
* @summary Logout tenant
|
|
313
|
+
* @param {LogoutRequestDto} logoutRequestDto
|
|
314
|
+
* @param {*} [options] Override http request option.
|
|
315
|
+
* @throws {RequiredError}
|
|
316
|
+
*/
|
|
317
|
+
logout: function (logoutRequestDto, options) {
|
|
318
|
+
if (options === void 0) { options = {}; }
|
|
319
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
320
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
321
|
+
return __generator(this, function (_a) {
|
|
322
|
+
// verify required parameter 'logoutRequestDto' is not null or undefined
|
|
323
|
+
(0, common_1.assertParamExists)('logout', 'logoutRequestDto', logoutRequestDto);
|
|
324
|
+
localVarPath = "/authservice/v1/logout";
|
|
325
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
326
|
+
if (configuration) {
|
|
327
|
+
baseOptions = configuration.baseOptions;
|
|
328
|
+
baseAccessToken = configuration.accessToken;
|
|
329
|
+
}
|
|
330
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
331
|
+
localVarHeaderParameter = {};
|
|
332
|
+
localVarQueryParameter = {};
|
|
333
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
334
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
335
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
336
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
337
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(logoutRequestDto, localVarRequestOptions, configuration);
|
|
338
|
+
return [2 /*return*/, {
|
|
339
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
340
|
+
options: localVarRequestOptions,
|
|
341
|
+
}];
|
|
342
|
+
});
|
|
343
|
+
});
|
|
344
|
+
},
|
|
345
|
+
/**
|
|
346
|
+
* Get new access token, new refresh token.
|
|
347
|
+
* @summary Refresh token by tenant
|
|
348
|
+
* @param {RefreshTokenDto} refreshTokenDto
|
|
349
|
+
* @param {string} [cookie] HTTP only cookie that was sent during login
|
|
350
|
+
* @param {*} [options] Override http request option.
|
|
351
|
+
* @throws {RequiredError}
|
|
352
|
+
*/
|
|
353
|
+
refreshToken: function (refreshTokenDto, cookie, options) {
|
|
354
|
+
if (options === void 0) { options = {}; }
|
|
355
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
356
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
357
|
+
return __generator(this, function (_a) {
|
|
358
|
+
// verify required parameter 'refreshTokenDto' is not null or undefined
|
|
359
|
+
(0, common_1.assertParamExists)('refreshToken', 'refreshTokenDto', refreshTokenDto);
|
|
360
|
+
localVarPath = "/authservice/v1/refresh-token";
|
|
361
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
362
|
+
if (configuration) {
|
|
363
|
+
baseOptions = configuration.baseOptions;
|
|
364
|
+
baseAccessToken = configuration.accessToken;
|
|
365
|
+
}
|
|
366
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
367
|
+
localVarHeaderParameter = {};
|
|
368
|
+
localVarQueryParameter = {};
|
|
369
|
+
if (cookie !== undefined && cookie !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
370
|
+
localVarHeaderParameter['Cookie'] = String(cookie ? cookie : baseAccessToken);
|
|
371
|
+
}
|
|
372
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
373
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
374
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
375
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
376
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(refreshTokenDto, localVarRequestOptions, configuration);
|
|
377
|
+
return [2 /*return*/, {
|
|
378
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
379
|
+
options: localVarRequestOptions,
|
|
380
|
+
}];
|
|
381
|
+
});
|
|
382
|
+
});
|
|
383
|
+
},
|
|
384
|
+
/**
|
|
385
|
+
* Change tenant user\'s password using the token provided by the reset password endpoint.
|
|
386
|
+
* @summary Change password by tenant
|
|
387
|
+
* @param {ResetPasswordRequestDto} resetPasswordRequestDto
|
|
388
|
+
* @param {*} [options] Override http request option.
|
|
389
|
+
* @throws {RequiredError}
|
|
390
|
+
*/
|
|
391
|
+
resetPassword: function (resetPasswordRequestDto, options) {
|
|
392
|
+
if (options === void 0) { options = {}; }
|
|
393
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
394
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
395
|
+
return __generator(this, function (_a) {
|
|
396
|
+
// verify required parameter 'resetPasswordRequestDto' is not null or undefined
|
|
397
|
+
(0, common_1.assertParamExists)('resetPassword', 'resetPasswordRequestDto', resetPasswordRequestDto);
|
|
398
|
+
localVarPath = "/authservice/v1/reset-password";
|
|
399
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
400
|
+
if (configuration) {
|
|
401
|
+
baseOptions = configuration.baseOptions;
|
|
402
|
+
baseAccessToken = configuration.accessToken;
|
|
403
|
+
}
|
|
404
|
+
localVarRequestOptions = __assign(__assign({ method: 'POST' }, baseOptions), options);
|
|
405
|
+
localVarHeaderParameter = {};
|
|
406
|
+
localVarQueryParameter = {};
|
|
407
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
408
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
409
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
410
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
411
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(resetPasswordRequestDto, localVarRequestOptions, configuration);
|
|
412
|
+
return [2 /*return*/, {
|
|
413
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
414
|
+
options: localVarRequestOptions,
|
|
415
|
+
}];
|
|
416
|
+
});
|
|
417
|
+
});
|
|
418
|
+
},
|
|
419
|
+
/**
|
|
420
|
+
* Verify the invite sent to the tenant user via email.
|
|
421
|
+
* @summary Verify tenant user\'s invite token
|
|
422
|
+
* @param {string} token
|
|
423
|
+
* @param {*} [options] Override http request option.
|
|
424
|
+
* @throws {RequiredError}
|
|
425
|
+
*/
|
|
426
|
+
verifyInvite: function (token, options) {
|
|
427
|
+
if (options === void 0) { options = {}; }
|
|
428
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
429
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
430
|
+
return __generator(this, function (_a) {
|
|
431
|
+
// verify required parameter 'token' is not null or undefined
|
|
432
|
+
(0, common_1.assertParamExists)('verifyInvite', 'token', token);
|
|
433
|
+
localVarPath = "/authservice/v1/verify-invite";
|
|
434
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
435
|
+
if (configuration) {
|
|
436
|
+
baseOptions = configuration.baseOptions;
|
|
437
|
+
baseAccessToken = configuration.accessToken;
|
|
438
|
+
}
|
|
439
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
440
|
+
localVarHeaderParameter = {};
|
|
441
|
+
localVarQueryParameter = {};
|
|
442
|
+
if (token !== undefined) {
|
|
443
|
+
localVarQueryParameter['token'] = token;
|
|
444
|
+
}
|
|
445
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
446
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
447
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
448
|
+
return [2 /*return*/, {
|
|
449
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
450
|
+
options: localVarRequestOptions,
|
|
451
|
+
}];
|
|
452
|
+
});
|
|
453
|
+
});
|
|
454
|
+
},
|
|
455
|
+
/**
|
|
456
|
+
* Verifies token and returns necessary data for signing up as an organization.
|
|
457
|
+
* @summary Verify a organization\'s invitation token
|
|
458
|
+
* @param {string} invitationToken
|
|
459
|
+
* @param {*} [options] Override http request option.
|
|
460
|
+
* @throws {RequiredError}
|
|
461
|
+
*/
|
|
462
|
+
verifyOrgInvitation: function (invitationToken, options) {
|
|
463
|
+
if (options === void 0) { options = {}; }
|
|
464
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
465
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
466
|
+
return __generator(this, function (_a) {
|
|
467
|
+
// verify required parameter 'invitationToken' is not null or undefined
|
|
468
|
+
(0, common_1.assertParamExists)('verifyOrgInvitation', 'invitationToken', invitationToken);
|
|
469
|
+
localVarPath = "/authservice/v1/verify-org-invitation";
|
|
470
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
471
|
+
if (configuration) {
|
|
472
|
+
baseOptions = configuration.baseOptions;
|
|
473
|
+
baseAccessToken = configuration.accessToken;
|
|
474
|
+
}
|
|
475
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
476
|
+
localVarHeaderParameter = {};
|
|
477
|
+
localVarQueryParameter = {};
|
|
478
|
+
if (invitationToken !== undefined) {
|
|
479
|
+
localVarQueryParameter['invitationToken'] = invitationToken;
|
|
480
|
+
}
|
|
481
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
482
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
483
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
484
|
+
return [2 /*return*/, {
|
|
485
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
486
|
+
options: localVarRequestOptions,
|
|
487
|
+
}];
|
|
488
|
+
});
|
|
489
|
+
});
|
|
490
|
+
},
|
|
491
|
+
/**
|
|
492
|
+
* Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
|
|
493
|
+
* @summary Verify tenant reset password token
|
|
494
|
+
* @param {string} resetToken Tenant user\'s reset token. Reset token can be found in the email sent after \'forgot-password\' endpoint was called.
|
|
495
|
+
* @param {*} [options] Override http request option.
|
|
496
|
+
* @throws {RequiredError}
|
|
497
|
+
*/
|
|
498
|
+
verifyResetPasswordToken: function (resetToken, options) {
|
|
499
|
+
if (options === void 0) { options = {}; }
|
|
500
|
+
return __awaiter(_this, void 0, void 0, function () {
|
|
501
|
+
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
502
|
+
return __generator(this, function (_a) {
|
|
503
|
+
// verify required parameter 'resetToken' is not null or undefined
|
|
504
|
+
(0, common_1.assertParamExists)('verifyResetPasswordToken', 'resetToken', resetToken);
|
|
505
|
+
localVarPath = "/authservice/v1/verify-reset-password";
|
|
506
|
+
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
507
|
+
if (configuration) {
|
|
508
|
+
baseOptions = configuration.baseOptions;
|
|
509
|
+
baseAccessToken = configuration.accessToken;
|
|
510
|
+
}
|
|
511
|
+
localVarRequestOptions = __assign(__assign({ method: 'GET' }, baseOptions), options);
|
|
512
|
+
localVarHeaderParameter = {};
|
|
513
|
+
localVarQueryParameter = {};
|
|
514
|
+
if (resetToken !== undefined) {
|
|
515
|
+
localVarQueryParameter['resetToken'] = resetToken;
|
|
516
|
+
}
|
|
517
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
518
|
+
headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
519
|
+
localVarRequestOptions.headers = __assign(__assign(__assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
520
|
+
return [2 /*return*/, {
|
|
521
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
522
|
+
options: localVarRequestOptions,
|
|
523
|
+
}];
|
|
524
|
+
});
|
|
525
|
+
});
|
|
526
|
+
},
|
|
527
|
+
};
|
|
528
|
+
};
|
|
529
|
+
exports.AuthserviceApiAxiosParamCreator = AuthserviceApiAxiosParamCreator;
|
|
530
|
+
/**
|
|
531
|
+
* AuthserviceApi - functional programming interface
|
|
532
|
+
* @export
|
|
533
|
+
*/
|
|
534
|
+
var AuthserviceApiFp = function (configuration) {
|
|
535
|
+
var localVarAxiosParamCreator = (0, exports.AuthserviceApiAxiosParamCreator)(configuration);
|
|
536
|
+
return {
|
|
537
|
+
/**
|
|
538
|
+
* Register a new organization with appropriate hierarchy and create a user for that organization.
|
|
539
|
+
* @summary Register Organization and User using invitation token
|
|
540
|
+
* @param {CreateOrgAndUserRequestDto} createOrgAndUserRequestDto
|
|
541
|
+
* @param {*} [options] Override http request option.
|
|
542
|
+
* @throws {RequiredError}
|
|
543
|
+
*/
|
|
544
|
+
createOrgAndUser: function (createOrgAndUserRequestDto, options) {
|
|
545
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
546
|
+
var localVarAxiosArgs;
|
|
547
|
+
return __generator(this, function (_a) {
|
|
548
|
+
switch (_a.label) {
|
|
549
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.createOrgAndUser(createOrgAndUserRequestDto, options)];
|
|
550
|
+
case 1:
|
|
551
|
+
localVarAxiosArgs = _a.sent();
|
|
552
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
553
|
+
}
|
|
554
|
+
});
|
|
555
|
+
});
|
|
556
|
+
},
|
|
557
|
+
/**
|
|
558
|
+
* Register a tenant user using the invite token sent to the tenant user\'s email address.
|
|
559
|
+
* @summary Register tenant user after invite
|
|
560
|
+
* @param {CreateUserRequestDto} createUserRequestDto
|
|
561
|
+
* @param {*} [options] Override http request option.
|
|
562
|
+
* @throws {RequiredError}
|
|
563
|
+
*/
|
|
564
|
+
createUser: function (createUserRequestDto, options) {
|
|
565
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
566
|
+
var localVarAxiosArgs;
|
|
567
|
+
return __generator(this, function (_a) {
|
|
568
|
+
switch (_a.label) {
|
|
569
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.createUser(createUserRequestDto, options)];
|
|
570
|
+
case 1:
|
|
571
|
+
localVarAxiosArgs = _a.sent();
|
|
572
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
573
|
+
}
|
|
574
|
+
});
|
|
575
|
+
});
|
|
576
|
+
},
|
|
577
|
+
/**
|
|
578
|
+
* Send a tenant user a reset-password token via email.
|
|
579
|
+
* @summary Forgot password by tenant
|
|
580
|
+
* @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
|
|
581
|
+
* @param {*} [options] Override http request option.
|
|
582
|
+
* @throws {RequiredError}
|
|
583
|
+
*/
|
|
584
|
+
forgotPassword: function (forgotPasswordRequestDto, options) {
|
|
585
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
586
|
+
var localVarAxiosArgs;
|
|
587
|
+
return __generator(this, function (_a) {
|
|
588
|
+
switch (_a.label) {
|
|
589
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.forgotPassword(forgotPasswordRequestDto, options)];
|
|
590
|
+
case 1:
|
|
591
|
+
localVarAxiosArgs = _a.sent();
|
|
592
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
593
|
+
}
|
|
594
|
+
});
|
|
595
|
+
});
|
|
596
|
+
},
|
|
597
|
+
/**
|
|
598
|
+
* Get SAML login link configured for the tenant in cognito as well as tenant settings
|
|
599
|
+
* @summary Get SAML login link for tenant
|
|
600
|
+
* @param {string} tenantSlug
|
|
601
|
+
* @param {*} [options] Override http request option.
|
|
602
|
+
* @throws {RequiredError}
|
|
603
|
+
*/
|
|
604
|
+
getSamlLoginLink: function (tenantSlug, options) {
|
|
605
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
606
|
+
var localVarAxiosArgs;
|
|
607
|
+
return __generator(this, function (_a) {
|
|
608
|
+
switch (_a.label) {
|
|
609
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getSamlLoginLink(tenantSlug, options)];
|
|
610
|
+
case 1:
|
|
611
|
+
localVarAxiosArgs = _a.sent();
|
|
612
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
613
|
+
}
|
|
614
|
+
});
|
|
615
|
+
});
|
|
616
|
+
},
|
|
617
|
+
/**
|
|
618
|
+
* Get new access token, refresh token after successful login.
|
|
619
|
+
* @summary Login by tenant
|
|
620
|
+
* @param {LoginRequestDto} loginRequestDto
|
|
621
|
+
* @param {*} [options] Override http request option.
|
|
622
|
+
* @throws {RequiredError}
|
|
623
|
+
*/
|
|
624
|
+
login: function (loginRequestDto, options) {
|
|
625
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
626
|
+
var localVarAxiosArgs;
|
|
627
|
+
return __generator(this, function (_a) {
|
|
628
|
+
switch (_a.label) {
|
|
629
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.login(loginRequestDto, options)];
|
|
630
|
+
case 1:
|
|
631
|
+
localVarAxiosArgs = _a.sent();
|
|
632
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
633
|
+
}
|
|
634
|
+
});
|
|
635
|
+
});
|
|
636
|
+
},
|
|
637
|
+
/**
|
|
638
|
+
* Get new access token, refresh token after successful login. This api also creates a tenant user if user does not exist
|
|
639
|
+
* @summary Login by SAML idp provider such as ADFS
|
|
640
|
+
* @param {LoginBySamlRequestDto} loginBySamlRequestDto
|
|
641
|
+
* @param {*} [options] Override http request option.
|
|
642
|
+
* @throws {RequiredError}
|
|
643
|
+
*/
|
|
644
|
+
loginBySaml: function (loginBySamlRequestDto, options) {
|
|
645
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
646
|
+
var localVarAxiosArgs;
|
|
647
|
+
return __generator(this, function (_a) {
|
|
648
|
+
switch (_a.label) {
|
|
649
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.loginBySaml(loginBySamlRequestDto, options)];
|
|
650
|
+
case 1:
|
|
651
|
+
localVarAxiosArgs = _a.sent();
|
|
652
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
653
|
+
}
|
|
654
|
+
});
|
|
655
|
+
});
|
|
656
|
+
},
|
|
657
|
+
/**
|
|
658
|
+
* Sign tenant user out.
|
|
659
|
+
* @summary Logout tenant
|
|
660
|
+
* @param {LogoutRequestDto} logoutRequestDto
|
|
661
|
+
* @param {*} [options] Override http request option.
|
|
662
|
+
* @throws {RequiredError}
|
|
663
|
+
*/
|
|
664
|
+
logout: function (logoutRequestDto, options) {
|
|
665
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
666
|
+
var localVarAxiosArgs;
|
|
667
|
+
return __generator(this, function (_a) {
|
|
668
|
+
switch (_a.label) {
|
|
669
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.logout(logoutRequestDto, options)];
|
|
670
|
+
case 1:
|
|
671
|
+
localVarAxiosArgs = _a.sent();
|
|
672
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
673
|
+
}
|
|
674
|
+
});
|
|
675
|
+
});
|
|
676
|
+
},
|
|
677
|
+
/**
|
|
678
|
+
* Get new access token, new refresh token.
|
|
679
|
+
* @summary Refresh token by tenant
|
|
680
|
+
* @param {RefreshTokenDto} refreshTokenDto
|
|
681
|
+
* @param {string} [cookie] HTTP only cookie that was sent during login
|
|
682
|
+
* @param {*} [options] Override http request option.
|
|
683
|
+
* @throws {RequiredError}
|
|
684
|
+
*/
|
|
685
|
+
refreshToken: function (refreshTokenDto, cookie, options) {
|
|
686
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
687
|
+
var localVarAxiosArgs;
|
|
688
|
+
return __generator(this, function (_a) {
|
|
689
|
+
switch (_a.label) {
|
|
690
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.refreshToken(refreshTokenDto, cookie, options)];
|
|
691
|
+
case 1:
|
|
692
|
+
localVarAxiosArgs = _a.sent();
|
|
693
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
694
|
+
}
|
|
695
|
+
});
|
|
696
|
+
});
|
|
697
|
+
},
|
|
698
|
+
/**
|
|
699
|
+
* Change tenant user\'s password using the token provided by the reset password endpoint.
|
|
700
|
+
* @summary Change password by tenant
|
|
701
|
+
* @param {ResetPasswordRequestDto} resetPasswordRequestDto
|
|
702
|
+
* @param {*} [options] Override http request option.
|
|
703
|
+
* @throws {RequiredError}
|
|
704
|
+
*/
|
|
705
|
+
resetPassword: function (resetPasswordRequestDto, options) {
|
|
706
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
707
|
+
var localVarAxiosArgs;
|
|
708
|
+
return __generator(this, function (_a) {
|
|
709
|
+
switch (_a.label) {
|
|
710
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.resetPassword(resetPasswordRequestDto, options)];
|
|
711
|
+
case 1:
|
|
712
|
+
localVarAxiosArgs = _a.sent();
|
|
713
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
714
|
+
}
|
|
715
|
+
});
|
|
716
|
+
});
|
|
717
|
+
},
|
|
718
|
+
/**
|
|
719
|
+
* Verify the invite sent to the tenant user via email.
|
|
720
|
+
* @summary Verify tenant user\'s invite token
|
|
721
|
+
* @param {string} token
|
|
722
|
+
* @param {*} [options] Override http request option.
|
|
723
|
+
* @throws {RequiredError}
|
|
724
|
+
*/
|
|
725
|
+
verifyInvite: function (token, options) {
|
|
726
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
727
|
+
var localVarAxiosArgs;
|
|
728
|
+
return __generator(this, function (_a) {
|
|
729
|
+
switch (_a.label) {
|
|
730
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.verifyInvite(token, options)];
|
|
731
|
+
case 1:
|
|
732
|
+
localVarAxiosArgs = _a.sent();
|
|
733
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
734
|
+
}
|
|
735
|
+
});
|
|
736
|
+
});
|
|
737
|
+
},
|
|
738
|
+
/**
|
|
739
|
+
* Verifies token and returns necessary data for signing up as an organization.
|
|
740
|
+
* @summary Verify a organization\'s invitation token
|
|
741
|
+
* @param {string} invitationToken
|
|
742
|
+
* @param {*} [options] Override http request option.
|
|
743
|
+
* @throws {RequiredError}
|
|
744
|
+
*/
|
|
745
|
+
verifyOrgInvitation: function (invitationToken, options) {
|
|
746
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
747
|
+
var localVarAxiosArgs;
|
|
748
|
+
return __generator(this, function (_a) {
|
|
749
|
+
switch (_a.label) {
|
|
750
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.verifyOrgInvitation(invitationToken, options)];
|
|
751
|
+
case 1:
|
|
752
|
+
localVarAxiosArgs = _a.sent();
|
|
753
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
754
|
+
}
|
|
755
|
+
});
|
|
756
|
+
});
|
|
757
|
+
},
|
|
758
|
+
/**
|
|
759
|
+
* Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
|
|
760
|
+
* @summary Verify tenant reset password token
|
|
761
|
+
* @param {string} resetToken Tenant user\'s reset token. Reset token can be found in the email sent after \'forgot-password\' endpoint was called.
|
|
762
|
+
* @param {*} [options] Override http request option.
|
|
763
|
+
* @throws {RequiredError}
|
|
764
|
+
*/
|
|
765
|
+
verifyResetPasswordToken: function (resetToken, options) {
|
|
766
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
767
|
+
var localVarAxiosArgs;
|
|
768
|
+
return __generator(this, function (_a) {
|
|
769
|
+
switch (_a.label) {
|
|
770
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.verifyResetPasswordToken(resetToken, options)];
|
|
771
|
+
case 1:
|
|
772
|
+
localVarAxiosArgs = _a.sent();
|
|
773
|
+
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
774
|
+
}
|
|
775
|
+
});
|
|
776
|
+
});
|
|
777
|
+
},
|
|
778
|
+
};
|
|
779
|
+
};
|
|
780
|
+
exports.AuthserviceApiFp = AuthserviceApiFp;
|
|
781
|
+
/**
|
|
782
|
+
* AuthserviceApi - factory interface
|
|
783
|
+
* @export
|
|
784
|
+
*/
|
|
785
|
+
var AuthserviceApiFactory = function (configuration, basePath, axios) {
|
|
786
|
+
var localVarFp = (0, exports.AuthserviceApiFp)(configuration);
|
|
787
|
+
return {
|
|
788
|
+
/**
|
|
789
|
+
* Register a new organization with appropriate hierarchy and create a user for that organization.
|
|
790
|
+
* @summary Register Organization and User using invitation token
|
|
791
|
+
* @param {CreateOrgAndUserRequestDto} createOrgAndUserRequestDto
|
|
792
|
+
* @param {*} [options] Override http request option.
|
|
793
|
+
* @throws {RequiredError}
|
|
794
|
+
*/
|
|
795
|
+
createOrgAndUser: function (createOrgAndUserRequestDto, options) {
|
|
796
|
+
return localVarFp.createOrgAndUser(createOrgAndUserRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
797
|
+
},
|
|
798
|
+
/**
|
|
799
|
+
* Register a tenant user using the invite token sent to the tenant user\'s email address.
|
|
800
|
+
* @summary Register tenant user after invite
|
|
801
|
+
* @param {CreateUserRequestDto} createUserRequestDto
|
|
802
|
+
* @param {*} [options] Override http request option.
|
|
803
|
+
* @throws {RequiredError}
|
|
804
|
+
*/
|
|
805
|
+
createUser: function (createUserRequestDto, options) {
|
|
806
|
+
return localVarFp.createUser(createUserRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
807
|
+
},
|
|
808
|
+
/**
|
|
809
|
+
* Send a tenant user a reset-password token via email.
|
|
810
|
+
* @summary Forgot password by tenant
|
|
811
|
+
* @param {ForgotPasswordRequestDto} forgotPasswordRequestDto
|
|
812
|
+
* @param {*} [options] Override http request option.
|
|
813
|
+
* @throws {RequiredError}
|
|
814
|
+
*/
|
|
815
|
+
forgotPassword: function (forgotPasswordRequestDto, options) {
|
|
816
|
+
return localVarFp.forgotPassword(forgotPasswordRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
817
|
+
},
|
|
818
|
+
/**
|
|
819
|
+
* Get SAML login link configured for the tenant in cognito as well as tenant settings
|
|
820
|
+
* @summary Get SAML login link for tenant
|
|
821
|
+
* @param {string} tenantSlug
|
|
822
|
+
* @param {*} [options] Override http request option.
|
|
823
|
+
* @throws {RequiredError}
|
|
824
|
+
*/
|
|
825
|
+
getSamlLoginLink: function (tenantSlug, options) {
|
|
826
|
+
return localVarFp.getSamlLoginLink(tenantSlug, options).then(function (request) { return request(axios, basePath); });
|
|
827
|
+
},
|
|
828
|
+
/**
|
|
829
|
+
* Get new access token, refresh token after successful login.
|
|
830
|
+
* @summary Login by tenant
|
|
831
|
+
* @param {LoginRequestDto} loginRequestDto
|
|
832
|
+
* @param {*} [options] Override http request option.
|
|
833
|
+
* @throws {RequiredError}
|
|
834
|
+
*/
|
|
835
|
+
login: function (loginRequestDto, options) {
|
|
836
|
+
return localVarFp.login(loginRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
837
|
+
},
|
|
838
|
+
/**
|
|
839
|
+
* Get new access token, refresh token after successful login. This api also creates a tenant user if user does not exist
|
|
840
|
+
* @summary Login by SAML idp provider such as ADFS
|
|
841
|
+
* @param {LoginBySamlRequestDto} loginBySamlRequestDto
|
|
842
|
+
* @param {*} [options] Override http request option.
|
|
843
|
+
* @throws {RequiredError}
|
|
844
|
+
*/
|
|
845
|
+
loginBySaml: function (loginBySamlRequestDto, options) {
|
|
846
|
+
return localVarFp.loginBySaml(loginBySamlRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
847
|
+
},
|
|
848
|
+
/**
|
|
849
|
+
* Sign tenant user out.
|
|
850
|
+
* @summary Logout tenant
|
|
851
|
+
* @param {LogoutRequestDto} logoutRequestDto
|
|
852
|
+
* @param {*} [options] Override http request option.
|
|
853
|
+
* @throws {RequiredError}
|
|
854
|
+
*/
|
|
855
|
+
logout: function (logoutRequestDto, options) {
|
|
856
|
+
return localVarFp.logout(logoutRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
857
|
+
},
|
|
858
|
+
/**
|
|
859
|
+
* Get new access token, new refresh token.
|
|
860
|
+
* @summary Refresh token by tenant
|
|
861
|
+
* @param {RefreshTokenDto} refreshTokenDto
|
|
862
|
+
* @param {string} [cookie] HTTP only cookie that was sent during login
|
|
863
|
+
* @param {*} [options] Override http request option.
|
|
864
|
+
* @throws {RequiredError}
|
|
865
|
+
*/
|
|
866
|
+
refreshToken: function (refreshTokenDto, cookie, options) {
|
|
867
|
+
return localVarFp.refreshToken(refreshTokenDto, cookie, options).then(function (request) { return request(axios, basePath); });
|
|
868
|
+
},
|
|
869
|
+
/**
|
|
870
|
+
* Change tenant user\'s password using the token provided by the reset password endpoint.
|
|
871
|
+
* @summary Change password by tenant
|
|
872
|
+
* @param {ResetPasswordRequestDto} resetPasswordRequestDto
|
|
873
|
+
* @param {*} [options] Override http request option.
|
|
874
|
+
* @throws {RequiredError}
|
|
875
|
+
*/
|
|
876
|
+
resetPassword: function (resetPasswordRequestDto, options) {
|
|
877
|
+
return localVarFp.resetPassword(resetPasswordRequestDto, options).then(function (request) { return request(axios, basePath); });
|
|
878
|
+
},
|
|
879
|
+
/**
|
|
880
|
+
* Verify the invite sent to the tenant user via email.
|
|
881
|
+
* @summary Verify tenant user\'s invite token
|
|
882
|
+
* @param {string} token
|
|
883
|
+
* @param {*} [options] Override http request option.
|
|
884
|
+
* @throws {RequiredError}
|
|
885
|
+
*/
|
|
886
|
+
verifyInvite: function (token, options) {
|
|
887
|
+
return localVarFp.verifyInvite(token, options).then(function (request) { return request(axios, basePath); });
|
|
888
|
+
},
|
|
889
|
+
/**
|
|
890
|
+
* Verifies token and returns necessary data for signing up as an organization.
|
|
891
|
+
* @summary Verify a organization\'s invitation token
|
|
892
|
+
* @param {string} invitationToken
|
|
893
|
+
* @param {*} [options] Override http request option.
|
|
894
|
+
* @throws {RequiredError}
|
|
895
|
+
*/
|
|
896
|
+
verifyOrgInvitation: function (invitationToken, options) {
|
|
897
|
+
return localVarFp.verifyOrgInvitation(invitationToken, options).then(function (request) { return request(axios, basePath); });
|
|
898
|
+
},
|
|
899
|
+
/**
|
|
900
|
+
* Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
|
|
901
|
+
* @summary Verify tenant reset password token
|
|
902
|
+
* @param {string} resetToken Tenant user\'s reset token. Reset token can be found in the email sent after \'forgot-password\' endpoint was called.
|
|
903
|
+
* @param {*} [options] Override http request option.
|
|
904
|
+
* @throws {RequiredError}
|
|
905
|
+
*/
|
|
906
|
+
verifyResetPasswordToken: function (resetToken, options) {
|
|
907
|
+
return localVarFp.verifyResetPasswordToken(resetToken, options).then(function (request) { return request(axios, basePath); });
|
|
908
|
+
},
|
|
909
|
+
};
|
|
910
|
+
};
|
|
911
|
+
exports.AuthserviceApiFactory = AuthserviceApiFactory;
|
|
912
|
+
/**
|
|
913
|
+
* AuthserviceApi - object-oriented interface
|
|
914
|
+
* @export
|
|
915
|
+
* @class AuthserviceApi
|
|
916
|
+
* @extends {BaseAPI}
|
|
917
|
+
*/
|
|
918
|
+
var AuthserviceApi = /** @class */ (function (_super) {
|
|
919
|
+
__extends(AuthserviceApi, _super);
|
|
920
|
+
function AuthserviceApi() {
|
|
921
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
922
|
+
}
|
|
923
|
+
/**
|
|
924
|
+
* Register a new organization with appropriate hierarchy and create a user for that organization.
|
|
925
|
+
* @summary Register Organization and User using invitation token
|
|
926
|
+
* @param {AuthserviceApiCreateOrgAndUserRequest} requestParameters Request parameters.
|
|
927
|
+
* @param {*} [options] Override http request option.
|
|
928
|
+
* @throws {RequiredError}
|
|
929
|
+
* @memberof AuthserviceApi
|
|
930
|
+
*/
|
|
931
|
+
AuthserviceApi.prototype.createOrgAndUser = function (requestParameters, options) {
|
|
932
|
+
var _this = this;
|
|
933
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).createOrgAndUser(requestParameters.createOrgAndUserRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
934
|
+
};
|
|
935
|
+
/**
|
|
936
|
+
* Register a tenant user using the invite token sent to the tenant user\'s email address.
|
|
937
|
+
* @summary Register tenant user after invite
|
|
938
|
+
* @param {AuthserviceApiCreateUserRequest} requestParameters Request parameters.
|
|
939
|
+
* @param {*} [options] Override http request option.
|
|
940
|
+
* @throws {RequiredError}
|
|
941
|
+
* @memberof AuthserviceApi
|
|
942
|
+
*/
|
|
943
|
+
AuthserviceApi.prototype.createUser = function (requestParameters, options) {
|
|
944
|
+
var _this = this;
|
|
945
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).createUser(requestParameters.createUserRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
946
|
+
};
|
|
947
|
+
/**
|
|
948
|
+
* Send a tenant user a reset-password token via email.
|
|
949
|
+
* @summary Forgot password by tenant
|
|
950
|
+
* @param {AuthserviceApiForgotPasswordRequest} requestParameters Request parameters.
|
|
951
|
+
* @param {*} [options] Override http request option.
|
|
952
|
+
* @throws {RequiredError}
|
|
953
|
+
* @memberof AuthserviceApi
|
|
954
|
+
*/
|
|
955
|
+
AuthserviceApi.prototype.forgotPassword = function (requestParameters, options) {
|
|
956
|
+
var _this = this;
|
|
957
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).forgotPassword(requestParameters.forgotPasswordRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
958
|
+
};
|
|
959
|
+
/**
|
|
960
|
+
* Get SAML login link configured for the tenant in cognito as well as tenant settings
|
|
961
|
+
* @summary Get SAML login link for tenant
|
|
962
|
+
* @param {AuthserviceApiGetSamlLoginLinkRequest} requestParameters Request parameters.
|
|
963
|
+
* @param {*} [options] Override http request option.
|
|
964
|
+
* @throws {RequiredError}
|
|
965
|
+
* @memberof AuthserviceApi
|
|
966
|
+
*/
|
|
967
|
+
AuthserviceApi.prototype.getSamlLoginLink = function (requestParameters, options) {
|
|
968
|
+
var _this = this;
|
|
969
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).getSamlLoginLink(requestParameters.tenantSlug, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
970
|
+
};
|
|
971
|
+
/**
|
|
972
|
+
* Get new access token, refresh token after successful login.
|
|
973
|
+
* @summary Login by tenant
|
|
974
|
+
* @param {AuthserviceApiLoginRequest} requestParameters Request parameters.
|
|
975
|
+
* @param {*} [options] Override http request option.
|
|
976
|
+
* @throws {RequiredError}
|
|
977
|
+
* @memberof AuthserviceApi
|
|
978
|
+
*/
|
|
979
|
+
AuthserviceApi.prototype.login = function (requestParameters, options) {
|
|
980
|
+
var _this = this;
|
|
981
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).login(requestParameters.loginRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
982
|
+
};
|
|
983
|
+
/**
|
|
984
|
+
* Get new access token, refresh token after successful login. This api also creates a tenant user if user does not exist
|
|
985
|
+
* @summary Login by SAML idp provider such as ADFS
|
|
986
|
+
* @param {AuthserviceApiLoginBySamlRequest} requestParameters Request parameters.
|
|
987
|
+
* @param {*} [options] Override http request option.
|
|
988
|
+
* @throws {RequiredError}
|
|
989
|
+
* @memberof AuthserviceApi
|
|
990
|
+
*/
|
|
991
|
+
AuthserviceApi.prototype.loginBySaml = function (requestParameters, options) {
|
|
992
|
+
var _this = this;
|
|
993
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).loginBySaml(requestParameters.loginBySamlRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
994
|
+
};
|
|
995
|
+
/**
|
|
996
|
+
* Sign tenant user out.
|
|
997
|
+
* @summary Logout tenant
|
|
998
|
+
* @param {AuthserviceApiLogoutRequest} requestParameters Request parameters.
|
|
999
|
+
* @param {*} [options] Override http request option.
|
|
1000
|
+
* @throws {RequiredError}
|
|
1001
|
+
* @memberof AuthserviceApi
|
|
1002
|
+
*/
|
|
1003
|
+
AuthserviceApi.prototype.logout = function (requestParameters, options) {
|
|
1004
|
+
var _this = this;
|
|
1005
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).logout(requestParameters.logoutRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1006
|
+
};
|
|
1007
|
+
/**
|
|
1008
|
+
* Get new access token, new refresh token.
|
|
1009
|
+
* @summary Refresh token by tenant
|
|
1010
|
+
* @param {AuthserviceApiRefreshTokenRequest} requestParameters Request parameters.
|
|
1011
|
+
* @param {*} [options] Override http request option.
|
|
1012
|
+
* @throws {RequiredError}
|
|
1013
|
+
* @memberof AuthserviceApi
|
|
1014
|
+
*/
|
|
1015
|
+
AuthserviceApi.prototype.refreshToken = function (requestParameters, options) {
|
|
1016
|
+
var _this = this;
|
|
1017
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).refreshToken(requestParameters.refreshTokenDto, requestParameters.cookie, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1018
|
+
};
|
|
1019
|
+
/**
|
|
1020
|
+
* Change tenant user\'s password using the token provided by the reset password endpoint.
|
|
1021
|
+
* @summary Change password by tenant
|
|
1022
|
+
* @param {AuthserviceApiResetPasswordRequest} requestParameters Request parameters.
|
|
1023
|
+
* @param {*} [options] Override http request option.
|
|
1024
|
+
* @throws {RequiredError}
|
|
1025
|
+
* @memberof AuthserviceApi
|
|
1026
|
+
*/
|
|
1027
|
+
AuthserviceApi.prototype.resetPassword = function (requestParameters, options) {
|
|
1028
|
+
var _this = this;
|
|
1029
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).resetPassword(requestParameters.resetPasswordRequestDto, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1030
|
+
};
|
|
1031
|
+
/**
|
|
1032
|
+
* Verify the invite sent to the tenant user via email.
|
|
1033
|
+
* @summary Verify tenant user\'s invite token
|
|
1034
|
+
* @param {AuthserviceApiVerifyInviteRequest} requestParameters Request parameters.
|
|
1035
|
+
* @param {*} [options] Override http request option.
|
|
1036
|
+
* @throws {RequiredError}
|
|
1037
|
+
* @memberof AuthserviceApi
|
|
1038
|
+
*/
|
|
1039
|
+
AuthserviceApi.prototype.verifyInvite = function (requestParameters, options) {
|
|
1040
|
+
var _this = this;
|
|
1041
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).verifyInvite(requestParameters.token, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1042
|
+
};
|
|
1043
|
+
/**
|
|
1044
|
+
* Verifies token and returns necessary data for signing up as an organization.
|
|
1045
|
+
* @summary Verify a organization\'s invitation token
|
|
1046
|
+
* @param {AuthserviceApiVerifyOrgInvitationRequest} requestParameters Request parameters.
|
|
1047
|
+
* @param {*} [options] Override http request option.
|
|
1048
|
+
* @throws {RequiredError}
|
|
1049
|
+
* @memberof AuthserviceApi
|
|
1050
|
+
*/
|
|
1051
|
+
AuthserviceApi.prototype.verifyOrgInvitation = function (requestParameters, options) {
|
|
1052
|
+
var _this = this;
|
|
1053
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).verifyOrgInvitation(requestParameters.invitationToken, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1054
|
+
};
|
|
1055
|
+
/**
|
|
1056
|
+
* Verify the reset password token that is sent by calling the \'forgot password\' endpoint.
|
|
1057
|
+
* @summary Verify tenant reset password token
|
|
1058
|
+
* @param {AuthserviceApiVerifyResetPasswordTokenRequest} requestParameters Request parameters.
|
|
1059
|
+
* @param {*} [options] Override http request option.
|
|
1060
|
+
* @throws {RequiredError}
|
|
1061
|
+
* @memberof AuthserviceApi
|
|
1062
|
+
*/
|
|
1063
|
+
AuthserviceApi.prototype.verifyResetPasswordToken = function (requestParameters, options) {
|
|
1064
|
+
var _this = this;
|
|
1065
|
+
return (0, exports.AuthserviceApiFp)(this.configuration).verifyResetPasswordToken(requestParameters.resetToken, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
1066
|
+
};
|
|
1067
|
+
return AuthserviceApi;
|
|
1068
|
+
}(base_1.BaseAPI));
|
|
1069
|
+
exports.AuthserviceApi = AuthserviceApi;
|