diff options
Diffstat (limited to 'docs/swagger.json')
| -rw-r--r-- | docs/swagger.json | 130 |
1 files changed, 128 insertions, 2 deletions
diff --git a/docs/swagger.json b/docs/swagger.json index 6fbe02e..f55190e 100644 --- a/docs/swagger.json +++ b/docs/swagger.json | |||
| @@ -222,6 +222,89 @@ | |||
| 222 | } | 222 | } |
| 223 | } | 223 | } |
| 224 | }, | 224 | }, |
| 225 | "/logs/mod": { | ||
| 226 | "get": { | ||
| 227 | "description": "Get mod logs.", | ||
| 228 | "produces": [ | ||
| 229 | "application/json" | ||
| 230 | ], | ||
| 231 | "tags": [ | ||
| 232 | "rankings" | ||
| 233 | ], | ||
| 234 | "parameters": [ | ||
| 235 | { | ||
| 236 | "type": "string", | ||
| 237 | "description": "JWT Token", | ||
| 238 | "name": "Authorization", | ||
| 239 | "in": "header", | ||
| 240 | "required": true | ||
| 241 | } | ||
| 242 | ], | ||
| 243 | "responses": { | ||
| 244 | "200": { | ||
| 245 | "description": "OK", | ||
| 246 | "schema": { | ||
| 247 | "allOf": [ | ||
| 248 | { | ||
| 249 | "$ref": "#/definitions/models.Response" | ||
| 250 | }, | ||
| 251 | { | ||
| 252 | "type": "object", | ||
| 253 | "properties": { | ||
| 254 | "data": { | ||
| 255 | "$ref": "#/definitions/handlers.ScoreLogsResponse" | ||
| 256 | } | ||
| 257 | } | ||
| 258 | } | ||
| 259 | ] | ||
| 260 | } | ||
| 261 | }, | ||
| 262 | "400": { | ||
| 263 | "description": "Bad Request", | ||
| 264 | "schema": { | ||
| 265 | "$ref": "#/definitions/models.Response" | ||
| 266 | } | ||
| 267 | } | ||
| 268 | } | ||
| 269 | } | ||
| 270 | }, | ||
| 271 | "/logs/score": { | ||
| 272 | "get": { | ||
| 273 | "description": "Get score logs of every player.", | ||
| 274 | "produces": [ | ||
| 275 | "application/json" | ||
| 276 | ], | ||
| 277 | "tags": [ | ||
| 278 | "rankings" | ||
| 279 | ], | ||
| 280 | "responses": { | ||
| 281 | "200": { | ||
| 282 | "description": "OK", | ||
| 283 | "schema": { | ||
| 284 | "allOf": [ | ||
| 285 | { | ||
| 286 | "$ref": "#/definitions/models.Response" | ||
| 287 | }, | ||
| 288 | { | ||
| 289 | "type": "object", | ||
| 290 | "properties": { | ||
| 291 | "data": { | ||
| 292 | "$ref": "#/definitions/handlers.ScoreLogsResponse" | ||
| 293 | } | ||
| 294 | } | ||
| 295 | } | ||
| 296 | ] | ||
| 297 | } | ||
| 298 | }, | ||
| 299 | "400": { | ||
| 300 | "description": "Bad Request", | ||
| 301 | "schema": { | ||
| 302 | "$ref": "#/definitions/models.Response" | ||
| 303 | } | ||
| 304 | } | ||
| 305 | } | ||
| 306 | } | ||
| 307 | }, | ||
| 225 | "/maps/{id}/image": { | 308 | "/maps/{id}/image": { |
| 226 | "put": { | 309 | "put": { |
| 227 | "description": "Edit map image with specified map id.", | 310 | "description": "Edit map image with specified map id.", |
| @@ -1260,13 +1343,19 @@ | |||
| 1260 | "handlers.RankingsResponse": { | 1343 | "handlers.RankingsResponse": { |
| 1261 | "type": "object", | 1344 | "type": "object", |
| 1262 | "properties": { | 1345 | "properties": { |
| 1263 | "rankings_mp": { | 1346 | "rankings_multiplayer": { |
| 1347 | "type": "array", | ||
| 1348 | "items": { | ||
| 1349 | "$ref": "#/definitions/models.UserRanking" | ||
| 1350 | } | ||
| 1351 | }, | ||
| 1352 | "rankings_overall": { | ||
| 1264 | "type": "array", | 1353 | "type": "array", |
| 1265 | "items": { | 1354 | "items": { |
| 1266 | "$ref": "#/definitions/models.UserRanking" | 1355 | "$ref": "#/definitions/models.UserRanking" |
| 1267 | } | 1356 | } |
| 1268 | }, | 1357 | }, |
| 1269 | "rankings_sp": { | 1358 | "rankings_singleplayer": { |
| 1270 | "type": "array", | 1359 | "type": "array", |
| 1271 | "items": { | 1360 | "items": { |
| 1272 | "$ref": "#/definitions/models.UserRanking" | 1361 | "$ref": "#/definitions/models.UserRanking" |
| @@ -1285,6 +1374,43 @@ | |||
| 1285 | } | 1374 | } |
| 1286 | } | 1375 | } |
| 1287 | }, | 1376 | }, |
| 1377 | "handlers.ScoreLogsResponse": { | ||
| 1378 | "type": "object", | ||
| 1379 | "properties": { | ||
| 1380 | "scores": { | ||
| 1381 | "type": "array", | ||
| 1382 | "items": { | ||
| 1383 | "$ref": "#/definitions/handlers.ScoreLogsResponseDetails" | ||
| 1384 | } | ||
| 1385 | } | ||
| 1386 | } | ||
| 1387 | }, | ||
| 1388 | "handlers.ScoreLogsResponseDetails": { | ||
| 1389 | "type": "object", | ||
| 1390 | "properties": { | ||
| 1391 | "date": { | ||
| 1392 | "type": "string" | ||
| 1393 | }, | ||
| 1394 | "demo_id": { | ||
| 1395 | "type": "string" | ||
| 1396 | }, | ||
| 1397 | "game": { | ||
| 1398 | "$ref": "#/definitions/models.Game" | ||
| 1399 | }, | ||
| 1400 | "map": { | ||
| 1401 | "$ref": "#/definitions/models.MapShort" | ||
| 1402 | }, | ||
| 1403 | "score_count": { | ||
| 1404 | "type": "integer" | ||
| 1405 | }, | ||
| 1406 | "score_time": { | ||
| 1407 | "type": "integer" | ||
| 1408 | }, | ||
| 1409 | "user": { | ||
| 1410 | "$ref": "#/definitions/models.UserShort" | ||
| 1411 | } | ||
| 1412 | } | ||
| 1413 | }, | ||
| 1288 | "handlers.SearchResponse": { | 1414 | "handlers.SearchResponse": { |
| 1289 | "type": "object", | 1415 | "type": "object", |
| 1290 | "properties": { | 1416 | "properties": { |