Files
BeamMP-Server/openapi.yml
Lion Kortlepel b46dc664c6 http: add /ready
2022-05-23 18:30:47 +02:00

54 lines
1.4 KiB
YAML

openapi: "3.0.2"
info:
title: BeamMP-Server
version: "1.0"
description: |
The BeamMP-Server optionally runs an HTTP server
which can be used to query information about the server's
status, health, players, etc.
servers:
- url: http://localhost:{port}/v1
description: local BeamMP-Server
variables:
port:
default: "8000"
paths:
/ready:
get:
summary: whether the server has started fully
description: |
True once all subsystems have started up.
This doesn't tell you whether they're healthy,
check /health for that information.
responses:
"200":
description: OK
content:
"text/plain":
schema:
type: boolean
/health:
get:
summary: health of the server's systems
responses:
"200":
description: OK
content:
"application/json":
schema:
type: object
properties:
healthy:
type: boolean
good:
type: array
items:
type: string
example: "Heartbeat"
bad:
type: array
items:
type: string
example: "ResourceManager"