diff options
Diffstat (limited to 'docs/swagger.json')
| -rw-r--r-- | docs/swagger.json | 104 |
1 files changed, 103 insertions, 1 deletions
diff --git a/docs/swagger.json b/docs/swagger.json index ef422ab..f644288 100644 --- a/docs/swagger.json +++ b/docs/swagger.json | |||
| @@ -222,6 +222,68 @@ | |||
| 222 | } | 222 | } |
| 223 | } | 223 | } |
| 224 | }, | 224 | }, |
| 225 | "/maps/{id}/image": { | ||
| 226 | "put": { | ||
| 227 | "description": "Edit map image with specified map id.", | ||
| 228 | "produces": [ | ||
| 229 | "application/json" | ||
| 230 | ], | ||
| 231 | "tags": [ | ||
| 232 | "maps" | ||
| 233 | ], | ||
| 234 | "parameters": [ | ||
| 235 | { | ||
| 236 | "type": "string", | ||
| 237 | "description": "JWT Token", | ||
| 238 | "name": "Authorization", | ||
| 239 | "in": "header", | ||
| 240 | "required": true | ||
| 241 | }, | ||
| 242 | { | ||
| 243 | "type": "integer", | ||
| 244 | "description": "Map ID", | ||
| 245 | "name": "id", | ||
| 246 | "in": "path", | ||
| 247 | "required": true | ||
| 248 | }, | ||
| 249 | { | ||
| 250 | "description": "Body", | ||
| 251 | "name": "request", | ||
| 252 | "in": "body", | ||
| 253 | "required": true, | ||
| 254 | "schema": { | ||
| 255 | "$ref": "#/definitions/models.EditMapImageRequest" | ||
| 256 | } | ||
| 257 | } | ||
| 258 | ], | ||
| 259 | "responses": { | ||
| 260 | "200": { | ||
| 261 | "description": "OK", | ||
| 262 | "schema": { | ||
| 263 | "allOf": [ | ||
| 264 | { | ||
| 265 | "$ref": "#/definitions/models.Response" | ||
| 266 | }, | ||
| 267 | { | ||
| 268 | "type": "object", | ||
| 269 | "properties": { | ||
| 270 | "data": { | ||
| 271 | "$ref": "#/definitions/models.EditMapImageRequest" | ||
| 272 | } | ||
| 273 | } | ||
| 274 | } | ||
| 275 | ] | ||
| 276 | } | ||
| 277 | }, | ||
| 278 | "400": { | ||
| 279 | "description": "Bad Request", | ||
| 280 | "schema": { | ||
| 281 | "$ref": "#/definitions/models.Response" | ||
| 282 | } | ||
| 283 | } | ||
| 284 | } | ||
| 285 | } | ||
| 286 | }, | ||
| 225 | "/maps/{id}/leaderboards": { | 287 | "/maps/{id}/leaderboards": { |
| 226 | "get": { | 288 | "get": { |
| 227 | "description": "Get map leaderboards with specified id.", | 289 | "description": "Get map leaderboards with specified id.", |
| @@ -337,7 +399,19 @@ | |||
| 337 | "200": { | 399 | "200": { |
| 338 | "description": "OK", | 400 | "description": "OK", |
| 339 | "schema": { | 401 | "schema": { |
| 340 | "$ref": "#/definitions/models.Response" | 402 | "allOf": [ |
| 403 | { | ||
| 404 | "$ref": "#/definitions/models.Response" | ||
| 405 | }, | ||
| 406 | { | ||
| 407 | "type": "object", | ||
| 408 | "properties": { | ||
| 409 | "data": { | ||
| 410 | "$ref": "#/definitions/models.RecordResponse" | ||
| 411 | } | ||
| 412 | } | ||
| 413 | } | ||
| 414 | ] | ||
| 341 | } | 415 | } |
| 342 | }, | 416 | }, |
| 343 | "400": { | 417 | "400": { |
| @@ -1040,6 +1114,17 @@ | |||
| 1040 | } | 1114 | } |
| 1041 | } | 1115 | } |
| 1042 | }, | 1116 | }, |
| 1117 | "models.EditMapImageRequest": { | ||
| 1118 | "type": "object", | ||
| 1119 | "required": [ | ||
| 1120 | "image" | ||
| 1121 | ], | ||
| 1122 | "properties": { | ||
| 1123 | "image": { | ||
| 1124 | "type": "string" | ||
| 1125 | } | ||
| 1126 | } | ||
| 1127 | }, | ||
| 1043 | "models.EditMapSummaryRequest": { | 1128 | "models.EditMapSummaryRequest": { |
| 1044 | "type": "object", | 1129 | "type": "object", |
| 1045 | "required": [ | 1130 | "required": [ |
| @@ -1077,6 +1162,9 @@ | |||
| 1077 | "id": { | 1162 | "id": { |
| 1078 | "type": "integer" | 1163 | "type": "integer" |
| 1079 | }, | 1164 | }, |
| 1165 | "is_coop": { | ||
| 1166 | "type": "boolean" | ||
| 1167 | }, | ||
| 1080 | "name": { | 1168 | "name": { |
| 1081 | "type": "string" | 1169 | "type": "string" |
| 1082 | } | 1170 | } |
| @@ -1105,6 +1193,9 @@ | |||
| 1105 | "image": { | 1193 | "image": { |
| 1106 | "type": "string" | 1194 | "type": "string" |
| 1107 | }, | 1195 | }, |
| 1196 | "is_coop": { | ||
| 1197 | "type": "boolean" | ||
| 1198 | }, | ||
| 1108 | "map_name": { | 1199 | "map_name": { |
| 1109 | "type": "string" | 1200 | "type": "string" |
| 1110 | } | 1201 | } |
| @@ -1235,6 +1326,17 @@ | |||
| 1235 | } | 1326 | } |
| 1236 | } | 1327 | } |
| 1237 | }, | 1328 | }, |
| 1329 | "models.RecordResponse": { | ||
| 1330 | "type": "object", | ||
| 1331 | "properties": { | ||
| 1332 | "score_count": { | ||
| 1333 | "type": "integer" | ||
| 1334 | }, | ||
| 1335 | "score_time": { | ||
| 1336 | "type": "integer" | ||
| 1337 | } | ||
| 1338 | } | ||
| 1339 | }, | ||
| 1238 | "models.Response": { | 1340 | "models.Response": { |
| 1239 | "type": "object", | 1341 | "type": "object", |
| 1240 | "properties": { | 1342 | "properties": { |