feat(openapi): refactor into indiv. files to match API & tpl routing

This commit is contained in:
psychobunny
2020-09-29 11:49:17 -04:00
parent 9c5b690799
commit 84f5e4cf3d
119 changed files with 7934 additions and 8224 deletions

View File

@@ -0,0 +1,23 @@
get:
tags:
- admin
summary: Get homepage settings
responses:
"200":
description: ""
content:
application/json:
schema:
allOf:
- type: object
properties:
routes:
type: array
items:
type: object
properties:
route:
type: string
name:
type: string
- $ref: ../../../components/schemas/CommonProps.yaml#/CommonProps

View File

@@ -0,0 +1,35 @@
get:
tags:
- admin
summary: Get language settings
responses:
"200":
description: A JSON object containing available languages and settings
content:
application/json:
schema:
allOf:
- type: object
properties:
languages:
type: array
items:
type: object
properties:
name:
type: string
description: Localised name of the language
code:
type: string
description: A language code (similar to ISO-639)
dir:
type: string
description: Directionality of the language
enum: [ltr, rtl]
selected:
type: boolean
description: Denotes the currently selected default system language on the forum
autoDetectLang:
type: integer
description: Whether the forum will attempt to guess language based on browser's `Accept-Language` header
- $ref: ../../../components/schemas/CommonProps.yaml#/CommonProps

View File

@@ -0,0 +1,107 @@
get:
tags:
- admin
summary: Get navigation bar settings
responses:
"200":
description: A JSON object containing navigation settings
content:
application/json:
schema:
allOf:
- type: object
properties:
enabled:
type: array
items:
type: object
properties:
route:
type: string
description: Relative URL to the page the navigation item goes to
title:
type: string
description: Tooltip text
enabled:
type: boolean
iconClass:
type: string
description: A FontAwesome icon string
textClass:
type: string
description: HTML class applied to the text label for this navigation item
text:
type: string
description: Label text for this navigation item
order:
type: integer
description: Ordinality of this item, lower value appears earlier
groups:
type: array
items:
type: object
properties:
displayName:
type: string
selected:
type: boolean
index:
type: integer
description: Seemingly identical to order, but an integer instead of a string
selected:
type: boolean
available:
type: array
items:
type: object
properties:
id:
type: string
description: Unique ID that will be added to the navigation element's `id` property in the DOM
route:
type: string
description: Relative URL to the page the navigation item goes to
title:
type: string
description: Tooltip text
enabled:
type: boolean
iconClass:
type: string
description: A FontAwesome icon string
textClass:
type: string
description: HTML class applied to the text label for this navigation item
text:
type: string
description: Label text for this navigation item
core:
type: boolean
description: Whether the navigation item is provided by core or not (a plugin)
groups:
type: array
items:
type: object
properties:
name:
type: string
displayName:
type: string
properties:
type: object
properties:
targetBlank:
type: boolean
groups:
type: array
items:
type: object
properties:
name:
type: string
displayName:
type: string
navigation:
type: array
description: A clone of `enabled`
- $ref: ../../../components/schemas/CommonProps.yaml#/CommonProps

View File

@@ -0,0 +1,28 @@
get:
tags:
- admin
summary: Get post social sharing settings
responses:
"200":
description: "A JSON object containing post social sharing settings"
content:
application/json:
schema:
allOf:
- type: object
properties:
posts:
type: array
items:
type: object
properties:
id:
type: string
name:
type: string
class:
type: string
description: A FontAwesome icon string
activated:
type: boolean
- $ref: ../../../components/schemas/CommonProps.yaml#/CommonProps