@rebornteam/reborn-api 4.0.0 → 4.5.0
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 +5 -0
- package/README.md +12 -2
- package/api.ts +467 -2
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +1 -1
- package/dist/api.d.ts +267 -2
- package/dist/api.js +339 -1
- package/dist/base.d.ts +1 -1
- package/dist/base.js +1 -1
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +1 -1
- package/dist/esm/api.d.ts +267 -2
- package/dist/esm/api.js +339 -1
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +1 -1
- package/dist/esm/common.d.ts +1 -1
- package/dist/esm/common.js +1 -1
- package/dist/esm/configuration.d.ts +1 -1
- package/dist/esm/configuration.js +1 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/docs/AdminAltGraph.md +27 -0
- package/docs/AdminAltGraphEdge.md +25 -0
- package/docs/AdminAltGraphNode.md +29 -0
- package/docs/AdminAsyncJob.md +2 -0
- package/docs/AdminAsyncJobArtifactMeta.md +23 -0
- package/docs/AdminJobsApi.md +55 -0
- package/docs/AdminPlayersApi.md +104 -0
- package/docs/AdminPunishmentTargets.md +23 -0
- package/docs/AdminPunishmentsApi.md +101 -0
- package/docs/AdminUpdatePunishmentRequest.md +9 -1
- package/index.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# AdminAltGraphNode
|
|
2
|
+
|
|
3
|
+
One player node in an alt-graph traversal.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**uuid** | **string** | Player Minecraft UUID | [default to undefined]
|
|
10
|
+
**username** | **string** | Most recently seen username, null if never resolved | [optional] [default to undefined]
|
|
11
|
+
**depth** | **number** | Hop count from the focal player (0 = the focal player herself). | [default to undefined]
|
|
12
|
+
**trustFactor** | **number** | Trust factor (0-100). Drives the node colour in the graph. | [default to undefined]
|
|
13
|
+
**hasActivePunishment** | **boolean** | Whether this player currently has at least one active (non-revoked, non-expired) player_punishment row. Drives a red outline ring on the node. | [default to undefined]
|
|
14
|
+
|
|
15
|
+
## Example
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
import { AdminAltGraphNode } from '@rebornteam/reborn-api';
|
|
19
|
+
|
|
20
|
+
const instance: AdminAltGraphNode = {
|
|
21
|
+
uuid,
|
|
22
|
+
username,
|
|
23
|
+
depth,
|
|
24
|
+
trustFactor,
|
|
25
|
+
hasActivePunishment,
|
|
26
|
+
};
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
package/docs/AdminAsyncJob.md
CHANGED
|
@@ -20,6 +20,7 @@ Name | Type | Description | Notes
|
|
|
20
20
|
**finishedAt** | **string** | When the job entered a terminal state. Null while running. | [optional] [default to undefined]
|
|
21
21
|
**cancelRequested** | **boolean** | True if an admin has requested cancellation. The host instance picks this up at its next progress tick. | [default to undefined]
|
|
22
22
|
**hostInstance** | **string** | Identifier of the API instance that is running this job. Other instances can see state and request cancellation but cannot dispose the in-flight Reactor subscription directly. | [default to undefined]
|
|
23
|
+
**artifact** | [**AdminAsyncJobArtifactMeta**](AdminAsyncJobArtifactMeta.md) | Pointer to a CSV artifact emitted by this job, when one exists. Present only after the job marks COMPLETED and the artifact has been persisted. Download the CSV bytes via GET /admin/job/{id}/artifact.csv. | [optional] [default to undefined]
|
|
23
24
|
|
|
24
25
|
## Example
|
|
25
26
|
|
|
@@ -41,6 +42,7 @@ const instance: AdminAsyncJob = {
|
|
|
41
42
|
finishedAt,
|
|
42
43
|
cancelRequested,
|
|
43
44
|
hostInstance,
|
|
45
|
+
artifact,
|
|
44
46
|
};
|
|
45
47
|
```
|
|
46
48
|
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# AdminAsyncJobArtifactMeta
|
|
2
|
+
|
|
3
|
+
Pointer to a job\'s CSV artifact. Present only when the job emitted one.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**rowCount** | **number** | Number of data rows in the artifact (excluding the header). | [default to undefined]
|
|
10
|
+
**createdAt** | **string** | When the artifact was finalized (typically a few seconds after the job marked COMPLETED). | [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { AdminAsyncJobArtifactMeta } from '@rebornteam/reborn-api';
|
|
16
|
+
|
|
17
|
+
const instance: AdminAsyncJobArtifactMeta = {
|
|
18
|
+
rowCount,
|
|
19
|
+
createdAt,
|
|
20
|
+
};
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
package/docs/AdminJobsApi.md
CHANGED
|
@@ -5,6 +5,7 @@ All URIs are relative to *https://api.smsh.sh*
|
|
|
5
5
|
|Method | HTTP request | Description|
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
7
|
|[**cancel**](#cancel) | **DELETE** /admin/job/{id} | Request cancellation of an async job|
|
|
8
|
+
|[**downloadArtifact**](#downloadartifact) | **GET** /admin/job/{id}/artifact.csv | Download a job\'s CSV artifact|
|
|
8
9
|
|[**get**](#get) | **GET** /admin/job/{id} | Get one async job|
|
|
9
10
|
|[**list**](#list) | **GET** /admin/job | List async jobs|
|
|
10
11
|
|
|
@@ -62,6 +63,60 @@ void (empty response body)
|
|
|
62
63
|
|
|
63
64
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
64
65
|
|
|
66
|
+
# **downloadArtifact**
|
|
67
|
+
> string downloadArtifact()
|
|
68
|
+
|
|
69
|
+
Returns the CSV emitted by the job — typically one row per record the job touched. The first line is a header; subsequent lines are RFC-4180 escaped data rows. 404 when the job has no artifact (either it didn\'t emit one, or it hasn\'t finished yet).
|
|
70
|
+
|
|
71
|
+
### Example
|
|
72
|
+
|
|
73
|
+
```typescript
|
|
74
|
+
import {
|
|
75
|
+
AdminJobsApi,
|
|
76
|
+
Configuration
|
|
77
|
+
} from '@rebornteam/reborn-api';
|
|
78
|
+
|
|
79
|
+
const configuration = new Configuration();
|
|
80
|
+
const apiInstance = new AdminJobsApi(configuration);
|
|
81
|
+
|
|
82
|
+
let id: string; //Job id (default to undefined)
|
|
83
|
+
|
|
84
|
+
const { status, data } = await apiInstance.downloadArtifact(
|
|
85
|
+
id
|
|
86
|
+
);
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
### Parameters
|
|
90
|
+
|
|
91
|
+
|Name | Type | Description | Notes|
|
|
92
|
+
|------------- | ------------- | ------------- | -------------|
|
|
93
|
+
| **id** | [**string**] | Job id | defaults to undefined|
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
### Return type
|
|
97
|
+
|
|
98
|
+
**string**
|
|
99
|
+
|
|
100
|
+
### Authorization
|
|
101
|
+
|
|
102
|
+
[DiscordAuth](../README.md#DiscordAuth)
|
|
103
|
+
|
|
104
|
+
### HTTP request headers
|
|
105
|
+
|
|
106
|
+
- **Content-Type**: Not defined
|
|
107
|
+
- **Accept**: text/csv
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
### HTTP response details
|
|
111
|
+
| Status code | Description | Response headers |
|
|
112
|
+
|-------------|-------------|------------------|
|
|
113
|
+
|**200** | CSV streamed | - |
|
|
114
|
+
|**404** | No artifact for this job | - |
|
|
115
|
+
|**401** | Unauthorized | - |
|
|
116
|
+
|**403** | Forbidden - Moderator role required | - |
|
|
117
|
+
|
|
118
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
119
|
+
|
|
65
120
|
# **get**
|
|
66
121
|
> AdminAsyncJob get()
|
|
67
122
|
|
package/docs/AdminPlayersApi.md
CHANGED
|
@@ -5,9 +5,11 @@ All URIs are relative to *https://api.smsh.sh*
|
|
|
5
5
|
|Method | HTTP request | Description|
|
|
6
6
|
|------------- | ------------- | -------------|
|
|
7
7
|
|[**addAltExemption**](#addaltexemption) | **POST** /admin/player/{uuid}/alt-exemption | Add an alt exemption|
|
|
8
|
+
|[**backfillUsernames**](#backfillusernames) | **POST** /admin/player/backfill-usernames | Start a username backfill job|
|
|
8
9
|
|[**bulkRevokePropagated**](#bulkrevokepropagated) | **POST** /admin/player/player-punishment/bulk-revoke | Bulk-revoke PROPAGATED links by source|
|
|
9
10
|
|[**createPlayerNote**](#createplayernote) | **POST** /admin/player/{uuid}/note | Create a staff note on a player|
|
|
10
11
|
|[**deletePlayerNote**](#deleteplayernote) | **DELETE** /admin/player/{uuid}/note/{noteId} | Soft-delete a staff note|
|
|
12
|
+
|[**getAltGraph**](#getaltgraph) | **GET** /admin/player/{uuid}/alt-graph | Alt-graph traversal rooted at a player|
|
|
11
13
|
|[**getPlayer**](#getplayer) | **GET** /admin/player/{uuid} | Get player detail|
|
|
12
14
|
|[**getPlayerAlts**](#getplayeralts) | **GET** /admin/player/{uuid}/alts | List a player\'s alt accounts|
|
|
13
15
|
|[**getPlayerConnections**](#getplayerconnections) | **GET** /admin/player/{uuid}/connections | List a player\'s connection history|
|
|
@@ -82,6 +84,52 @@ void (empty response body)
|
|
|
82
84
|
|
|
83
85
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
84
86
|
|
|
87
|
+
# **backfillUsernames**
|
|
88
|
+
> AdminAsyncJobStartResponse backfillUsernames()
|
|
89
|
+
|
|
90
|
+
Submits an async job that walks every player row whose username is NULL and calls the Mojang profile API to resolve it. The job upserts both the player.username column and a player_username_history row. Returns immediately with a job id — poll GET /admin/job/{id} for progress and DELETE /admin/job/{id} to cancel. The final Admin_BackfillUsernamesResponse (processed/succeeded/failed counts) lands in the job\'s result_payload on COMPLETED. Mojang rate-limits at ~1 req/sec; a backfill of many rows can run for a while — cancel is honoured between rows.
|
|
91
|
+
|
|
92
|
+
### Example
|
|
93
|
+
|
|
94
|
+
```typescript
|
|
95
|
+
import {
|
|
96
|
+
AdminPlayersApi,
|
|
97
|
+
Configuration
|
|
98
|
+
} from '@rebornteam/reborn-api';
|
|
99
|
+
|
|
100
|
+
const configuration = new Configuration();
|
|
101
|
+
const apiInstance = new AdminPlayersApi(configuration);
|
|
102
|
+
|
|
103
|
+
const { status, data } = await apiInstance.backfillUsernames();
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Parameters
|
|
107
|
+
This endpoint does not have any parameters.
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
### Return type
|
|
111
|
+
|
|
112
|
+
**AdminAsyncJobStartResponse**
|
|
113
|
+
|
|
114
|
+
### Authorization
|
|
115
|
+
|
|
116
|
+
[DiscordAuth](../README.md#DiscordAuth)
|
|
117
|
+
|
|
118
|
+
### HTTP request headers
|
|
119
|
+
|
|
120
|
+
- **Content-Type**: Not defined
|
|
121
|
+
- **Accept**: application/json
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
### HTTP response details
|
|
125
|
+
| Status code | Description | Response headers |
|
|
126
|
+
|-------------|-------------|------------------|
|
|
127
|
+
|**202** | Job accepted; poll /admin/job/{id} for progress | - |
|
|
128
|
+
|**401** | Unauthorized | - |
|
|
129
|
+
|**403** | Forbidden - Moderator role required | - |
|
|
130
|
+
|
|
131
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
132
|
+
|
|
85
133
|
# **bulkRevokePropagated**
|
|
86
134
|
> AdminBulkRevokeResponse bulkRevokePropagated(adminBulkRevokeRequest)
|
|
87
135
|
|
|
@@ -252,6 +300,62 @@ void (empty response body)
|
|
|
252
300
|
|
|
253
301
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
254
302
|
|
|
303
|
+
# **getAltGraph**
|
|
304
|
+
> AdminAltGraph getAltGraph()
|
|
305
|
+
|
|
306
|
+
Returns the connection-shared player graph reachable from this player within {depth} hops. Mirrors the propagation walk used by ALT_PROPAGATION_SWEEP — promiscuous (likely shared-NAT) connections are pruned, alt-exemption rows cut the graph at exempted players. Depth is clamped server-side at 5. Used by the admin Graph tab to render an interactive explorer.
|
|
307
|
+
|
|
308
|
+
### Example
|
|
309
|
+
|
|
310
|
+
```typescript
|
|
311
|
+
import {
|
|
312
|
+
AdminPlayersApi,
|
|
313
|
+
Configuration
|
|
314
|
+
} from '@rebornteam/reborn-api';
|
|
315
|
+
|
|
316
|
+
const configuration = new Configuration();
|
|
317
|
+
const apiInstance = new AdminPlayersApi(configuration);
|
|
318
|
+
|
|
319
|
+
let uuid: string; //Player Minecraft UUID (default to undefined)
|
|
320
|
+
let depth: number; //Hop depth to walk. 1=direct alts only; 5=full sticky-trap radius. Default 2. (optional) (default to 2)
|
|
321
|
+
|
|
322
|
+
const { status, data } = await apiInstance.getAltGraph(
|
|
323
|
+
uuid,
|
|
324
|
+
depth
|
|
325
|
+
);
|
|
326
|
+
```
|
|
327
|
+
|
|
328
|
+
### Parameters
|
|
329
|
+
|
|
330
|
+
|Name | Type | Description | Notes|
|
|
331
|
+
|------------- | ------------- | ------------- | -------------|
|
|
332
|
+
| **uuid** | [**string**] | Player Minecraft UUID | defaults to undefined|
|
|
333
|
+
| **depth** | [**number**] | Hop depth to walk. 1=direct alts only; 5=full sticky-trap radius. Default 2. | (optional) defaults to 2|
|
|
334
|
+
|
|
335
|
+
|
|
336
|
+
### Return type
|
|
337
|
+
|
|
338
|
+
**AdminAltGraph**
|
|
339
|
+
|
|
340
|
+
### Authorization
|
|
341
|
+
|
|
342
|
+
[DiscordAuth](../README.md#DiscordAuth)
|
|
343
|
+
|
|
344
|
+
### HTTP request headers
|
|
345
|
+
|
|
346
|
+
- **Content-Type**: Not defined
|
|
347
|
+
- **Accept**: application/json
|
|
348
|
+
|
|
349
|
+
|
|
350
|
+
### HTTP response details
|
|
351
|
+
| Status code | Description | Response headers |
|
|
352
|
+
|-------------|-------------|------------------|
|
|
353
|
+
|**200** | Graph traversal complete | - |
|
|
354
|
+
|**401** | Unauthorized | - |
|
|
355
|
+
|**403** | Forbidden - Moderator role required | - |
|
|
356
|
+
|
|
357
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
358
|
+
|
|
255
359
|
# **getPlayer**
|
|
256
360
|
> AdminPlayerDetailResponse getPlayer()
|
|
257
361
|
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
# AdminPunishmentTargets
|
|
2
|
+
|
|
3
|
+
Active DIRECT participants currently attached to a punishment.
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**playerUuids** | **Array<string>** | UUIDs of players with an active DIRECT player_punishment link to this punishment. | [default to undefined]
|
|
10
|
+
**ipAddresses** | **Array<string>** | IPs of connections with a live connection_punishment row for this punishment. | [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { AdminPunishmentTargets } from '@rebornteam/reborn-api';
|
|
16
|
+
|
|
17
|
+
const instance: AdminPunishmentTargets = {
|
|
18
|
+
playerUuids,
|
|
19
|
+
ipAddresses,
|
|
20
|
+
};
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -7,7 +7,9 @@ All URIs are relative to *https://api.smsh.sh*
|
|
|
7
7
|
|[**applyPunishment**](#applypunishment) | **POST** /admin/punishment/apply | Apply punishment|
|
|
8
8
|
|[**createDraft**](#createdraft) | **POST** /admin/punishment/draft | Evaluate punishment impact|
|
|
9
9
|
|[**editPunishment**](#editpunishment) | **PATCH** /admin/punishment/{id} | Edit a punishment|
|
|
10
|
+
|[**getPunishmentTargets**](#getpunishmenttargets) | **GET** /admin/punishment/{id}/targets | List a punishment\'s current participants|
|
|
10
11
|
|[**getPunishments**](#getpunishments) | **GET** /admin/punishment | List punishments|
|
|
12
|
+
|[**propagationSweep**](#propagationsweep) | **POST** /admin/punishment/propagation-sweep | Start an alt-propagation sweep job|
|
|
11
13
|
|[**searchTargets**](#searchtargets) | **GET** /admin/punishment/search | Search punishment targets|
|
|
12
14
|
|
|
13
15
|
# **applyPunishment**
|
|
@@ -178,6 +180,59 @@ void (empty response body)
|
|
|
178
180
|
|
|
179
181
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
180
182
|
|
|
183
|
+
# **getPunishmentTargets**
|
|
184
|
+
> AdminPunishmentTargets getPunishmentTargets()
|
|
185
|
+
|
|
186
|
+
Returns the active DIRECT player_punishment UUIDs and the live connection_punishment IPs for a punishment. Used by the admin edit dialog to render the editable participant list. PROPAGATED links are excluded — they\'re an enforcement detail, not part of \'who the admin attached to this punishment\'.
|
|
187
|
+
|
|
188
|
+
### Example
|
|
189
|
+
|
|
190
|
+
```typescript
|
|
191
|
+
import {
|
|
192
|
+
AdminPunishmentsApi,
|
|
193
|
+
Configuration
|
|
194
|
+
} from '@rebornteam/reborn-api';
|
|
195
|
+
|
|
196
|
+
const configuration = new Configuration();
|
|
197
|
+
const apiInstance = new AdminPunishmentsApi(configuration);
|
|
198
|
+
|
|
199
|
+
let id: number; //Punishment id (default to undefined)
|
|
200
|
+
|
|
201
|
+
const { status, data } = await apiInstance.getPunishmentTargets(
|
|
202
|
+
id
|
|
203
|
+
);
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
### Parameters
|
|
207
|
+
|
|
208
|
+
|Name | Type | Description | Notes|
|
|
209
|
+
|------------- | ------------- | ------------- | -------------|
|
|
210
|
+
| **id** | [**number**] | Punishment id | defaults to undefined|
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
### Return type
|
|
214
|
+
|
|
215
|
+
**AdminPunishmentTargets**
|
|
216
|
+
|
|
217
|
+
### Authorization
|
|
218
|
+
|
|
219
|
+
[DiscordAuth](../README.md#DiscordAuth)
|
|
220
|
+
|
|
221
|
+
### HTTP request headers
|
|
222
|
+
|
|
223
|
+
- **Content-Type**: Not defined
|
|
224
|
+
- **Accept**: application/json
|
|
225
|
+
|
|
226
|
+
|
|
227
|
+
### HTTP response details
|
|
228
|
+
| Status code | Description | Response headers |
|
|
229
|
+
|-------------|-------------|------------------|
|
|
230
|
+
|**200** | Participants retrieved | - |
|
|
231
|
+
|**401** | Unauthorized | - |
|
|
232
|
+
|**403** | Forbidden - Moderator role required | - |
|
|
233
|
+
|
|
234
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
235
|
+
|
|
181
236
|
# **getPunishments**
|
|
182
237
|
> PageAdminPunishmentListItem getPunishments()
|
|
183
238
|
|
|
@@ -250,6 +305,52 @@ const { status, data } = await apiInstance.getPunishments(
|
|
|
250
305
|
|
|
251
306
|
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
252
307
|
|
|
308
|
+
# **propagationSweep**
|
|
309
|
+
> AdminAsyncJobStartResponse propagationSweep()
|
|
310
|
+
|
|
311
|
+
Submits an async job that walks every player and re-runs the aggressive-mode propagation logic (tier-1 own-IP plus tier-2 alt-driven). Useful after toggling aggressive-mode on, or after a propagation-rule change, to backfill PROPAGATED player_punishment rows that would otherwise only appear on each player\'s next login. Idempotent — ON CONFLICT DO NOTHING. Returns immediately with a job id; poll GET /admin/job/{id} for progress and DELETE /admin/job/{id} to cancel.
|
|
312
|
+
|
|
313
|
+
### Example
|
|
314
|
+
|
|
315
|
+
```typescript
|
|
316
|
+
import {
|
|
317
|
+
AdminPunishmentsApi,
|
|
318
|
+
Configuration
|
|
319
|
+
} from '@rebornteam/reborn-api';
|
|
320
|
+
|
|
321
|
+
const configuration = new Configuration();
|
|
322
|
+
const apiInstance = new AdminPunishmentsApi(configuration);
|
|
323
|
+
|
|
324
|
+
const { status, data } = await apiInstance.propagationSweep();
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
### Parameters
|
|
328
|
+
This endpoint does not have any parameters.
|
|
329
|
+
|
|
330
|
+
|
|
331
|
+
### Return type
|
|
332
|
+
|
|
333
|
+
**AdminAsyncJobStartResponse**
|
|
334
|
+
|
|
335
|
+
### Authorization
|
|
336
|
+
|
|
337
|
+
[DiscordAuth](../README.md#DiscordAuth)
|
|
338
|
+
|
|
339
|
+
### HTTP request headers
|
|
340
|
+
|
|
341
|
+
- **Content-Type**: Not defined
|
|
342
|
+
- **Accept**: application/json
|
|
343
|
+
|
|
344
|
+
|
|
345
|
+
### HTTP response details
|
|
346
|
+
| Status code | Description | Response headers |
|
|
347
|
+
|-------------|-------------|------------------|
|
|
348
|
+
|**202** | Job accepted; poll /admin/job/{id} for progress | - |
|
|
349
|
+
|**401** | Unauthorized | - |
|
|
350
|
+
|**403** | Forbidden - Moderator role required | - |
|
|
351
|
+
|
|
352
|
+
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
|
|
353
|
+
|
|
253
354
|
# **searchTargets**
|
|
254
355
|
> AdminPunishmentSearchResponse searchTargets()
|
|
255
356
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# AdminUpdatePunishmentRequest
|
|
2
2
|
|
|
3
|
-
Partial update for a punishment.
|
|
3
|
+
Partial update for a punishment. All fields are optional; omitted fields stay untouched.
|
|
4
4
|
|
|
5
5
|
## Properties
|
|
6
6
|
|
|
@@ -10,6 +10,10 @@ Name | Type | Description | Notes
|
|
|
10
10
|
**notes** | **string** | Replace the internal admin notes. Null leaves them untouched; empty string clears them. | [optional] [default to undefined]
|
|
11
11
|
**expiresAt** | **string** | Replace the expiry timestamp (ISO-8601). Send an explicit null in JSON to make permanent — but note: omitting the field leaves expiry untouched. Use \'forcePermanent\' if you want to clear. | [optional] [default to undefined]
|
|
12
12
|
**forcePermanent** | **boolean** | When true, clears expiresAt (makes the punishment permanent). Takes precedence over expiresAt. | [optional] [default to undefined]
|
|
13
|
+
**type** | [**PunishmentType**](PunishmentType.md) | Replace the punishment type (BAN/MUTE/KICK/WARNING). Affects trust factor retroactively. | [optional] [default to undefined]
|
|
14
|
+
**severity** | **number** | Replace the severity (1–4). Affects trust factor retroactively. | [optional] [default to undefined]
|
|
15
|
+
**addTargets** | [**Array<AdminPunishmentTarget>**](AdminPunishmentTarget.md) | Targets to ADD. Each entry has either a player UUID or an IP. UUID → new DIRECT player_punishment row. IP → new connection_punishment row. | [optional] [default to undefined]
|
|
16
|
+
**removeTargets** | [**Array<AdminPunishmentTarget>**](AdminPunishmentTarget.md) | Targets to REMOVE. UUID → soft-revoke the DIRECT player_punishment link. IP → delete the connection_punishment row outright. PROPAGATED links are not affected by this endpoint. | [optional] [default to undefined]
|
|
13
17
|
|
|
14
18
|
## Example
|
|
15
19
|
|
|
@@ -21,6 +25,10 @@ const instance: AdminUpdatePunishmentRequest = {
|
|
|
21
25
|
notes,
|
|
22
26
|
expiresAt,
|
|
23
27
|
forcePermanent,
|
|
28
|
+
type,
|
|
29
|
+
severity,
|
|
30
|
+
addTargets,
|
|
31
|
+
removeTargets,
|
|
24
32
|
};
|
|
25
33
|
```
|
|
26
34
|
|
package/index.ts
CHANGED
|
@@ -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: 4.
|
|
7
|
+
* The version of the OpenAPI document: 4.5.0
|
|
8
8
|
*
|
|
9
9
|
*
|
|
10
10
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|