Add /api/version documentation
Signed-off-by: DL6ER <dl6er@dl6er.de>
This commit is contained in:
parent
afb154e402
commit
0758dc9cc7
|
@ -254,14 +254,3 @@ components:
|
|||
type: null
|
||||
description: "Additional data (if available)"
|
||||
example: null
|
||||
parameters:
|
||||
logs:
|
||||
dns:
|
||||
nextID:
|
||||
in: query
|
||||
description: (Optional) ID of next line to return
|
||||
name: nextID
|
||||
schema:
|
||||
type: integer
|
||||
required: false
|
||||
example: 219
|
||||
|
|
|
@ -64,3 +64,6 @@ paths:
|
|||
|
||||
/lists:
|
||||
$ref: 'lists.yaml#/components/paths/direct'
|
||||
|
||||
/version:
|
||||
$ref: 'version.yaml#/components/paths/version'
|
||||
|
|
|
@ -0,0 +1,58 @@
|
|||
openapi: 3.0.2
|
||||
components:
|
||||
paths:
|
||||
version:
|
||||
get:
|
||||
summary: Get Pi-hole version
|
||||
description: |
|
||||
Request versions of the individual Pi-hole components
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
oneOf:
|
||||
- $ref: '#/components/schemas/version'
|
||||
|
||||
schemas:
|
||||
version:
|
||||
type: object
|
||||
properties:
|
||||
web:
|
||||
type: object
|
||||
properties:
|
||||
branch:
|
||||
type: string
|
||||
description: web branch
|
||||
example: "master"
|
||||
tag:
|
||||
type: string
|
||||
description: web tag
|
||||
example: "v6.0"
|
||||
core:
|
||||
type: object
|
||||
properties:
|
||||
branch:
|
||||
type: string
|
||||
description: core branch
|
||||
example: "master"
|
||||
tag:
|
||||
type: string
|
||||
description: core tag
|
||||
example: "v6.0"
|
||||
ftl:
|
||||
type: object
|
||||
properties:
|
||||
branch:
|
||||
type: string
|
||||
description: FTL branch
|
||||
example: "master"
|
||||
tag:
|
||||
type: string
|
||||
description: FTL tag
|
||||
example: "v6.0"
|
||||
date:
|
||||
type: string
|
||||
description: FTL build time
|
||||
example: "2021-05-12 21:04:55 +0200"
|
Loading…
Reference in New Issue