@cherryin/api-client 0.0.3 → 0.0.5
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 +20 -0
- package/README.md +29 -3
- package/api.ts +750 -1
- package/dist/api.d.ts +457 -0
- package/dist/api.js +481 -3
- package/dist/esm/api.d.ts +457 -0
- package/dist/esm/api.js +475 -1
- package/docs/Auth2UserServiceApi.md +58 -0
- package/docs/AuthOAuth2CallbackResponse.md +32 -0
- package/docs/BatchUpdateSessionsRequest.md +24 -0
- package/docs/BatchUpdateSessionsResponse.md +24 -0
- package/docs/GetUserDetailResponse.md +24 -0
- package/docs/ListUsersRequest.md +36 -0
- package/docs/ListUsersResponse.md +30 -0
- package/docs/ProviderAdminServiceApi.md +1 -1
- package/docs/SetUserRoleRequest.md +22 -0
- package/docs/SetUserRoleResponse.md +24 -0
- package/docs/SetUserStatusRequest.md +22 -0
- package/docs/SetUserStatusResponse.md +26 -0
- package/docs/UpdateUserInfoRequest.md +26 -0
- package/docs/UpdateUserInfoResponse.md +24 -0
- package/docs/UserManageAPIKey.md +38 -0
- package/docs/UserManageAdminServiceApi.md +330 -0
- package/docs/UserManageAuthMethod.md +32 -0
- package/docs/UserManageBalance.md +32 -0
- package/docs/UserManageDetail.md +47 -0
- package/docs/UserManageItem.md +39 -0
- package/docs/UserManageSession.md +34 -0
- package/docs/UserManageSettings.md +20 -0
- package/package.json +1 -1
package/dist/api.js
CHANGED
|
@@ -22,8 +22,8 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
22
22
|
});
|
|
23
23
|
};
|
|
24
24
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
-
exports.
|
|
26
|
-
exports.UserPoralServiceApi = exports.UserPoralServiceApiFactory = void 0;
|
|
25
|
+
exports.UserPayServiceApiFp = exports.UserPayServiceApiAxiosParamCreator = exports.UserModelServiceApi = exports.UserModelServiceApiFactory = exports.UserModelServiceApiFp = exports.UserModelServiceApiAxiosParamCreator = exports.UserManageAdminServiceApi = exports.UserManageAdminServiceApiFactory = exports.UserManageAdminServiceApiFp = exports.UserManageAdminServiceApiAxiosParamCreator = exports.UserLabelServiceApi = exports.UserLabelServiceApiFactory = exports.UserLabelServiceApiFp = exports.UserLabelServiceApiAxiosParamCreator = exports.UserBalanceServiceApi = exports.UserBalanceServiceApiFactory = exports.UserBalanceServiceApiFp = exports.UserBalanceServiceApiAxiosParamCreator = exports.UserAPIKeyServiceApi = exports.UserAPIKeyServiceApiFactory = exports.UserAPIKeyServiceApiFp = exports.UserAPIKeyServiceApiAxiosParamCreator = exports.RemoteConfigAdminServiceApi = exports.RemoteConfigAdminServiceApiFactory = exports.RemoteConfigAdminServiceApiFp = exports.RemoteConfigAdminServiceApiAxiosParamCreator = exports.ProviderModelAdminServiceApi = exports.ProviderModelAdminServiceApiFactory = exports.ProviderModelAdminServiceApiFp = exports.ProviderModelAdminServiceApiAxiosParamCreator = exports.ProviderAdminServiceApi = exports.ProviderAdminServiceApiFactory = exports.ProviderAdminServiceApiFp = exports.ProviderAdminServiceApiAxiosParamCreator = exports.DiscountAdminServiceApi = exports.DiscountAdminServiceApiFactory = exports.DiscountAdminServiceApiFp = exports.DiscountAdminServiceApiAxiosParamCreator = exports.Auth2UserServiceApi = exports.Auth2UserServiceApiFactory = exports.Auth2UserServiceApiFp = exports.Auth2UserServiceApiAxiosParamCreator = exports.Auth2AdminServiceApi = exports.Auth2AdminServiceApiFactory = exports.Auth2AdminServiceApiFp = exports.Auth2AdminServiceApiAxiosParamCreator = exports.AIModelAdminServiceApi = exports.AIModelAdminServiceApiFactory = exports.AIModelAdminServiceApiFp = exports.AIModelAdminServiceApiAxiosParamCreator = void 0;
|
|
26
|
+
exports.UserPoralServiceApi = exports.UserPoralServiceApiFactory = exports.UserPoralServiceApiFp = exports.UserPoralServiceApiAxiosParamCreator = exports.UserPayServiceApi = exports.UserPayServiceApiFactory = void 0;
|
|
27
27
|
const axios_1 = require("axios");
|
|
28
28
|
// Some imports not used depending on template conditions
|
|
29
29
|
// @ts-ignore
|
|
@@ -1410,6 +1410,42 @@ const Auth2UserServiceApiAxiosParamCreator = function (configuration) {
|
|
|
1410
1410
|
options: localVarRequestOptions,
|
|
1411
1411
|
};
|
|
1412
1412
|
}),
|
|
1413
|
+
/**
|
|
1414
|
+
*
|
|
1415
|
+
* @param {string} platform
|
|
1416
|
+
* @param {string} [code]
|
|
1417
|
+
* @param {string} [state]
|
|
1418
|
+
* @param {*} [options] Override http request option.
|
|
1419
|
+
* @throws {RequiredError}
|
|
1420
|
+
*/
|
|
1421
|
+
auth2UserServiceAuthOAuth2Callback: (platform_1, code_1, state_1, ...args_1) => __awaiter(this, [platform_1, code_1, state_1, ...args_1], void 0, function* (platform, code, state, options = {}) {
|
|
1422
|
+
// verify required parameter 'platform' is not null or undefined
|
|
1423
|
+
(0, common_1.assertParamExists)('auth2UserServiceAuthOAuth2Callback', 'platform', platform);
|
|
1424
|
+
const localVarPath = `/oauth2/{platform}/callback`
|
|
1425
|
+
.replace(`{${"platform"}}`, encodeURIComponent(String(platform)));
|
|
1426
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
1427
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
1428
|
+
let baseOptions;
|
|
1429
|
+
if (configuration) {
|
|
1430
|
+
baseOptions = configuration.baseOptions;
|
|
1431
|
+
}
|
|
1432
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
1433
|
+
const localVarHeaderParameter = {};
|
|
1434
|
+
const localVarQueryParameter = {};
|
|
1435
|
+
if (code !== undefined) {
|
|
1436
|
+
localVarQueryParameter['code'] = code;
|
|
1437
|
+
}
|
|
1438
|
+
if (state !== undefined) {
|
|
1439
|
+
localVarQueryParameter['state'] = state;
|
|
1440
|
+
}
|
|
1441
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
1442
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
1443
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
1444
|
+
return {
|
|
1445
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
1446
|
+
options: localVarRequestOptions,
|
|
1447
|
+
};
|
|
1448
|
+
}),
|
|
1413
1449
|
/**
|
|
1414
1450
|
* ============ Token 管理 ============
|
|
1415
1451
|
* @param {AuthRefreshTokenRequest} authRefreshTokenRequest
|
|
@@ -1963,6 +1999,23 @@ const Auth2UserServiceApiFp = function (configuration) {
|
|
|
1963
1999
|
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
1964
2000
|
});
|
|
1965
2001
|
},
|
|
2002
|
+
/**
|
|
2003
|
+
*
|
|
2004
|
+
* @param {string} platform
|
|
2005
|
+
* @param {string} [code]
|
|
2006
|
+
* @param {string} [state]
|
|
2007
|
+
* @param {*} [options] Override http request option.
|
|
2008
|
+
* @throws {RequiredError}
|
|
2009
|
+
*/
|
|
2010
|
+
auth2UserServiceAuthOAuth2Callback(platform, code, state, options) {
|
|
2011
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2012
|
+
var _a, _b, _c;
|
|
2013
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.auth2UserServiceAuthOAuth2Callback(platform, code, state, options);
|
|
2014
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
2015
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['Auth2UserServiceApi.auth2UserServiceAuthOAuth2Callback']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
2016
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
2017
|
+
});
|
|
2018
|
+
},
|
|
1966
2019
|
/**
|
|
1967
2020
|
* ============ Token 管理 ============
|
|
1968
2021
|
* @param {AuthRefreshTokenRequest} authRefreshTokenRequest
|
|
@@ -2261,6 +2314,17 @@ const Auth2UserServiceApiFactory = function (configuration, basePath, axios) {
|
|
|
2261
2314
|
auth2UserServiceAuthListSessions(options) {
|
|
2262
2315
|
return localVarFp.auth2UserServiceAuthListSessions(options).then((request) => request(axios, basePath));
|
|
2263
2316
|
},
|
|
2317
|
+
/**
|
|
2318
|
+
*
|
|
2319
|
+
* @param {string} platform
|
|
2320
|
+
* @param {string} [code]
|
|
2321
|
+
* @param {string} [state]
|
|
2322
|
+
* @param {*} [options] Override http request option.
|
|
2323
|
+
* @throws {RequiredError}
|
|
2324
|
+
*/
|
|
2325
|
+
auth2UserServiceAuthOAuth2Callback(platform, code, state, options) {
|
|
2326
|
+
return localVarFp.auth2UserServiceAuthOAuth2Callback(platform, code, state, options).then((request) => request(axios, basePath));
|
|
2327
|
+
},
|
|
2264
2328
|
/**
|
|
2265
2329
|
* ============ Token 管理 ============
|
|
2266
2330
|
* @param {AuthRefreshTokenRequest} authRefreshTokenRequest
|
|
@@ -2473,6 +2537,17 @@ class Auth2UserServiceApi extends base_1.BaseAPI {
|
|
|
2473
2537
|
auth2UserServiceAuthListSessions(options) {
|
|
2474
2538
|
return (0, exports.Auth2UserServiceApiFp)(this.configuration).auth2UserServiceAuthListSessions(options).then((request) => request(this.axios, this.basePath));
|
|
2475
2539
|
}
|
|
2540
|
+
/**
|
|
2541
|
+
*
|
|
2542
|
+
* @param {string} platform
|
|
2543
|
+
* @param {string} [code]
|
|
2544
|
+
* @param {string} [state]
|
|
2545
|
+
* @param {*} [options] Override http request option.
|
|
2546
|
+
* @throws {RequiredError}
|
|
2547
|
+
*/
|
|
2548
|
+
auth2UserServiceAuthOAuth2Callback(platform, code, state, options) {
|
|
2549
|
+
return (0, exports.Auth2UserServiceApiFp)(this.configuration).auth2UserServiceAuthOAuth2Callback(platform, code, state, options).then((request) => request(this.axios, this.basePath));
|
|
2550
|
+
}
|
|
2476
2551
|
/**
|
|
2477
2552
|
* ============ Token 管理 ============
|
|
2478
2553
|
* @param {AuthRefreshTokenRequest} authRefreshTokenRequest
|
|
@@ -3007,7 +3082,7 @@ const ProviderAdminServiceApiAxiosParamCreator = function (configuration) {
|
|
|
3007
3082
|
if (configuration) {
|
|
3008
3083
|
baseOptions = configuration.baseOptions;
|
|
3009
3084
|
}
|
|
3010
|
-
const localVarRequestOptions = Object.assign(Object.assign({ method: '
|
|
3085
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'DELETE' }, baseOptions), options);
|
|
3011
3086
|
const localVarHeaderParameter = {};
|
|
3012
3087
|
const localVarQueryParameter = {};
|
|
3013
3088
|
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
@@ -5270,6 +5345,409 @@ class UserLabelServiceApi extends base_1.BaseAPI {
|
|
|
5270
5345
|
}
|
|
5271
5346
|
}
|
|
5272
5347
|
exports.UserLabelServiceApi = UserLabelServiceApi;
|
|
5348
|
+
/**
|
|
5349
|
+
* UserManageAdminServiceApi - axios parameter creator
|
|
5350
|
+
*/
|
|
5351
|
+
const UserManageAdminServiceApiAxiosParamCreator = function (configuration) {
|
|
5352
|
+
return {
|
|
5353
|
+
/**
|
|
5354
|
+
* 批量管理 Session
|
|
5355
|
+
* @param {BatchUpdateSessionsRequest} batchUpdateSessionsRequest
|
|
5356
|
+
* @param {*} [options] Override http request option.
|
|
5357
|
+
* @throws {RequiredError}
|
|
5358
|
+
*/
|
|
5359
|
+
userManageAdminServiceBatchUpdateSessions: (batchUpdateSessionsRequest_1, ...args_1) => __awaiter(this, [batchUpdateSessionsRequest_1, ...args_1], void 0, function* (batchUpdateSessionsRequest, options = {}) {
|
|
5360
|
+
// verify required parameter 'batchUpdateSessionsRequest' is not null or undefined
|
|
5361
|
+
(0, common_1.assertParamExists)('userManageAdminServiceBatchUpdateSessions', 'batchUpdateSessionsRequest', batchUpdateSessionsRequest);
|
|
5362
|
+
const localVarPath = `/admin/users/manage/sessions`;
|
|
5363
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5364
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5365
|
+
let baseOptions;
|
|
5366
|
+
if (configuration) {
|
|
5367
|
+
baseOptions = configuration.baseOptions;
|
|
5368
|
+
}
|
|
5369
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5370
|
+
const localVarHeaderParameter = {};
|
|
5371
|
+
const localVarQueryParameter = {};
|
|
5372
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5373
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5374
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5375
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5376
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(batchUpdateSessionsRequest, localVarRequestOptions, configuration);
|
|
5377
|
+
return {
|
|
5378
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5379
|
+
options: localVarRequestOptions,
|
|
5380
|
+
};
|
|
5381
|
+
}),
|
|
5382
|
+
/**
|
|
5383
|
+
* 用户详情
|
|
5384
|
+
* @param {string} [uid] @gotags: form:\"uid\" binding:\"uid\"
|
|
5385
|
+
* @param {*} [options] Override http request option.
|
|
5386
|
+
* @throws {RequiredError}
|
|
5387
|
+
*/
|
|
5388
|
+
userManageAdminServiceGetUserDetail: (uid_1, ...args_1) => __awaiter(this, [uid_1, ...args_1], void 0, function* (uid, options = {}) {
|
|
5389
|
+
const localVarPath = `/admin/users/detail`;
|
|
5390
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5391
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5392
|
+
let baseOptions;
|
|
5393
|
+
if (configuration) {
|
|
5394
|
+
baseOptions = configuration.baseOptions;
|
|
5395
|
+
}
|
|
5396
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
5397
|
+
const localVarHeaderParameter = {};
|
|
5398
|
+
const localVarQueryParameter = {};
|
|
5399
|
+
if (uid !== undefined) {
|
|
5400
|
+
localVarQueryParameter['uid'] = uid;
|
|
5401
|
+
}
|
|
5402
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5403
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5404
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5405
|
+
return {
|
|
5406
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5407
|
+
options: localVarRequestOptions,
|
|
5408
|
+
};
|
|
5409
|
+
}),
|
|
5410
|
+
/**
|
|
5411
|
+
* 用户列表(分页查询)
|
|
5412
|
+
* @param {ListUsersRequest} listUsersRequest
|
|
5413
|
+
* @param {*} [options] Override http request option.
|
|
5414
|
+
* @throws {RequiredError}
|
|
5415
|
+
*/
|
|
5416
|
+
userManageAdminServiceListUsers: (listUsersRequest_1, ...args_1) => __awaiter(this, [listUsersRequest_1, ...args_1], void 0, function* (listUsersRequest, options = {}) {
|
|
5417
|
+
// verify required parameter 'listUsersRequest' is not null or undefined
|
|
5418
|
+
(0, common_1.assertParamExists)('userManageAdminServiceListUsers', 'listUsersRequest', listUsersRequest);
|
|
5419
|
+
const localVarPath = `/admin/users/list`;
|
|
5420
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5421
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5422
|
+
let baseOptions;
|
|
5423
|
+
if (configuration) {
|
|
5424
|
+
baseOptions = configuration.baseOptions;
|
|
5425
|
+
}
|
|
5426
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5427
|
+
const localVarHeaderParameter = {};
|
|
5428
|
+
const localVarQueryParameter = {};
|
|
5429
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5430
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5431
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5432
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5433
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(listUsersRequest, localVarRequestOptions, configuration);
|
|
5434
|
+
return {
|
|
5435
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5436
|
+
options: localVarRequestOptions,
|
|
5437
|
+
};
|
|
5438
|
+
}),
|
|
5439
|
+
/**
|
|
5440
|
+
* 设置用户角色
|
|
5441
|
+
* @param {SetUserRoleRequest} setUserRoleRequest
|
|
5442
|
+
* @param {*} [options] Override http request option.
|
|
5443
|
+
* @throws {RequiredError}
|
|
5444
|
+
*/
|
|
5445
|
+
userManageAdminServiceSetUserRole: (setUserRoleRequest_1, ...args_1) => __awaiter(this, [setUserRoleRequest_1, ...args_1], void 0, function* (setUserRoleRequest, options = {}) {
|
|
5446
|
+
// verify required parameter 'setUserRoleRequest' is not null or undefined
|
|
5447
|
+
(0, common_1.assertParamExists)('userManageAdminServiceSetUserRole', 'setUserRoleRequest', setUserRoleRequest);
|
|
5448
|
+
const localVarPath = `/admin/users/manage/role`;
|
|
5449
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5450
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5451
|
+
let baseOptions;
|
|
5452
|
+
if (configuration) {
|
|
5453
|
+
baseOptions = configuration.baseOptions;
|
|
5454
|
+
}
|
|
5455
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5456
|
+
const localVarHeaderParameter = {};
|
|
5457
|
+
const localVarQueryParameter = {};
|
|
5458
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5459
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5460
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5461
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5462
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(setUserRoleRequest, localVarRequestOptions, configuration);
|
|
5463
|
+
return {
|
|
5464
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5465
|
+
options: localVarRequestOptions,
|
|
5466
|
+
};
|
|
5467
|
+
}),
|
|
5468
|
+
/**
|
|
5469
|
+
* 设置用户状态(启用/禁用)
|
|
5470
|
+
* @param {SetUserStatusRequest} setUserStatusRequest
|
|
5471
|
+
* @param {*} [options] Override http request option.
|
|
5472
|
+
* @throws {RequiredError}
|
|
5473
|
+
*/
|
|
5474
|
+
userManageAdminServiceSetUserStatus: (setUserStatusRequest_1, ...args_1) => __awaiter(this, [setUserStatusRequest_1, ...args_1], void 0, function* (setUserStatusRequest, options = {}) {
|
|
5475
|
+
// verify required parameter 'setUserStatusRequest' is not null or undefined
|
|
5476
|
+
(0, common_1.assertParamExists)('userManageAdminServiceSetUserStatus', 'setUserStatusRequest', setUserStatusRequest);
|
|
5477
|
+
const localVarPath = `/admin/users/manage/status`;
|
|
5478
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5479
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5480
|
+
let baseOptions;
|
|
5481
|
+
if (configuration) {
|
|
5482
|
+
baseOptions = configuration.baseOptions;
|
|
5483
|
+
}
|
|
5484
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5485
|
+
const localVarHeaderParameter = {};
|
|
5486
|
+
const localVarQueryParameter = {};
|
|
5487
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5488
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5489
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5490
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5491
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(setUserStatusRequest, localVarRequestOptions, configuration);
|
|
5492
|
+
return {
|
|
5493
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5494
|
+
options: localVarRequestOptions,
|
|
5495
|
+
};
|
|
5496
|
+
}),
|
|
5497
|
+
/**
|
|
5498
|
+
* 更新用户信息
|
|
5499
|
+
* @param {UpdateUserInfoRequest} updateUserInfoRequest
|
|
5500
|
+
* @param {*} [options] Override http request option.
|
|
5501
|
+
* @throws {RequiredError}
|
|
5502
|
+
*/
|
|
5503
|
+
userManageAdminServiceUpdateUserInfo: (updateUserInfoRequest_1, ...args_1) => __awaiter(this, [updateUserInfoRequest_1, ...args_1], void 0, function* (updateUserInfoRequest, options = {}) {
|
|
5504
|
+
// verify required parameter 'updateUserInfoRequest' is not null or undefined
|
|
5505
|
+
(0, common_1.assertParamExists)('userManageAdminServiceUpdateUserInfo', 'updateUserInfoRequest', updateUserInfoRequest);
|
|
5506
|
+
const localVarPath = `/admin/users/manage/info`;
|
|
5507
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
5508
|
+
const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
5509
|
+
let baseOptions;
|
|
5510
|
+
if (configuration) {
|
|
5511
|
+
baseOptions = configuration.baseOptions;
|
|
5512
|
+
}
|
|
5513
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
5514
|
+
const localVarHeaderParameter = {};
|
|
5515
|
+
const localVarQueryParameter = {};
|
|
5516
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
5517
|
+
(0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
|
|
5518
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
5519
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
5520
|
+
localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(updateUserInfoRequest, localVarRequestOptions, configuration);
|
|
5521
|
+
return {
|
|
5522
|
+
url: (0, common_1.toPathString)(localVarUrlObj),
|
|
5523
|
+
options: localVarRequestOptions,
|
|
5524
|
+
};
|
|
5525
|
+
}),
|
|
5526
|
+
};
|
|
5527
|
+
};
|
|
5528
|
+
exports.UserManageAdminServiceApiAxiosParamCreator = UserManageAdminServiceApiAxiosParamCreator;
|
|
5529
|
+
/**
|
|
5530
|
+
* UserManageAdminServiceApi - functional programming interface
|
|
5531
|
+
*/
|
|
5532
|
+
const UserManageAdminServiceApiFp = function (configuration) {
|
|
5533
|
+
const localVarAxiosParamCreator = (0, exports.UserManageAdminServiceApiAxiosParamCreator)(configuration);
|
|
5534
|
+
return {
|
|
5535
|
+
/**
|
|
5536
|
+
* 批量管理 Session
|
|
5537
|
+
* @param {BatchUpdateSessionsRequest} batchUpdateSessionsRequest
|
|
5538
|
+
* @param {*} [options] Override http request option.
|
|
5539
|
+
* @throws {RequiredError}
|
|
5540
|
+
*/
|
|
5541
|
+
userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options) {
|
|
5542
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5543
|
+
var _a, _b, _c;
|
|
5544
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options);
|
|
5545
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5546
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceBatchUpdateSessions']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5547
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5548
|
+
});
|
|
5549
|
+
},
|
|
5550
|
+
/**
|
|
5551
|
+
* 用户详情
|
|
5552
|
+
* @param {string} [uid] @gotags: form:\"uid\" binding:\"uid\"
|
|
5553
|
+
* @param {*} [options] Override http request option.
|
|
5554
|
+
* @throws {RequiredError}
|
|
5555
|
+
*/
|
|
5556
|
+
userManageAdminServiceGetUserDetail(uid, options) {
|
|
5557
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5558
|
+
var _a, _b, _c;
|
|
5559
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceGetUserDetail(uid, options);
|
|
5560
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5561
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceGetUserDetail']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5562
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5563
|
+
});
|
|
5564
|
+
},
|
|
5565
|
+
/**
|
|
5566
|
+
* 用户列表(分页查询)
|
|
5567
|
+
* @param {ListUsersRequest} listUsersRequest
|
|
5568
|
+
* @param {*} [options] Override http request option.
|
|
5569
|
+
* @throws {RequiredError}
|
|
5570
|
+
*/
|
|
5571
|
+
userManageAdminServiceListUsers(listUsersRequest, options) {
|
|
5572
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5573
|
+
var _a, _b, _c;
|
|
5574
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceListUsers(listUsersRequest, options);
|
|
5575
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5576
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceListUsers']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5577
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5578
|
+
});
|
|
5579
|
+
},
|
|
5580
|
+
/**
|
|
5581
|
+
* 设置用户角色
|
|
5582
|
+
* @param {SetUserRoleRequest} setUserRoleRequest
|
|
5583
|
+
* @param {*} [options] Override http request option.
|
|
5584
|
+
* @throws {RequiredError}
|
|
5585
|
+
*/
|
|
5586
|
+
userManageAdminServiceSetUserRole(setUserRoleRequest, options) {
|
|
5587
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5588
|
+
var _a, _b, _c;
|
|
5589
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceSetUserRole(setUserRoleRequest, options);
|
|
5590
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5591
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceSetUserRole']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5592
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5593
|
+
});
|
|
5594
|
+
},
|
|
5595
|
+
/**
|
|
5596
|
+
* 设置用户状态(启用/禁用)
|
|
5597
|
+
* @param {SetUserStatusRequest} setUserStatusRequest
|
|
5598
|
+
* @param {*} [options] Override http request option.
|
|
5599
|
+
* @throws {RequiredError}
|
|
5600
|
+
*/
|
|
5601
|
+
userManageAdminServiceSetUserStatus(setUserStatusRequest, options) {
|
|
5602
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5603
|
+
var _a, _b, _c;
|
|
5604
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceSetUserStatus(setUserStatusRequest, options);
|
|
5605
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5606
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceSetUserStatus']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5607
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5608
|
+
});
|
|
5609
|
+
},
|
|
5610
|
+
/**
|
|
5611
|
+
* 更新用户信息
|
|
5612
|
+
* @param {UpdateUserInfoRequest} updateUserInfoRequest
|
|
5613
|
+
* @param {*} [options] Override http request option.
|
|
5614
|
+
* @throws {RequiredError}
|
|
5615
|
+
*/
|
|
5616
|
+
userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options) {
|
|
5617
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
5618
|
+
var _a, _b, _c;
|
|
5619
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options);
|
|
5620
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
5621
|
+
const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['UserManageAdminServiceApi.userManageAdminServiceUpdateUserInfo']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
5622
|
+
return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
5623
|
+
});
|
|
5624
|
+
},
|
|
5625
|
+
};
|
|
5626
|
+
};
|
|
5627
|
+
exports.UserManageAdminServiceApiFp = UserManageAdminServiceApiFp;
|
|
5628
|
+
/**
|
|
5629
|
+
* UserManageAdminServiceApi - factory interface
|
|
5630
|
+
*/
|
|
5631
|
+
const UserManageAdminServiceApiFactory = function (configuration, basePath, axios) {
|
|
5632
|
+
const localVarFp = (0, exports.UserManageAdminServiceApiFp)(configuration);
|
|
5633
|
+
return {
|
|
5634
|
+
/**
|
|
5635
|
+
* 批量管理 Session
|
|
5636
|
+
* @param {BatchUpdateSessionsRequest} batchUpdateSessionsRequest
|
|
5637
|
+
* @param {*} [options] Override http request option.
|
|
5638
|
+
* @throws {RequiredError}
|
|
5639
|
+
*/
|
|
5640
|
+
userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options) {
|
|
5641
|
+
return localVarFp.userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options).then((request) => request(axios, basePath));
|
|
5642
|
+
},
|
|
5643
|
+
/**
|
|
5644
|
+
* 用户详情
|
|
5645
|
+
* @param {string} [uid] @gotags: form:\"uid\" binding:\"uid\"
|
|
5646
|
+
* @param {*} [options] Override http request option.
|
|
5647
|
+
* @throws {RequiredError}
|
|
5648
|
+
*/
|
|
5649
|
+
userManageAdminServiceGetUserDetail(uid, options) {
|
|
5650
|
+
return localVarFp.userManageAdminServiceGetUserDetail(uid, options).then((request) => request(axios, basePath));
|
|
5651
|
+
},
|
|
5652
|
+
/**
|
|
5653
|
+
* 用户列表(分页查询)
|
|
5654
|
+
* @param {ListUsersRequest} listUsersRequest
|
|
5655
|
+
* @param {*} [options] Override http request option.
|
|
5656
|
+
* @throws {RequiredError}
|
|
5657
|
+
*/
|
|
5658
|
+
userManageAdminServiceListUsers(listUsersRequest, options) {
|
|
5659
|
+
return localVarFp.userManageAdminServiceListUsers(listUsersRequest, options).then((request) => request(axios, basePath));
|
|
5660
|
+
},
|
|
5661
|
+
/**
|
|
5662
|
+
* 设置用户角色
|
|
5663
|
+
* @param {SetUserRoleRequest} setUserRoleRequest
|
|
5664
|
+
* @param {*} [options] Override http request option.
|
|
5665
|
+
* @throws {RequiredError}
|
|
5666
|
+
*/
|
|
5667
|
+
userManageAdminServiceSetUserRole(setUserRoleRequest, options) {
|
|
5668
|
+
return localVarFp.userManageAdminServiceSetUserRole(setUserRoleRequest, options).then((request) => request(axios, basePath));
|
|
5669
|
+
},
|
|
5670
|
+
/**
|
|
5671
|
+
* 设置用户状态(启用/禁用)
|
|
5672
|
+
* @param {SetUserStatusRequest} setUserStatusRequest
|
|
5673
|
+
* @param {*} [options] Override http request option.
|
|
5674
|
+
* @throws {RequiredError}
|
|
5675
|
+
*/
|
|
5676
|
+
userManageAdminServiceSetUserStatus(setUserStatusRequest, options) {
|
|
5677
|
+
return localVarFp.userManageAdminServiceSetUserStatus(setUserStatusRequest, options).then((request) => request(axios, basePath));
|
|
5678
|
+
},
|
|
5679
|
+
/**
|
|
5680
|
+
* 更新用户信息
|
|
5681
|
+
* @param {UpdateUserInfoRequest} updateUserInfoRequest
|
|
5682
|
+
* @param {*} [options] Override http request option.
|
|
5683
|
+
* @throws {RequiredError}
|
|
5684
|
+
*/
|
|
5685
|
+
userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options) {
|
|
5686
|
+
return localVarFp.userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options).then((request) => request(axios, basePath));
|
|
5687
|
+
},
|
|
5688
|
+
};
|
|
5689
|
+
};
|
|
5690
|
+
exports.UserManageAdminServiceApiFactory = UserManageAdminServiceApiFactory;
|
|
5691
|
+
/**
|
|
5692
|
+
* UserManageAdminServiceApi - object-oriented interface
|
|
5693
|
+
*/
|
|
5694
|
+
class UserManageAdminServiceApi extends base_1.BaseAPI {
|
|
5695
|
+
/**
|
|
5696
|
+
* 批量管理 Session
|
|
5697
|
+
* @param {BatchUpdateSessionsRequest} batchUpdateSessionsRequest
|
|
5698
|
+
* @param {*} [options] Override http request option.
|
|
5699
|
+
* @throws {RequiredError}
|
|
5700
|
+
*/
|
|
5701
|
+
userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options) {
|
|
5702
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceBatchUpdateSessions(batchUpdateSessionsRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5703
|
+
}
|
|
5704
|
+
/**
|
|
5705
|
+
* 用户详情
|
|
5706
|
+
* @param {string} [uid] @gotags: form:\"uid\" binding:\"uid\"
|
|
5707
|
+
* @param {*} [options] Override http request option.
|
|
5708
|
+
* @throws {RequiredError}
|
|
5709
|
+
*/
|
|
5710
|
+
userManageAdminServiceGetUserDetail(uid, options) {
|
|
5711
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceGetUserDetail(uid, options).then((request) => request(this.axios, this.basePath));
|
|
5712
|
+
}
|
|
5713
|
+
/**
|
|
5714
|
+
* 用户列表(分页查询)
|
|
5715
|
+
* @param {ListUsersRequest} listUsersRequest
|
|
5716
|
+
* @param {*} [options] Override http request option.
|
|
5717
|
+
* @throws {RequiredError}
|
|
5718
|
+
*/
|
|
5719
|
+
userManageAdminServiceListUsers(listUsersRequest, options) {
|
|
5720
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceListUsers(listUsersRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5721
|
+
}
|
|
5722
|
+
/**
|
|
5723
|
+
* 设置用户角色
|
|
5724
|
+
* @param {SetUserRoleRequest} setUserRoleRequest
|
|
5725
|
+
* @param {*} [options] Override http request option.
|
|
5726
|
+
* @throws {RequiredError}
|
|
5727
|
+
*/
|
|
5728
|
+
userManageAdminServiceSetUserRole(setUserRoleRequest, options) {
|
|
5729
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceSetUserRole(setUserRoleRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5730
|
+
}
|
|
5731
|
+
/**
|
|
5732
|
+
* 设置用户状态(启用/禁用)
|
|
5733
|
+
* @param {SetUserStatusRequest} setUserStatusRequest
|
|
5734
|
+
* @param {*} [options] Override http request option.
|
|
5735
|
+
* @throws {RequiredError}
|
|
5736
|
+
*/
|
|
5737
|
+
userManageAdminServiceSetUserStatus(setUserStatusRequest, options) {
|
|
5738
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceSetUserStatus(setUserStatusRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5739
|
+
}
|
|
5740
|
+
/**
|
|
5741
|
+
* 更新用户信息
|
|
5742
|
+
* @param {UpdateUserInfoRequest} updateUserInfoRequest
|
|
5743
|
+
* @param {*} [options] Override http request option.
|
|
5744
|
+
* @throws {RequiredError}
|
|
5745
|
+
*/
|
|
5746
|
+
userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options) {
|
|
5747
|
+
return (0, exports.UserManageAdminServiceApiFp)(this.configuration).userManageAdminServiceUpdateUserInfo(updateUserInfoRequest, options).then((request) => request(this.axios, this.basePath));
|
|
5748
|
+
}
|
|
5749
|
+
}
|
|
5750
|
+
exports.UserManageAdminServiceApi = UserManageAdminServiceApi;
|
|
5273
5751
|
/**
|
|
5274
5752
|
* UserModelServiceApi - axios parameter creator
|
|
5275
5753
|
*/
|