2024-11-26 04:45:06 +00:00
|
|
|
openapi: 3.1.0
|
2024-11-26 01:22:45 +00:00
|
|
|
info:
|
2024-11-26 03:06:12 +00:00
|
|
|
title: StrafesNET Maps - OpenAPI 3.0
|
|
|
|
description: Browse and manage maps.
|
2024-11-26 01:22:45 +00:00
|
|
|
version: 0.1.0
|
|
|
|
servers:
|
2024-11-26 03:06:12 +00:00
|
|
|
- url: https://maps.strafes.net/v1
|
2024-11-26 01:22:45 +00:00
|
|
|
tags:
|
2024-11-26 04:45:06 +00:00
|
|
|
- name: Maps
|
|
|
|
description: Map operations
|
2024-11-26 01:22:45 +00:00
|
|
|
paths:
|
2024-11-26 04:45:06 +00:00
|
|
|
/maps:
|
2024-11-26 01:22:45 +00:00
|
|
|
get:
|
2024-11-26 04:45:06 +00:00
|
|
|
summary: Get list of maps
|
|
|
|
operationId: listMaps
|
2024-11-26 01:22:45 +00:00
|
|
|
tags:
|
2024-11-26 04:45:06 +00:00
|
|
|
- Maps
|
2024-11-26 01:22:45 +00:00
|
|
|
parameters:
|
|
|
|
- name: page
|
|
|
|
in: query
|
|
|
|
required: true
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/Pagination"
|
|
|
|
- name: filter
|
|
|
|
in: query
|
|
|
|
required: false
|
|
|
|
schema:
|
2024-11-26 04:45:06 +00:00
|
|
|
$ref: "#/components/schemas/MapFilter"
|
2024-11-26 01:22:45 +00:00
|
|
|
responses:
|
|
|
|
"200":
|
|
|
|
description: Successful response
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
type: array
|
|
|
|
items:
|
2024-11-26 04:45:06 +00:00
|
|
|
$ref: "#/components/schemas/Map"
|
2024-11-26 01:22:45 +00:00
|
|
|
default:
|
|
|
|
description: General Error
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/Error"
|
2024-11-26 04:45:06 +00:00
|
|
|
/maps/{MapID}:
|
2024-11-26 01:22:45 +00:00
|
|
|
get:
|
2024-11-26 04:45:06 +00:00
|
|
|
summary: Retrieve map with ID
|
|
|
|
operationId: getMap
|
2024-11-26 01:22:45 +00:00
|
|
|
tags:
|
2024-11-26 04:45:06 +00:00
|
|
|
- Maps
|
2024-11-26 01:22:45 +00:00
|
|
|
parameters:
|
2024-11-26 04:45:06 +00:00
|
|
|
- name: MapID
|
2024-11-26 01:22:45 +00:00
|
|
|
in: path
|
|
|
|
required: true
|
|
|
|
schema:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
|
|
|
responses:
|
|
|
|
"200":
|
|
|
|
description: Successful response
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
2024-11-26 04:45:06 +00:00
|
|
|
$ref: "#/components/schemas/Map"
|
2024-11-26 01:22:45 +00:00
|
|
|
default:
|
|
|
|
description: General Error
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
$ref: "#/components/schemas/Error"
|
|
|
|
components:
|
|
|
|
schemas:
|
|
|
|
User:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
ID:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
|
|
|
Username:
|
|
|
|
type: string
|
|
|
|
StateID:
|
|
|
|
type: integer
|
|
|
|
format: int32
|
|
|
|
Map:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
ID:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
|
|
|
DisplayName:
|
|
|
|
type: string
|
|
|
|
Creator:
|
|
|
|
type: string
|
|
|
|
GameID:
|
|
|
|
type: integer
|
|
|
|
format: int32
|
|
|
|
Date:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
2024-11-26 04:45:06 +00:00
|
|
|
MapFilter:
|
2024-11-26 01:22:45 +00:00
|
|
|
type: object
|
2024-11-26 03:06:12 +00:00
|
|
|
properties:
|
2024-11-26 01:22:45 +00:00
|
|
|
ID:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
2024-11-26 04:45:06 +00:00
|
|
|
DisplayName:
|
|
|
|
type: string
|
|
|
|
Creator:
|
|
|
|
type: string
|
2024-11-26 01:22:45 +00:00
|
|
|
GameID:
|
|
|
|
type: integer
|
|
|
|
format: int32
|
2024-11-26 04:45:06 +00:00
|
|
|
Date:
|
2024-11-26 01:22:45 +00:00
|
|
|
type: integer
|
|
|
|
format: int64
|
|
|
|
Pagination:
|
|
|
|
type: object
|
|
|
|
required:
|
|
|
|
- Page
|
|
|
|
- Limit
|
|
|
|
properties:
|
|
|
|
Page:
|
|
|
|
type: integer
|
|
|
|
format: int32
|
|
|
|
minimum: 1
|
|
|
|
Limit:
|
|
|
|
type: integer
|
|
|
|
format: int32
|
|
|
|
minimum: 1
|
|
|
|
maximum: 100
|
|
|
|
Error:
|
|
|
|
description: Represents error object
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
code:
|
|
|
|
type: integer
|
|
|
|
format: int64
|
|
|
|
message:
|
|
|
|
type: string
|
|
|
|
required:
|
|
|
|
- code
|
2024-11-26 03:06:12 +00:00
|
|
|
- message
|