@rebornteam/reborn-api 2.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.gitkeep +0 -0
- package/.openapi-generator/FILES +36 -0
- package/.openapi-generator/VERSION +1 -0
- package/.openapi-generator-ignore +23 -0
- package/README.md +104 -0
- package/api.ts +2037 -0
- package/base.ts +62 -0
- package/common.ts +127 -0
- package/configuration.ts +121 -0
- package/dist/api.d.ts +1144 -0
- package/dist/api.js +1594 -0
- package/dist/base.d.ts +42 -0
- package/dist/base.js +46 -0
- package/dist/common.d.ts +34 -0
- package/dist/common.js +139 -0
- package/dist/configuration.d.ts +98 -0
- package/dist/configuration.js +44 -0
- package/dist/esm/api.d.ts +1144 -0
- package/dist/esm/api.js +1567 -0
- package/dist/esm/base.d.ts +42 -0
- package/dist/esm/base.js +41 -0
- package/dist/esm/common.d.ts +34 -0
- package/dist/esm/common.js +126 -0
- package/dist/esm/configuration.d.ts +98 -0
- package/dist/esm/configuration.js +40 -0
- package/dist/esm/index.d.ts +13 -0
- package/dist/esm/index.js +15 -0
- package/dist/index.d.ts +13 -0
- package/dist/index.js +31 -0
- package/docs/AdminClientCredentialResponse.md +33 -0
- package/docs/AdminClientCredentialsApi.md +390 -0
- package/docs/AdminConnectionBypassResponse.md +27 -0
- package/docs/AdminConnectionsApi.md +135 -0
- package/docs/AdminDashboardApi.md +54 -0
- package/docs/AdminDashboardConnectionResponse.md +38 -0
- package/docs/AdminGetDashboardStats.md +24 -0
- package/docs/ApplyPunishmentRequest.md +31 -0
- package/docs/ApplyPunishmentResponse.md +33 -0
- package/docs/ClientCredentialRequest.md +23 -0
- package/docs/ConnectionApi.md +69 -0
- package/docs/ConnectionGetConnectionDetailsResponse.md +35 -0
- package/docs/CreateBypassRequest.md +23 -0
- package/docs/CreatePunishmentDraftRequest.md +29 -0
- package/docs/PlayerApi.md +62 -0
- package/docs/PlayerGetPlayerInformation.md +27 -0
- package/docs/PunishmentApi.md +347 -0
- package/docs/PunishmentDraftResponse.md +39 -0
- package/docs/PunishmentGetPunishmentResponse.md +33 -0
- package/docs/PunishmentSeveritiesResponse.md +21 -0
- package/docs/PunishmentSeveritiesResponsePunishmentTypeInfo.md +23 -0
- package/docs/PunishmentSeveritiesResponseSeverityInfo.md +23 -0
- package/docs/UpdateClientRequest.md +23 -0
- package/git_push.sh +57 -0
- package/index.ts +18 -0
- package/package.json +33 -0
- package/tsconfig.esm.json +7 -0
- package/tsconfig.json +18 -0
|
@@ -0,0 +1,390 @@
|
|
|
1
|
+
# AdminClientCredentialsApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.smsh.sh*
|
|
4
|
+
|
|
5
|
+
|Method | HTTP request | Description|
|
|
6
|
+
|------------- | ------------- | -------------|
|
|
7
|
+
|[**disableClient**](#disableclient) | **POST** /admin/client/{id}/disable | Disable client credentials|
|
|
8
|
+
|[**enableClient**](#enableclient) | **POST** /admin/client/{id}/enable | Enable client credentials|
|
|
9
|
+
|[**generateClientCredentials**](#generateclientcredentials) | **POST** /admin/client/generate | Generate new client credentials|
|
|
10
|
+
|[**listClients**](#listclients) | **GET** /admin/client | List client credentials|
|
|
11
|
+
|[**revokeToken**](#revoketoken) | **DELETE** /admin/client/{id} | Revoke client credentials|
|
|
12
|
+
|[**rotateToken**](#rotatetoken) | **POST** /admin/client/{id}/rotate | Rotate client credentials|
|
|
13
|
+
|[**updateClient**](#updateclient) | **PUT** /admin/client/{id} | Update client metadata|
|
|
14
|
+
|
|
15
|
+
# **disableClient**
|
|
16
|
+
> disableClient()
|
|
17
|
+
|
|
18
|
+
Temporarily disables a client credential, preventing authentication. Can be re-enabled later.
|
|
19
|
+
|
|
20
|
+
### Example
|
|
21
|
+
|
|
22
|
+
```typescript
|
|
23
|
+
import {
|
|
24
|
+
AdminClientCredentialsApi,
|
|
25
|
+
Configuration
|
|
26
|
+
} from '@rebornteam/reborn-api';
|
|
27
|
+
|
|
28
|
+
const configuration = new Configuration();
|
|
29
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
30
|
+
|
|
31
|
+
let id: number; //Client credential ID (default to undefined)
|
|
32
|
+
|
|
33
|
+
const { status, data } = await apiInstance.disableClient(
|
|
34
|
+
id
|
|
35
|
+
);
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
### Parameters
|
|
39
|
+
|
|
40
|
+
|Name | Type | Description | Notes|
|
|
41
|
+
|------------- | ------------- | ------------- | -------------|
|
|
42
|
+
| **id** | [**number**] | Client credential ID | defaults to undefined|
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
### Return type
|
|
46
|
+
|
|
47
|
+
void (empty response body)
|
|
48
|
+
|
|
49
|
+
### Authorization
|
|
50
|
+
|
|
51
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
52
|
+
|
|
53
|
+
### HTTP request headers
|
|
54
|
+
|
|
55
|
+
- **Content-Type**: Not defined
|
|
56
|
+
- **Accept**: Not defined
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
### HTTP response details
|
|
60
|
+
| Status code | Description | Response headers |
|
|
61
|
+
|-------------|-------------|------------------|
|
|
62
|
+
|**204** | Client credential disabled successfully | - |
|
|
63
|
+
|**404** | Client credential not found | - |
|
|
64
|
+
|**401** | Unauthorized - Cognito token required | - |
|
|
65
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
66
|
+
|
|
67
|
+
[[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)
|
|
68
|
+
|
|
69
|
+
# **enableClient**
|
|
70
|
+
> enableClient()
|
|
71
|
+
|
|
72
|
+
Re-enables a previously disabled client credential, allowing authentication.
|
|
73
|
+
|
|
74
|
+
### Example
|
|
75
|
+
|
|
76
|
+
```typescript
|
|
77
|
+
import {
|
|
78
|
+
AdminClientCredentialsApi,
|
|
79
|
+
Configuration
|
|
80
|
+
} from '@rebornteam/reborn-api';
|
|
81
|
+
|
|
82
|
+
const configuration = new Configuration();
|
|
83
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
84
|
+
|
|
85
|
+
let id: number; //Client credential ID (default to undefined)
|
|
86
|
+
|
|
87
|
+
const { status, data } = await apiInstance.enableClient(
|
|
88
|
+
id
|
|
89
|
+
);
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### Parameters
|
|
93
|
+
|
|
94
|
+
|Name | Type | Description | Notes|
|
|
95
|
+
|------------- | ------------- | ------------- | -------------|
|
|
96
|
+
| **id** | [**number**] | Client credential ID | defaults to undefined|
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
### Return type
|
|
100
|
+
|
|
101
|
+
void (empty response body)
|
|
102
|
+
|
|
103
|
+
### Authorization
|
|
104
|
+
|
|
105
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
106
|
+
|
|
107
|
+
### HTTP request headers
|
|
108
|
+
|
|
109
|
+
- **Content-Type**: Not defined
|
|
110
|
+
- **Accept**: Not defined
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
### HTTP response details
|
|
114
|
+
| Status code | Description | Response headers |
|
|
115
|
+
|-------------|-------------|------------------|
|
|
116
|
+
|**204** | Client credential enabled successfully | - |
|
|
117
|
+
|**404** | Client credential not found | - |
|
|
118
|
+
|**401** | Unauthorized - Cognito token required | - |
|
|
119
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
120
|
+
|
|
121
|
+
[[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)
|
|
122
|
+
|
|
123
|
+
# **generateClientCredentials**
|
|
124
|
+
> AdminClientCredentialResponse generateClientCredentials(clientCredentialRequest)
|
|
125
|
+
|
|
126
|
+
Creates a new API client with credentials for authentication. Returns the client ID and secret (only shown once).
|
|
127
|
+
|
|
128
|
+
### Example
|
|
129
|
+
|
|
130
|
+
```typescript
|
|
131
|
+
import {
|
|
132
|
+
AdminClientCredentialsApi,
|
|
133
|
+
Configuration,
|
|
134
|
+
ClientCredentialRequest
|
|
135
|
+
} from '@rebornteam/reborn-api';
|
|
136
|
+
|
|
137
|
+
const configuration = new Configuration();
|
|
138
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
139
|
+
|
|
140
|
+
let clientCredentialRequest: ClientCredentialRequest; //
|
|
141
|
+
|
|
142
|
+
const { status, data } = await apiInstance.generateClientCredentials(
|
|
143
|
+
clientCredentialRequest
|
|
144
|
+
);
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
### Parameters
|
|
148
|
+
|
|
149
|
+
|Name | Type | Description | Notes|
|
|
150
|
+
|------------- | ------------- | ------------- | -------------|
|
|
151
|
+
| **clientCredentialRequest** | **ClientCredentialRequest**| | |
|
|
152
|
+
|
|
153
|
+
|
|
154
|
+
### Return type
|
|
155
|
+
|
|
156
|
+
**AdminClientCredentialResponse**
|
|
157
|
+
|
|
158
|
+
### Authorization
|
|
159
|
+
|
|
160
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
161
|
+
|
|
162
|
+
### HTTP request headers
|
|
163
|
+
|
|
164
|
+
- **Content-Type**: application/json
|
|
165
|
+
- **Accept**: application/json
|
|
166
|
+
|
|
167
|
+
|
|
168
|
+
### HTTP response details
|
|
169
|
+
| Status code | Description | Response headers |
|
|
170
|
+
|-------------|-------------|------------------|
|
|
171
|
+
|**200** | Client credentials generated successfully | - |
|
|
172
|
+
|**400** | Invalid request body | - |
|
|
173
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
174
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
175
|
+
|
|
176
|
+
[[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)
|
|
177
|
+
|
|
178
|
+
# **listClients**
|
|
179
|
+
> Array<AdminClientCredentialResponse> listClients()
|
|
180
|
+
|
|
181
|
+
Returns all client credentials. **Client secrets are never returned** from this endpoint.
|
|
182
|
+
|
|
183
|
+
### Example
|
|
184
|
+
|
|
185
|
+
```typescript
|
|
186
|
+
import {
|
|
187
|
+
AdminClientCredentialsApi,
|
|
188
|
+
Configuration
|
|
189
|
+
} from '@rebornteam/reborn-api';
|
|
190
|
+
|
|
191
|
+
const configuration = new Configuration();
|
|
192
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
193
|
+
|
|
194
|
+
const { status, data } = await apiInstance.listClients();
|
|
195
|
+
```
|
|
196
|
+
|
|
197
|
+
### Parameters
|
|
198
|
+
This endpoint does not have any parameters.
|
|
199
|
+
|
|
200
|
+
|
|
201
|
+
### Return type
|
|
202
|
+
|
|
203
|
+
**Array<AdminClientCredentialResponse>**
|
|
204
|
+
|
|
205
|
+
### Authorization
|
|
206
|
+
|
|
207
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
208
|
+
|
|
209
|
+
### HTTP request headers
|
|
210
|
+
|
|
211
|
+
- **Content-Type**: Not defined
|
|
212
|
+
- **Accept**: application/json
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
### HTTP response details
|
|
216
|
+
| Status code | Description | Response headers |
|
|
217
|
+
|-------------|-------------|------------------|
|
|
218
|
+
|**200** | Client credentials retrieved successfully | - |
|
|
219
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
220
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
221
|
+
|
|
222
|
+
[[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)
|
|
223
|
+
|
|
224
|
+
# **revokeToken**
|
|
225
|
+
> revokeToken()
|
|
226
|
+
|
|
227
|
+
Permanently deletes a client credential from the database, revoking all access.
|
|
228
|
+
|
|
229
|
+
### Example
|
|
230
|
+
|
|
231
|
+
```typescript
|
|
232
|
+
import {
|
|
233
|
+
AdminClientCredentialsApi,
|
|
234
|
+
Configuration
|
|
235
|
+
} from '@rebornteam/reborn-api';
|
|
236
|
+
|
|
237
|
+
const configuration = new Configuration();
|
|
238
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
239
|
+
|
|
240
|
+
let id: number; //Client credential ID (default to undefined)
|
|
241
|
+
|
|
242
|
+
const { status, data } = await apiInstance.revokeToken(
|
|
243
|
+
id
|
|
244
|
+
);
|
|
245
|
+
```
|
|
246
|
+
|
|
247
|
+
### Parameters
|
|
248
|
+
|
|
249
|
+
|Name | Type | Description | Notes|
|
|
250
|
+
|------------- | ------------- | ------------- | -------------|
|
|
251
|
+
| **id** | [**number**] | Client credential ID | defaults to undefined|
|
|
252
|
+
|
|
253
|
+
|
|
254
|
+
### Return type
|
|
255
|
+
|
|
256
|
+
void (empty response body)
|
|
257
|
+
|
|
258
|
+
### Authorization
|
|
259
|
+
|
|
260
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
261
|
+
|
|
262
|
+
### HTTP request headers
|
|
263
|
+
|
|
264
|
+
- **Content-Type**: Not defined
|
|
265
|
+
- **Accept**: Not defined
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
### HTTP response details
|
|
269
|
+
| Status code | Description | Response headers |
|
|
270
|
+
|-------------|-------------|------------------|
|
|
271
|
+
|**204** | Client credential revoked successfully | - |
|
|
272
|
+
|**404** | Client credential not found | - |
|
|
273
|
+
|**401** | Unauthorized - Cognito token required | - |
|
|
274
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
275
|
+
|
|
276
|
+
[[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)
|
|
277
|
+
|
|
278
|
+
# **rotateToken**
|
|
279
|
+
> AdminClientCredentialResponse rotateToken()
|
|
280
|
+
|
|
281
|
+
Generates new client ID and secret for an existing client. The old credentials will no longer work. Returns the new credentials (secret only shown once).
|
|
282
|
+
|
|
283
|
+
### Example
|
|
284
|
+
|
|
285
|
+
```typescript
|
|
286
|
+
import {
|
|
287
|
+
AdminClientCredentialsApi,
|
|
288
|
+
Configuration
|
|
289
|
+
} from '@rebornteam/reborn-api';
|
|
290
|
+
|
|
291
|
+
const configuration = new Configuration();
|
|
292
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
293
|
+
|
|
294
|
+
let id: number; //Client credential ID (default to undefined)
|
|
295
|
+
|
|
296
|
+
const { status, data } = await apiInstance.rotateToken(
|
|
297
|
+
id
|
|
298
|
+
);
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
### Parameters
|
|
302
|
+
|
|
303
|
+
|Name | Type | Description | Notes|
|
|
304
|
+
|------------- | ------------- | ------------- | -------------|
|
|
305
|
+
| **id** | [**number**] | Client credential ID | defaults to undefined|
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
### Return type
|
|
309
|
+
|
|
310
|
+
**AdminClientCredentialResponse**
|
|
311
|
+
|
|
312
|
+
### Authorization
|
|
313
|
+
|
|
314
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
315
|
+
|
|
316
|
+
### HTTP request headers
|
|
317
|
+
|
|
318
|
+
- **Content-Type**: Not defined
|
|
319
|
+
- **Accept**: application/json
|
|
320
|
+
|
|
321
|
+
|
|
322
|
+
### HTTP response details
|
|
323
|
+
| Status code | Description | Response headers |
|
|
324
|
+
|-------------|-------------|------------------|
|
|
325
|
+
|**200** | Client credentials rotated successfully | - |
|
|
326
|
+
|**404** | Client credential not found | - |
|
|
327
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
328
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
329
|
+
|
|
330
|
+
[[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)
|
|
331
|
+
|
|
332
|
+
# **updateClient**
|
|
333
|
+
> AdminClientCredentialResponse updateClient(updateClientRequest)
|
|
334
|
+
|
|
335
|
+
Updates the name and/or description of a client credential. Does not affect the actual credentials.
|
|
336
|
+
|
|
337
|
+
### Example
|
|
338
|
+
|
|
339
|
+
```typescript
|
|
340
|
+
import {
|
|
341
|
+
AdminClientCredentialsApi,
|
|
342
|
+
Configuration,
|
|
343
|
+
UpdateClientRequest
|
|
344
|
+
} from '@rebornteam/reborn-api';
|
|
345
|
+
|
|
346
|
+
const configuration = new Configuration();
|
|
347
|
+
const apiInstance = new AdminClientCredentialsApi(configuration);
|
|
348
|
+
|
|
349
|
+
let id: number; //Client credential ID (default to undefined)
|
|
350
|
+
let updateClientRequest: UpdateClientRequest; //
|
|
351
|
+
|
|
352
|
+
const { status, data } = await apiInstance.updateClient(
|
|
353
|
+
id,
|
|
354
|
+
updateClientRequest
|
|
355
|
+
);
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
### Parameters
|
|
359
|
+
|
|
360
|
+
|Name | Type | Description | Notes|
|
|
361
|
+
|------------- | ------------- | ------------- | -------------|
|
|
362
|
+
| **updateClientRequest** | **UpdateClientRequest**| | |
|
|
363
|
+
| **id** | [**number**] | Client credential ID | defaults to undefined|
|
|
364
|
+
|
|
365
|
+
|
|
366
|
+
### Return type
|
|
367
|
+
|
|
368
|
+
**AdminClientCredentialResponse**
|
|
369
|
+
|
|
370
|
+
### Authorization
|
|
371
|
+
|
|
372
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
373
|
+
|
|
374
|
+
### HTTP request headers
|
|
375
|
+
|
|
376
|
+
- **Content-Type**: application/json
|
|
377
|
+
- **Accept**: application/json
|
|
378
|
+
|
|
379
|
+
|
|
380
|
+
### HTTP response details
|
|
381
|
+
| Status code | Description | Response headers |
|
|
382
|
+
|-------------|-------------|------------------|
|
|
383
|
+
|**200** | Client metadata updated successfully | - |
|
|
384
|
+
|**404** | Client credential not found | - |
|
|
385
|
+
|**400** | Invalid request body | - |
|
|
386
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
387
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
388
|
+
|
|
389
|
+
[[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)
|
|
390
|
+
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# AdminConnectionBypassResponse
|
|
2
|
+
|
|
3
|
+
Connection bypass response
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**id** | **number** | Unique identifier for the bypass | [optional] [default to undefined]
|
|
10
|
+
**ipAddress** | **string** | IP address that is bypassed | [optional] [default to undefined]
|
|
11
|
+
**expiresAt** | **string** | Timestamp when the bypass expires (ISO-8601 format) | [optional] [default to undefined]
|
|
12
|
+
**createdAt** | **string** | Timestamp when the bypass was created (ISO-8601 format) | [optional] [default to undefined]
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import { AdminConnectionBypassResponse } from '@rebornteam/reborn-api';
|
|
18
|
+
|
|
19
|
+
const instance: AdminConnectionBypassResponse = {
|
|
20
|
+
id,
|
|
21
|
+
ipAddress,
|
|
22
|
+
expiresAt,
|
|
23
|
+
createdAt,
|
|
24
|
+
};
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
# AdminConnectionsApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.smsh.sh*
|
|
4
|
+
|
|
5
|
+
|Method | HTTP request | Description|
|
|
6
|
+
|------------- | ------------- | -------------|
|
|
7
|
+
|[**createBypass**](#createbypass) | **POST** /admin/connection/bypass | Create connection bypass|
|
|
8
|
+
|[**listConnections**](#listconnections) | **GET** /admin/connection/recent | List recent connections|
|
|
9
|
+
|
|
10
|
+
# **createBypass**
|
|
11
|
+
> AdminConnectionBypassResponse createBypass(createBypassRequest)
|
|
12
|
+
|
|
13
|
+
Creates a temporary bypass for an IP address, expiring at the specified epoch timestamp (milliseconds since Unix epoch).
|
|
14
|
+
|
|
15
|
+
### Example
|
|
16
|
+
|
|
17
|
+
```typescript
|
|
18
|
+
import {
|
|
19
|
+
AdminConnectionsApi,
|
|
20
|
+
Configuration,
|
|
21
|
+
CreateBypassRequest
|
|
22
|
+
} from '@rebornteam/reborn-api';
|
|
23
|
+
|
|
24
|
+
const configuration = new Configuration();
|
|
25
|
+
const apiInstance = new AdminConnectionsApi(configuration);
|
|
26
|
+
|
|
27
|
+
let createBypassRequest: CreateBypassRequest; //
|
|
28
|
+
|
|
29
|
+
const { status, data } = await apiInstance.createBypass(
|
|
30
|
+
createBypassRequest
|
|
31
|
+
);
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
### Parameters
|
|
35
|
+
|
|
36
|
+
|Name | Type | Description | Notes|
|
|
37
|
+
|------------- | ------------- | ------------- | -------------|
|
|
38
|
+
| **createBypassRequest** | **CreateBypassRequest**| | |
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
### Return type
|
|
42
|
+
|
|
43
|
+
**AdminConnectionBypassResponse**
|
|
44
|
+
|
|
45
|
+
### Authorization
|
|
46
|
+
|
|
47
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
48
|
+
|
|
49
|
+
### HTTP request headers
|
|
50
|
+
|
|
51
|
+
- **Content-Type**: application/json
|
|
52
|
+
- **Accept**: application/json
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
### HTTP response details
|
|
56
|
+
| Status code | Description | Response headers |
|
|
57
|
+
|-------------|-------------|------------------|
|
|
58
|
+
|**200** | Connection bypass created successfully | - |
|
|
59
|
+
|**400** | Invalid request body | - |
|
|
60
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
61
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
62
|
+
|
|
63
|
+
[[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
|
+
# **listConnections**
|
|
66
|
+
> Array<AdminDashboardConnectionResponse> listConnections()
|
|
67
|
+
|
|
68
|
+
Returns a list of recent connections with VPN detection status, bypass information, and associated player data. Optionally filter by epoch timestamp (seconds since Unix epoch).
|
|
69
|
+
|
|
70
|
+
### Example
|
|
71
|
+
|
|
72
|
+
```typescript
|
|
73
|
+
import {
|
|
74
|
+
AdminConnectionsApi,
|
|
75
|
+
Configuration
|
|
76
|
+
} from '@rebornteam/reborn-api';
|
|
77
|
+
|
|
78
|
+
const configuration = new Configuration();
|
|
79
|
+
const apiInstance = new AdminConnectionsApi(configuration);
|
|
80
|
+
|
|
81
|
+
let createdAfter: number; //Filter connections after this epoch timestamp in milliseconds (optional) (default to undefined)
|
|
82
|
+
let createdBefore: number; //Filter connections before this epoch timestamp in milliseconds (optional) (default to undefined)
|
|
83
|
+
let ipAddress: string; //Filter by IP address (optional) (default to undefined)
|
|
84
|
+
let uuid: string; //Filter by player UUID (optional) (default to undefined)
|
|
85
|
+
let isVpn: boolean; //Filter by VPN status (true=VPN, false=not VPN) (optional) (default to undefined)
|
|
86
|
+
let page: number; //Page number for pagination (optional) (default to 1)
|
|
87
|
+
let limit: number; //Maximum number of records to return (optional) (default to 100)
|
|
88
|
+
|
|
89
|
+
const { status, data } = await apiInstance.listConnections(
|
|
90
|
+
createdAfter,
|
|
91
|
+
createdBefore,
|
|
92
|
+
ipAddress,
|
|
93
|
+
uuid,
|
|
94
|
+
isVpn,
|
|
95
|
+
page,
|
|
96
|
+
limit
|
|
97
|
+
);
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
### Parameters
|
|
101
|
+
|
|
102
|
+
|Name | Type | Description | Notes|
|
|
103
|
+
|------------- | ------------- | ------------- | -------------|
|
|
104
|
+
| **createdAfter** | [**number**] | Filter connections after this epoch timestamp in milliseconds | (optional) defaults to undefined|
|
|
105
|
+
| **createdBefore** | [**number**] | Filter connections before this epoch timestamp in milliseconds | (optional) defaults to undefined|
|
|
106
|
+
| **ipAddress** | [**string**] | Filter by IP address | (optional) defaults to undefined|
|
|
107
|
+
| **uuid** | [**string**] | Filter by player UUID | (optional) defaults to undefined|
|
|
108
|
+
| **isVpn** | [**boolean**] | Filter by VPN status (true=VPN, false=not VPN) | (optional) defaults to undefined|
|
|
109
|
+
| **page** | [**number**] | Page number for pagination | (optional) defaults to 1|
|
|
110
|
+
| **limit** | [**number**] | Maximum number of records to return | (optional) defaults to 100|
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
### Return type
|
|
114
|
+
|
|
115
|
+
**Array<AdminDashboardConnectionResponse>**
|
|
116
|
+
|
|
117
|
+
### Authorization
|
|
118
|
+
|
|
119
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
120
|
+
|
|
121
|
+
### HTTP request headers
|
|
122
|
+
|
|
123
|
+
- **Content-Type**: Not defined
|
|
124
|
+
- **Accept**: application/json
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
### HTTP response details
|
|
128
|
+
| Status code | Description | Response headers |
|
|
129
|
+
|-------------|-------------|------------------|
|
|
130
|
+
|**200** | Successfully retrieved connections list | - |
|
|
131
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
132
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
133
|
+
|
|
134
|
+
[[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)
|
|
135
|
+
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# AdminDashboardApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *https://api.smsh.sh*
|
|
4
|
+
|
|
5
|
+
|Method | HTTP request | Description|
|
|
6
|
+
|------------- | ------------- | -------------|
|
|
7
|
+
|[**dashboardStats**](#dashboardstats) | **GET** /admin/dashboard | Get dashboard statistics|
|
|
8
|
+
|
|
9
|
+
# **dashboardStats**
|
|
10
|
+
> AdminGetDashboardStats dashboardStats()
|
|
11
|
+
|
|
12
|
+
Returns aggregate counts for clients, connections, and players in the system.
|
|
13
|
+
|
|
14
|
+
### Example
|
|
15
|
+
|
|
16
|
+
```typescript
|
|
17
|
+
import {
|
|
18
|
+
AdminDashboardApi,
|
|
19
|
+
Configuration
|
|
20
|
+
} from '@rebornteam/reborn-api';
|
|
21
|
+
|
|
22
|
+
const configuration = new Configuration();
|
|
23
|
+
const apiInstance = new AdminDashboardApi(configuration);
|
|
24
|
+
|
|
25
|
+
const { status, data } = await apiInstance.dashboardStats();
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
### Parameters
|
|
29
|
+
This endpoint does not have any parameters.
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
### Return type
|
|
33
|
+
|
|
34
|
+
**AdminGetDashboardStats**
|
|
35
|
+
|
|
36
|
+
### Authorization
|
|
37
|
+
|
|
38
|
+
[CognitoAuth](../README.md#CognitoAuth)
|
|
39
|
+
|
|
40
|
+
### HTTP request headers
|
|
41
|
+
|
|
42
|
+
- **Content-Type**: Not defined
|
|
43
|
+
- **Accept**: application/json
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
### HTTP response details
|
|
47
|
+
| Status code | Description | Response headers |
|
|
48
|
+
|-------------|-------------|------------------|
|
|
49
|
+
|**200** | Successfully retrieved dashboard statistics | - |
|
|
50
|
+
|**401** | Unauthorized - Authentication required | - |
|
|
51
|
+
|**403** | Forbidden - CognitoAdministrator role required | - |
|
|
52
|
+
|
|
53
|
+
[[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)
|
|
54
|
+
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# AdminDashboardConnectionResponse
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**id** | **number** | | [default to undefined]
|
|
9
|
+
**ipAddress** | **string** | | [default to undefined]
|
|
10
|
+
**location** | **string** | | [default to undefined]
|
|
11
|
+
**isVpn** | **boolean** | | [default to undefined]
|
|
12
|
+
**isBypassed** | **boolean** | | [default to undefined]
|
|
13
|
+
**bypassExpiresAt** | **string** | | [optional] [default to undefined]
|
|
14
|
+
**playerUuid** | **string** | | [optional] [default to undefined]
|
|
15
|
+
**lastSeen** | **string** | | [optional] [default to undefined]
|
|
16
|
+
**percentPositive** | **number** | | [default to undefined]
|
|
17
|
+
**numberOfChecks** | **number** | | [default to undefined]
|
|
18
|
+
|
|
19
|
+
## Example
|
|
20
|
+
|
|
21
|
+
```typescript
|
|
22
|
+
import { AdminDashboardConnectionResponse } from '@rebornteam/reborn-api';
|
|
23
|
+
|
|
24
|
+
const instance: AdminDashboardConnectionResponse = {
|
|
25
|
+
id,
|
|
26
|
+
ipAddress,
|
|
27
|
+
location,
|
|
28
|
+
isVpn,
|
|
29
|
+
isBypassed,
|
|
30
|
+
bypassExpiresAt,
|
|
31
|
+
playerUuid,
|
|
32
|
+
lastSeen,
|
|
33
|
+
percentPositive,
|
|
34
|
+
numberOfChecks,
|
|
35
|
+
};
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# AdminGetDashboardStats
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
## Properties
|
|
5
|
+
|
|
6
|
+
Name | Type | Description | Notes
|
|
7
|
+
------------ | ------------- | ------------- | -------------
|
|
8
|
+
**totalPlayers** | **number** | | [default to undefined]
|
|
9
|
+
**totalConnections** | **number** | | [default to undefined]
|
|
10
|
+
**totalClients** | **number** | | [default to undefined]
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
import { AdminGetDashboardStats } from '@rebornteam/reborn-api';
|
|
16
|
+
|
|
17
|
+
const instance: AdminGetDashboardStats = {
|
|
18
|
+
totalPlayers,
|
|
19
|
+
totalConnections,
|
|
20
|
+
totalClients,
|
|
21
|
+
};
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# ApplyPunishmentRequest
|
|
2
|
+
|
|
3
|
+
Request to apply a punishment to a player
|
|
4
|
+
|
|
5
|
+
## Properties
|
|
6
|
+
|
|
7
|
+
Name | Type | Description | Notes
|
|
8
|
+
------------ | ------------- | ------------- | -------------
|
|
9
|
+
**playerUuid** | **string** | Player UUID to punish | [default to undefined]
|
|
10
|
+
**reason** | **string** | Reason for the punishment | [default to undefined]
|
|
11
|
+
**type** | **string** | Type of punishment | [default to undefined]
|
|
12
|
+
**severity** | **number** | Severity level of the punishment (1-10) | [default to undefined]
|
|
13
|
+
**createdBy** | **string** | Staff member applying the punishment | [default to undefined]
|
|
14
|
+
**durationSeconds** | **number** | Duration of the punishment in seconds. Null means permanent. | [optional] [default to undefined]
|
|
15
|
+
|
|
16
|
+
## Example
|
|
17
|
+
|
|
18
|
+
```typescript
|
|
19
|
+
import { ApplyPunishmentRequest } from '@rebornteam/reborn-api';
|
|
20
|
+
|
|
21
|
+
const instance: ApplyPunishmentRequest = {
|
|
22
|
+
playerUuid,
|
|
23
|
+
reason,
|
|
24
|
+
type,
|
|
25
|
+
severity,
|
|
26
|
+
createdBy,
|
|
27
|
+
durationSeconds,
|
|
28
|
+
};
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|