nyanimedb/api/paths/titles.yaml

83 lines
1.8 KiB
YAML

get:
summary: Get titles
parameters:
- $ref: "../parameters/cursor.yaml"
- $ref: "../parameters/title_sort.yaml"
- in: query
name: sort_forward
schema:
type: boolean
default: true
- in: query
name: ext_search
schema:
type: boolean
default: false
- in: query
name: word
schema:
type: string
- in: query
name: status
schema:
type: array
items:
$ref: '../schemas/enums/TitleStatus.yaml'
description: List of title statuses to filter
style: form
explode: false
- in: query
name: rating
schema:
type: number
format: double
- in: query
name: release_year
schema:
type: integer
format: int32
- in: query
name: release_season
schema:
$ref: '../schemas/enums/ReleaseSeason.yaml'
- in: query
name: limit
schema:
type: integer
format: int32
default: 10
- in: query
name: offset
schema:
type: integer
format: int32
default: 0
- in: query
name: fields
schema:
type: string
default: all
responses:
'200':
description: List of titles with cursor
content:
application/json:
schema:
type: object
properties:
data:
type: array
items:
$ref: '../schemas/Title.yaml'
description: List of titles
cursor:
$ref: '../schemas/CursorObj.yaml'
required:
- data
- cursor
'204':
description: No titles found
'400':
description: Request params are not correct
'500':
description: Unknown server error