@rebornteam/reborn-api 2.6.0 → 2.6.4

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.
Files changed (47) hide show
  1. package/.openapi-generator/FILES +11 -4
  2. package/README.md +16 -8
  3. package/api.ts +463 -262
  4. package/base.ts +1 -1
  5. package/common.ts +1 -1
  6. package/configuration.ts +1 -1
  7. package/dist/api.d.ts +329 -180
  8. package/dist/api.js +231 -146
  9. package/dist/base.d.ts +1 -1
  10. package/dist/base.js +1 -1
  11. package/dist/common.d.ts +1 -1
  12. package/dist/common.js +1 -1
  13. package/dist/configuration.d.ts +1 -1
  14. package/dist/configuration.js +1 -1
  15. package/dist/esm/api.d.ts +329 -180
  16. package/dist/esm/api.js +230 -145
  17. package/dist/esm/base.d.ts +1 -1
  18. package/dist/esm/base.js +1 -1
  19. package/dist/esm/common.d.ts +1 -1
  20. package/dist/esm/common.js +1 -1
  21. package/dist/esm/configuration.d.ts +1 -1
  22. package/dist/esm/configuration.js +1 -1
  23. package/dist/esm/index.d.ts +1 -1
  24. package/dist/esm/index.js +1 -1
  25. package/dist/index.d.ts +1 -1
  26. package/dist/index.js +1 -1
  27. package/docs/AdminApplyPunishmentRequest.md +33 -0
  28. package/docs/AdminApplyPunishmentResponse.md +21 -0
  29. package/docs/AdminApplyPunishmentResult.md +33 -0
  30. package/docs/AdminCreatePunishmentDraftRequest.md +31 -0
  31. package/docs/AdminIpSearchResult.md +23 -0
  32. package/docs/AdminPagedPunishmentResponse.md +1 -1
  33. package/docs/AdminPlayerSearchResult.md +23 -0
  34. package/docs/AdminPunishmentDraftResponse.md +21 -0
  35. package/docs/AdminPunishmentEvaluation.md +39 -0
  36. package/docs/AdminPunishmentListItem.md +42 -0
  37. package/docs/AdminPunishmentSearchResponse.md +25 -0
  38. package/docs/AdminPunishmentTarget.md +23 -0
  39. package/docs/AdminPunishmentsApi.md +168 -2
  40. package/docs/PunishmentApi.md +0 -106
  41. package/docs/PunishmentGetPunishmentResponse.md +5 -3
  42. package/index.ts +1 -1
  43. package/package.json +1 -1
  44. package/docs/ApplyPunishmentRequest.md +0 -31
  45. package/docs/ApplyPunishmentResponse.md +0 -33
  46. package/docs/CreatePunishmentDraftRequest.md +0 -29
  47. package/docs/PunishmentDraftResponse.md +0 -39
package/dist/api.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Reborn API
6
6
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
7
7
  *
8
- * The version of the OpenAPI document: 2.6.0
8
+ * The version of the OpenAPI document: 2.6.4
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -22,13 +22,27 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
22
22
  });
23
23
  };
24
24
  Object.defineProperty(exports, "__esModule", { value: true });
25
- exports.PunishmentApi = exports.PunishmentApiFactory = exports.PunishmentApiFp = exports.PunishmentApiAxiosParamCreator = exports.PlayerApi = exports.PlayerApiFactory = exports.PlayerApiFp = exports.PlayerApiAxiosParamCreator = exports.DefaultApi = exports.DefaultApiFactory = exports.DefaultApiFp = exports.DefaultApiAxiosParamCreator = exports.ConnectionApi = exports.ConnectionApiFactory = exports.ConnectionApiFp = exports.ConnectionApiAxiosParamCreator = exports.AdminPunishmentsApi = exports.AdminPunishmentsApiFactory = exports.AdminPunishmentsApiFp = exports.AdminPunishmentsApiAxiosParamCreator = exports.AdminPlayersApi = exports.AdminPlayersApiFactory = exports.AdminPlayersApiFp = exports.AdminPlayersApiAxiosParamCreator = exports.AdminDashboardApi = exports.AdminDashboardApiFactory = exports.AdminDashboardApiFp = exports.AdminDashboardApiAxiosParamCreator = exports.AdminConnectionsApi = exports.AdminConnectionsApiFactory = exports.AdminConnectionsApiFp = exports.AdminConnectionsApiAxiosParamCreator = exports.AdminClientCredentialsApi = exports.AdminClientCredentialsApiFactory = exports.AdminClientCredentialsApiFp = exports.AdminClientCredentialsApiAxiosParamCreator = void 0;
25
+ exports.PunishmentApi = exports.PunishmentApiFactory = exports.PunishmentApiFp = exports.PunishmentApiAxiosParamCreator = exports.PlayerApi = exports.PlayerApiFactory = exports.PlayerApiFp = exports.PlayerApiAxiosParamCreator = exports.DefaultApi = exports.DefaultApiFactory = exports.DefaultApiFp = exports.DefaultApiAxiosParamCreator = exports.ConnectionApi = exports.ConnectionApiFactory = exports.ConnectionApiFp = exports.ConnectionApiAxiosParamCreator = exports.AdminPunishmentsApi = exports.AdminPunishmentsApiFactory = exports.AdminPunishmentsApiFp = exports.AdminPunishmentsApiAxiosParamCreator = exports.AdminPlayersApi = exports.AdminPlayersApiFactory = exports.AdminPlayersApiFp = exports.AdminPlayersApiAxiosParamCreator = exports.AdminDashboardApi = exports.AdminDashboardApiFactory = exports.AdminDashboardApiFp = exports.AdminDashboardApiAxiosParamCreator = exports.AdminConnectionsApi = exports.AdminConnectionsApiFactory = exports.AdminConnectionsApiFp = exports.AdminConnectionsApiAxiosParamCreator = exports.AdminClientCredentialsApi = exports.AdminClientCredentialsApiFactory = exports.AdminClientCredentialsApiFp = exports.AdminClientCredentialsApiAxiosParamCreator = exports.AdminPunishmentSearchResponseKindEnum = exports.AdminCreatePunishmentDraftRequestTypeEnum = exports.AdminApplyPunishmentRequestTypeEnum = void 0;
26
26
  const axios_1 = require("axios");
27
27
  // Some imports not used depending on template conditions
28
28
  // @ts-ignore
29
29
  const common_1 = require("./common");
30
30
  // @ts-ignore
31
31
  const base_1 = require("./base");
32
+ exports.AdminApplyPunishmentRequestTypeEnum = {
33
+ Ban: 'BAN',
34
+ Mute: 'MUTE',
35
+ Warning: 'WARNING'
36
+ };
37
+ exports.AdminCreatePunishmentDraftRequestTypeEnum = {
38
+ Ban: 'BAN',
39
+ Mute: 'MUTE',
40
+ Warning: 'WARNING'
41
+ };
42
+ exports.AdminPunishmentSearchResponseKindEnum = {
43
+ Player: 'player',
44
+ Ip: 'ip'
45
+ };
32
46
  /**
33
47
  * AdminClientCredentialsApi - axios parameter creator
34
48
  */
@@ -1140,6 +1154,74 @@ exports.AdminPlayersApi = AdminPlayersApi;
1140
1154
  */
1141
1155
  const AdminPunishmentsApiAxiosParamCreator = function (configuration) {
1142
1156
  return {
1157
+ /**
1158
+ * Apply a punishment to one or more targets. Player targets are linked via player_punishment; IP targets are linked via connection_punishment. The authenticated user is recorded as the issuer.
1159
+ * @summary Apply punishment
1160
+ * @param {AdminApplyPunishmentRequest} adminApplyPunishmentRequest
1161
+ * @param {*} [options] Override http request option.
1162
+ * @throws {RequiredError}
1163
+ */
1164
+ applyPunishment: (adminApplyPunishmentRequest_1, ...args_1) => __awaiter(this, [adminApplyPunishmentRequest_1, ...args_1], void 0, function* (adminApplyPunishmentRequest, options = {}) {
1165
+ // verify required parameter 'adminApplyPunishmentRequest' is not null or undefined
1166
+ (0, common_1.assertParamExists)('applyPunishment', 'adminApplyPunishmentRequest', adminApplyPunishmentRequest);
1167
+ const localVarPath = `/admin/punishment/apply`;
1168
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1169
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1170
+ let baseOptions;
1171
+ if (configuration) {
1172
+ baseOptions = configuration.baseOptions;
1173
+ }
1174
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
1175
+ const localVarHeaderParameter = {};
1176
+ const localVarQueryParameter = {};
1177
+ // authentication DiscordAuth required
1178
+ // http bearer authentication required
1179
+ yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
1180
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1181
+ localVarHeaderParameter['Accept'] = 'application/json';
1182
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1183
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1184
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1185
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(adminApplyPunishmentRequest, localVarRequestOptions, configuration);
1186
+ return {
1187
+ url: (0, common_1.toPathString)(localVarUrlObj),
1188
+ options: localVarRequestOptions,
1189
+ };
1190
+ }),
1191
+ /**
1192
+ * Preview the impact of a punishment across one or more targets. Returns current score, points to add, projected new score, and affected players per target. No changes are made.
1193
+ * @summary Evaluate punishment impact
1194
+ * @param {AdminCreatePunishmentDraftRequest} adminCreatePunishmentDraftRequest
1195
+ * @param {*} [options] Override http request option.
1196
+ * @throws {RequiredError}
1197
+ */
1198
+ createDraft: (adminCreatePunishmentDraftRequest_1, ...args_1) => __awaiter(this, [adminCreatePunishmentDraftRequest_1, ...args_1], void 0, function* (adminCreatePunishmentDraftRequest, options = {}) {
1199
+ // verify required parameter 'adminCreatePunishmentDraftRequest' is not null or undefined
1200
+ (0, common_1.assertParamExists)('createDraft', 'adminCreatePunishmentDraftRequest', adminCreatePunishmentDraftRequest);
1201
+ const localVarPath = `/admin/punishment/draft`;
1202
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1203
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1204
+ let baseOptions;
1205
+ if (configuration) {
1206
+ baseOptions = configuration.baseOptions;
1207
+ }
1208
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
1209
+ const localVarHeaderParameter = {};
1210
+ const localVarQueryParameter = {};
1211
+ // authentication DiscordAuth required
1212
+ // http bearer authentication required
1213
+ yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
1214
+ localVarHeaderParameter['Content-Type'] = 'application/json';
1215
+ localVarHeaderParameter['Accept'] = 'application/json';
1216
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1217
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1218
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1219
+ localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(adminCreatePunishmentDraftRequest, localVarRequestOptions, configuration);
1220
+ return {
1221
+ url: (0, common_1.toPathString)(localVarUrlObj),
1222
+ options: localVarRequestOptions,
1223
+ };
1224
+ }),
1143
1225
  /**
1144
1226
  * Returns a paginated list of punishments with optional filtering by player UUID, username, IP address, type, and date range.
1145
1227
  * @summary List punishments
@@ -1148,7 +1230,7 @@ const AdminPunishmentsApiAxiosParamCreator = function (configuration) {
1148
1230
  * @param {string | null} [uuid] Filter by player UUID
1149
1231
  * @param {string | null} [username] Filter by player username (case-insensitive substring match)
1150
1232
  * @param {string | null} [ipAddress] Filter by IP address
1151
- * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, KICK, WARNING). Repeatable.
1233
+ * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, WARNING). Repeatable.
1152
1234
  * @param {number | null} [issuedAfter] Filter punishments issued after this epoch timestamp (ms)
1153
1235
  * @param {number | null} [issuedBefore] Filter punishments issued before this epoch timestamp (ms)
1154
1236
  * @param {*} [options] Override http request option.
@@ -1205,6 +1287,41 @@ const AdminPunishmentsApiAxiosParamCreator = function (configuration) {
1205
1287
  options: localVarRequestOptions,
1206
1288
  };
1207
1289
  }),
1290
+ /**
1291
+ * Search for players by UUID or username, or look up all players associated with an IP address. Used to populate the target table before issuing a punishment.
1292
+ * @summary Search punishment targets
1293
+ * @param {string} q UUID, username, or partial/full IP address to search for
1294
+ * @param {*} [options] Override http request option.
1295
+ * @throws {RequiredError}
1296
+ */
1297
+ searchTargets: (q_1, ...args_1) => __awaiter(this, [q_1, ...args_1], void 0, function* (q, options = {}) {
1298
+ // verify required parameter 'q' is not null or undefined
1299
+ (0, common_1.assertParamExists)('searchTargets', 'q', q);
1300
+ const localVarPath = `/admin/punishment/search`;
1301
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
1302
+ const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1303
+ let baseOptions;
1304
+ if (configuration) {
1305
+ baseOptions = configuration.baseOptions;
1306
+ }
1307
+ const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
1308
+ const localVarHeaderParameter = {};
1309
+ const localVarQueryParameter = {};
1310
+ // authentication DiscordAuth required
1311
+ // http bearer authentication required
1312
+ yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
1313
+ if (q !== undefined) {
1314
+ localVarQueryParameter['q'] = q;
1315
+ }
1316
+ localVarHeaderParameter['Accept'] = 'application/json';
1317
+ (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1318
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1319
+ localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1320
+ return {
1321
+ url: (0, common_1.toPathString)(localVarUrlObj),
1322
+ options: localVarRequestOptions,
1323
+ };
1324
+ }),
1208
1325
  };
1209
1326
  };
1210
1327
  exports.AdminPunishmentsApiAxiosParamCreator = AdminPunishmentsApiAxiosParamCreator;
@@ -1214,6 +1331,38 @@ exports.AdminPunishmentsApiAxiosParamCreator = AdminPunishmentsApiAxiosParamCrea
1214
1331
  const AdminPunishmentsApiFp = function (configuration) {
1215
1332
  const localVarAxiosParamCreator = (0, exports.AdminPunishmentsApiAxiosParamCreator)(configuration);
1216
1333
  return {
1334
+ /**
1335
+ * Apply a punishment to one or more targets. Player targets are linked via player_punishment; IP targets are linked via connection_punishment. The authenticated user is recorded as the issuer.
1336
+ * @summary Apply punishment
1337
+ * @param {AdminApplyPunishmentRequest} adminApplyPunishmentRequest
1338
+ * @param {*} [options] Override http request option.
1339
+ * @throws {RequiredError}
1340
+ */
1341
+ applyPunishment(adminApplyPunishmentRequest, options) {
1342
+ return __awaiter(this, void 0, void 0, function* () {
1343
+ var _a, _b, _c;
1344
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.applyPunishment(adminApplyPunishmentRequest, options);
1345
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1346
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AdminPunishmentsApi.applyPunishment']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1347
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1348
+ });
1349
+ },
1350
+ /**
1351
+ * Preview the impact of a punishment across one or more targets. Returns current score, points to add, projected new score, and affected players per target. No changes are made.
1352
+ * @summary Evaluate punishment impact
1353
+ * @param {AdminCreatePunishmentDraftRequest} adminCreatePunishmentDraftRequest
1354
+ * @param {*} [options] Override http request option.
1355
+ * @throws {RequiredError}
1356
+ */
1357
+ createDraft(adminCreatePunishmentDraftRequest, options) {
1358
+ return __awaiter(this, void 0, void 0, function* () {
1359
+ var _a, _b, _c;
1360
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.createDraft(adminCreatePunishmentDraftRequest, options);
1361
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1362
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AdminPunishmentsApi.createDraft']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1363
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1364
+ });
1365
+ },
1217
1366
  /**
1218
1367
  * Returns a paginated list of punishments with optional filtering by player UUID, username, IP address, type, and date range.
1219
1368
  * @summary List punishments
@@ -1222,7 +1371,7 @@ const AdminPunishmentsApiFp = function (configuration) {
1222
1371
  * @param {string | null} [uuid] Filter by player UUID
1223
1372
  * @param {string | null} [username] Filter by player username (case-insensitive substring match)
1224
1373
  * @param {string | null} [ipAddress] Filter by IP address
1225
- * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, KICK, WARNING). Repeatable.
1374
+ * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, WARNING). Repeatable.
1226
1375
  * @param {number | null} [issuedAfter] Filter punishments issued after this epoch timestamp (ms)
1227
1376
  * @param {number | null} [issuedBefore] Filter punishments issued before this epoch timestamp (ms)
1228
1377
  * @param {*} [options] Override http request option.
@@ -1237,6 +1386,22 @@ const AdminPunishmentsApiFp = function (configuration) {
1237
1386
  return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1238
1387
  });
1239
1388
  },
1389
+ /**
1390
+ * Search for players by UUID or username, or look up all players associated with an IP address. Used to populate the target table before issuing a punishment.
1391
+ * @summary Search punishment targets
1392
+ * @param {string} q UUID, username, or partial/full IP address to search for
1393
+ * @param {*} [options] Override http request option.
1394
+ * @throws {RequiredError}
1395
+ */
1396
+ searchTargets(q, options) {
1397
+ return __awaiter(this, void 0, void 0, function* () {
1398
+ var _a, _b, _c;
1399
+ const localVarAxiosArgs = yield localVarAxiosParamCreator.searchTargets(q, options);
1400
+ const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1401
+ const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['AdminPunishmentsApi.searchTargets']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1402
+ return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1403
+ });
1404
+ },
1240
1405
  };
1241
1406
  };
1242
1407
  exports.AdminPunishmentsApiFp = AdminPunishmentsApiFp;
@@ -1246,6 +1411,26 @@ exports.AdminPunishmentsApiFp = AdminPunishmentsApiFp;
1246
1411
  const AdminPunishmentsApiFactory = function (configuration, basePath, axios) {
1247
1412
  const localVarFp = (0, exports.AdminPunishmentsApiFp)(configuration);
1248
1413
  return {
1414
+ /**
1415
+ * Apply a punishment to one or more targets. Player targets are linked via player_punishment; IP targets are linked via connection_punishment. The authenticated user is recorded as the issuer.
1416
+ * @summary Apply punishment
1417
+ * @param {AdminApplyPunishmentRequest} adminApplyPunishmentRequest
1418
+ * @param {*} [options] Override http request option.
1419
+ * @throws {RequiredError}
1420
+ */
1421
+ applyPunishment(adminApplyPunishmentRequest, options) {
1422
+ return localVarFp.applyPunishment(adminApplyPunishmentRequest, options).then((request) => request(axios, basePath));
1423
+ },
1424
+ /**
1425
+ * Preview the impact of a punishment across one or more targets. Returns current score, points to add, projected new score, and affected players per target. No changes are made.
1426
+ * @summary Evaluate punishment impact
1427
+ * @param {AdminCreatePunishmentDraftRequest} adminCreatePunishmentDraftRequest
1428
+ * @param {*} [options] Override http request option.
1429
+ * @throws {RequiredError}
1430
+ */
1431
+ createDraft(adminCreatePunishmentDraftRequest, options) {
1432
+ return localVarFp.createDraft(adminCreatePunishmentDraftRequest, options).then((request) => request(axios, basePath));
1433
+ },
1249
1434
  /**
1250
1435
  * Returns a paginated list of punishments with optional filtering by player UUID, username, IP address, type, and date range.
1251
1436
  * @summary List punishments
@@ -1254,7 +1439,7 @@ const AdminPunishmentsApiFactory = function (configuration, basePath, axios) {
1254
1439
  * @param {string | null} [uuid] Filter by player UUID
1255
1440
  * @param {string | null} [username] Filter by player username (case-insensitive substring match)
1256
1441
  * @param {string | null} [ipAddress] Filter by IP address
1257
- * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, KICK, WARNING). Repeatable.
1442
+ * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, WARNING). Repeatable.
1258
1443
  * @param {number | null} [issuedAfter] Filter punishments issued after this epoch timestamp (ms)
1259
1444
  * @param {number | null} [issuedBefore] Filter punishments issued before this epoch timestamp (ms)
1260
1445
  * @param {*} [options] Override http request option.
@@ -1263,6 +1448,16 @@ const AdminPunishmentsApiFactory = function (configuration, basePath, axios) {
1263
1448
  getPunishments(page, limit, uuid, username, ipAddress, type, issuedAfter, issuedBefore, options) {
1264
1449
  return localVarFp.getPunishments(page, limit, uuid, username, ipAddress, type, issuedAfter, issuedBefore, options).then((request) => request(axios, basePath));
1265
1450
  },
1451
+ /**
1452
+ * Search for players by UUID or username, or look up all players associated with an IP address. Used to populate the target table before issuing a punishment.
1453
+ * @summary Search punishment targets
1454
+ * @param {string} q UUID, username, or partial/full IP address to search for
1455
+ * @param {*} [options] Override http request option.
1456
+ * @throws {RequiredError}
1457
+ */
1458
+ searchTargets(q, options) {
1459
+ return localVarFp.searchTargets(q, options).then((request) => request(axios, basePath));
1460
+ },
1266
1461
  };
1267
1462
  };
1268
1463
  exports.AdminPunishmentsApiFactory = AdminPunishmentsApiFactory;
@@ -1270,6 +1465,26 @@ exports.AdminPunishmentsApiFactory = AdminPunishmentsApiFactory;
1270
1465
  * AdminPunishmentsApi - object-oriented interface
1271
1466
  */
1272
1467
  class AdminPunishmentsApi extends base_1.BaseAPI {
1468
+ /**
1469
+ * Apply a punishment to one or more targets. Player targets are linked via player_punishment; IP targets are linked via connection_punishment. The authenticated user is recorded as the issuer.
1470
+ * @summary Apply punishment
1471
+ * @param {AdminApplyPunishmentRequest} adminApplyPunishmentRequest
1472
+ * @param {*} [options] Override http request option.
1473
+ * @throws {RequiredError}
1474
+ */
1475
+ applyPunishment(adminApplyPunishmentRequest, options) {
1476
+ return (0, exports.AdminPunishmentsApiFp)(this.configuration).applyPunishment(adminApplyPunishmentRequest, options).then((request) => request(this.axios, this.basePath));
1477
+ }
1478
+ /**
1479
+ * Preview the impact of a punishment across one or more targets. Returns current score, points to add, projected new score, and affected players per target. No changes are made.
1480
+ * @summary Evaluate punishment impact
1481
+ * @param {AdminCreatePunishmentDraftRequest} adminCreatePunishmentDraftRequest
1482
+ * @param {*} [options] Override http request option.
1483
+ * @throws {RequiredError}
1484
+ */
1485
+ createDraft(adminCreatePunishmentDraftRequest, options) {
1486
+ return (0, exports.AdminPunishmentsApiFp)(this.configuration).createDraft(adminCreatePunishmentDraftRequest, options).then((request) => request(this.axios, this.basePath));
1487
+ }
1273
1488
  /**
1274
1489
  * Returns a paginated list of punishments with optional filtering by player UUID, username, IP address, type, and date range.
1275
1490
  * @summary List punishments
@@ -1278,7 +1493,7 @@ class AdminPunishmentsApi extends base_1.BaseAPI {
1278
1493
  * @param {string | null} [uuid] Filter by player UUID
1279
1494
  * @param {string | null} [username] Filter by player username (case-insensitive substring match)
1280
1495
  * @param {string | null} [ipAddress] Filter by IP address
1281
- * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, KICK, WARNING). Repeatable.
1496
+ * @param {Array<string> | null} [type] Filter by punishment type (BAN, MUTE, WARNING). Repeatable.
1282
1497
  * @param {number | null} [issuedAfter] Filter punishments issued after this epoch timestamp (ms)
1283
1498
  * @param {number | null} [issuedBefore] Filter punishments issued before this epoch timestamp (ms)
1284
1499
  * @param {*} [options] Override http request option.
@@ -1287,6 +1502,16 @@ class AdminPunishmentsApi extends base_1.BaseAPI {
1287
1502
  getPunishments(page, limit, uuid, username, ipAddress, type, issuedAfter, issuedBefore, options) {
1288
1503
  return (0, exports.AdminPunishmentsApiFp)(this.configuration).getPunishments(page, limit, uuid, username, ipAddress, type, issuedAfter, issuedBefore, options).then((request) => request(this.axios, this.basePath));
1289
1504
  }
1505
+ /**
1506
+ * Search for players by UUID or username, or look up all players associated with an IP address. Used to populate the target table before issuing a punishment.
1507
+ * @summary Search punishment targets
1508
+ * @param {string} q UUID, username, or partial/full IP address to search for
1509
+ * @param {*} [options] Override http request option.
1510
+ * @throws {RequiredError}
1511
+ */
1512
+ searchTargets(q, options) {
1513
+ return (0, exports.AdminPunishmentsApiFp)(this.configuration).searchTargets(q, options).then((request) => request(this.axios, this.basePath));
1514
+ }
1290
1515
  }
1291
1516
  exports.AdminPunishmentsApi = AdminPunishmentsApi;
1292
1517
  /**
@@ -1674,74 +1899,6 @@ exports.PlayerApi = PlayerApi;
1674
1899
  */
1675
1900
  const PunishmentApiAxiosParamCreator = function (configuration) {
1676
1901
  return {
1677
- /**
1678
- * Create and apply a punishment to a player. Automatically determines if permanent based on current score threshold (≥100%).
1679
- * @summary Apply a punishment
1680
- * @param {ApplyPunishmentRequest} applyPunishmentRequest
1681
- * @param {*} [options] Override http request option.
1682
- * @throws {RequiredError}
1683
- */
1684
- applyPunishment: (applyPunishmentRequest_1, ...args_1) => __awaiter(this, [applyPunishmentRequest_1, ...args_1], void 0, function* (applyPunishmentRequest, options = {}) {
1685
- // verify required parameter 'applyPunishmentRequest' is not null or undefined
1686
- (0, common_1.assertParamExists)('applyPunishment', 'applyPunishmentRequest', applyPunishmentRequest);
1687
- const localVarPath = `/v1/punishment/apply`;
1688
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1689
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1690
- let baseOptions;
1691
- if (configuration) {
1692
- baseOptions = configuration.baseOptions;
1693
- }
1694
- const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
1695
- const localVarHeaderParameter = {};
1696
- const localVarQueryParameter = {};
1697
- // authentication DiscordAuth required
1698
- // http bearer authentication required
1699
- yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
1700
- localVarHeaderParameter['Content-Type'] = 'application/json';
1701
- localVarHeaderParameter['Accept'] = 'application/json';
1702
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1703
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1704
- localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1705
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(applyPunishmentRequest, localVarRequestOptions, configuration);
1706
- return {
1707
- url: (0, common_1.toPathString)(localVarUrlObj),
1708
- options: localVarRequestOptions,
1709
- };
1710
- }),
1711
- /**
1712
- * Preview punishment impact before applying. Returns calculated points, current/new thresholds, and whether it will be permanent.
1713
- * @summary Create a punishment draft
1714
- * @param {CreatePunishmentDraftRequest} createPunishmentDraftRequest
1715
- * @param {*} [options] Override http request option.
1716
- * @throws {RequiredError}
1717
- */
1718
- createPunishmentDraft: (createPunishmentDraftRequest_1, ...args_1) => __awaiter(this, [createPunishmentDraftRequest_1, ...args_1], void 0, function* (createPunishmentDraftRequest, options = {}) {
1719
- // verify required parameter 'createPunishmentDraftRequest' is not null or undefined
1720
- (0, common_1.assertParamExists)('createPunishmentDraft', 'createPunishmentDraftRequest', createPunishmentDraftRequest);
1721
- const localVarPath = `/v1/punishment/draft`;
1722
- // use dummy base URL string because the URL constructor only accepts absolute URLs.
1723
- const localVarUrlObj = new URL(localVarPath, common_1.DUMMY_BASE_URL);
1724
- let baseOptions;
1725
- if (configuration) {
1726
- baseOptions = configuration.baseOptions;
1727
- }
1728
- const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
1729
- const localVarHeaderParameter = {};
1730
- const localVarQueryParameter = {};
1731
- // authentication DiscordAuth required
1732
- // http bearer authentication required
1733
- yield (0, common_1.setBearerAuthToObject)(localVarHeaderParameter, configuration);
1734
- localVarHeaderParameter['Content-Type'] = 'application/json';
1735
- localVarHeaderParameter['Accept'] = 'application/json';
1736
- (0, common_1.setSearchParams)(localVarUrlObj, localVarQueryParameter);
1737
- let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
1738
- localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
1739
- localVarRequestOptions.data = (0, common_1.serializeDataIfNeeded)(createPunishmentDraftRequest, localVarRequestOptions, configuration);
1740
- return {
1741
- url: (0, common_1.toPathString)(localVarUrlObj),
1742
- options: localVarRequestOptions,
1743
- };
1744
- }),
1745
1902
  /**
1746
1903
  * Retrieve duration information for each punishment type and severity level (1-10)
1747
1904
  * @summary Get punishment severities
@@ -1929,38 +2086,6 @@ exports.PunishmentApiAxiosParamCreator = PunishmentApiAxiosParamCreator;
1929
2086
  const PunishmentApiFp = function (configuration) {
1930
2087
  const localVarAxiosParamCreator = (0, exports.PunishmentApiAxiosParamCreator)(configuration);
1931
2088
  return {
1932
- /**
1933
- * Create and apply a punishment to a player. Automatically determines if permanent based on current score threshold (≥100%).
1934
- * @summary Apply a punishment
1935
- * @param {ApplyPunishmentRequest} applyPunishmentRequest
1936
- * @param {*} [options] Override http request option.
1937
- * @throws {RequiredError}
1938
- */
1939
- applyPunishment(applyPunishmentRequest, options) {
1940
- return __awaiter(this, void 0, void 0, function* () {
1941
- var _a, _b, _c;
1942
- const localVarAxiosArgs = yield localVarAxiosParamCreator.applyPunishment(applyPunishmentRequest, options);
1943
- const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1944
- const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['PunishmentApi.applyPunishment']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1945
- return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1946
- });
1947
- },
1948
- /**
1949
- * Preview punishment impact before applying. Returns calculated points, current/new thresholds, and whether it will be permanent.
1950
- * @summary Create a punishment draft
1951
- * @param {CreatePunishmentDraftRequest} createPunishmentDraftRequest
1952
- * @param {*} [options] Override http request option.
1953
- * @throws {RequiredError}
1954
- */
1955
- createPunishmentDraft(createPunishmentDraftRequest, options) {
1956
- return __awaiter(this, void 0, void 0, function* () {
1957
- var _a, _b, _c;
1958
- const localVarAxiosArgs = yield localVarAxiosParamCreator.createPunishmentDraft(createPunishmentDraftRequest, options);
1959
- const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
1960
- const localVarOperationServerBasePath = (_c = (_b = base_1.operationServerMap['PunishmentApi.createPunishmentDraft']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
1961
- return (axios, basePath) => (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
1962
- });
1963
- },
1964
2089
  /**
1965
2090
  * Retrieve duration information for each punishment type and severity level (1-10)
1966
2091
  * @summary Get punishment severities
@@ -2044,26 +2169,6 @@ exports.PunishmentApiFp = PunishmentApiFp;
2044
2169
  const PunishmentApiFactory = function (configuration, basePath, axios) {
2045
2170
  const localVarFp = (0, exports.PunishmentApiFp)(configuration);
2046
2171
  return {
2047
- /**
2048
- * Create and apply a punishment to a player. Automatically determines if permanent based on current score threshold (≥100%).
2049
- * @summary Apply a punishment
2050
- * @param {ApplyPunishmentRequest} applyPunishmentRequest
2051
- * @param {*} [options] Override http request option.
2052
- * @throws {RequiredError}
2053
- */
2054
- applyPunishment(applyPunishmentRequest, options) {
2055
- return localVarFp.applyPunishment(applyPunishmentRequest, options).then((request) => request(axios, basePath));
2056
- },
2057
- /**
2058
- * Preview punishment impact before applying. Returns calculated points, current/new thresholds, and whether it will be permanent.
2059
- * @summary Create a punishment draft
2060
- * @param {CreatePunishmentDraftRequest} createPunishmentDraftRequest
2061
- * @param {*} [options] Override http request option.
2062
- * @throws {RequiredError}
2063
- */
2064
- createPunishmentDraft(createPunishmentDraftRequest, options) {
2065
- return localVarFp.createPunishmentDraft(createPunishmentDraftRequest, options).then((request) => request(axios, basePath));
2066
- },
2067
2172
  /**
2068
2173
  * Retrieve duration information for each punishment type and severity level (1-10)
2069
2174
  * @summary Get punishment severities
@@ -2121,26 +2226,6 @@ exports.PunishmentApiFactory = PunishmentApiFactory;
2121
2226
  * PunishmentApi - object-oriented interface
2122
2227
  */
2123
2228
  class PunishmentApi extends base_1.BaseAPI {
2124
- /**
2125
- * Create and apply a punishment to a player. Automatically determines if permanent based on current score threshold (≥100%).
2126
- * @summary Apply a punishment
2127
- * @param {ApplyPunishmentRequest} applyPunishmentRequest
2128
- * @param {*} [options] Override http request option.
2129
- * @throws {RequiredError}
2130
- */
2131
- applyPunishment(applyPunishmentRequest, options) {
2132
- return (0, exports.PunishmentApiFp)(this.configuration).applyPunishment(applyPunishmentRequest, options).then((request) => request(this.axios, this.basePath));
2133
- }
2134
- /**
2135
- * Preview punishment impact before applying. Returns calculated points, current/new thresholds, and whether it will be permanent.
2136
- * @summary Create a punishment draft
2137
- * @param {CreatePunishmentDraftRequest} createPunishmentDraftRequest
2138
- * @param {*} [options] Override http request option.
2139
- * @throws {RequiredError}
2140
- */
2141
- createPunishmentDraft(createPunishmentDraftRequest, options) {
2142
- return (0, exports.PunishmentApiFp)(this.configuration).createPunishmentDraft(createPunishmentDraftRequest, options).then((request) => request(this.axios, this.basePath));
2143
- }
2144
2229
  /**
2145
2230
  * Retrieve duration information for each punishment type and severity level (1-10)
2146
2231
  * @summary Get punishment severities
package/dist/base.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Reborn API
3
3
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
4
4
  *
5
- * The version of the OpenAPI document: 2.6.0
5
+ * The version of the OpenAPI document: 2.6.4
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/base.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Reborn API
6
6
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
7
7
  *
8
- * The version of the OpenAPI document: 2.6.0
8
+ * The version of the OpenAPI document: 2.6.4
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/common.d.ts CHANGED
@@ -2,7 +2,7 @@
2
2
  * Reborn API
3
3
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
4
4
  *
5
- * The version of the OpenAPI document: 2.6.0
5
+ * The version of the OpenAPI document: 2.6.4
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
package/dist/common.js CHANGED
@@ -5,7 +5,7 @@
5
5
  * Reborn API
6
6
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
7
7
  *
8
- * The version of the OpenAPI document: 2.6.0
8
+ * The version of the OpenAPI document: 2.6.4
9
9
  *
10
10
  *
11
11
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -2,7 +2,7 @@
2
2
  * Reborn API
3
3
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
4
4
  *
5
- * The version of the OpenAPI document: 2.6.0
5
+ * The version of the OpenAPI document: 2.6.4
6
6
  *
7
7
  *
8
8
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
@@ -4,7 +4,7 @@
4
4
  * Reborn API
5
5
  * The Reborn API serves as the central backend for the platform, orchestrating secure communication between game clients and data services. This API supports two authentication methods: - **OAuth 2.0 Client Credentials**: For programmatic API access - **Discord SSO Bearer Token**: For admin endpoints requiring Discord authentication
6
6
  *
7
- * The version of the OpenAPI document: 2.6.0
7
+ * The version of the OpenAPI document: 2.6.4
8
8
  *
9
9
  *
10
10
  * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).