Merge branch 'dev' into dev-karas
Need to get a fresh openapi description for auth
This commit is contained in:
commit
3bbd2c2818
30 changed files with 1247 additions and 370 deletions
|
|
@ -122,6 +122,53 @@ paths:
|
|||
description: Unknown server error
|
||||
security:
|
||||
- JwtAuthCookies: []
|
||||
/users/:
|
||||
get:
|
||||
summary: 'Search user by nickname or dispname (both in one param), response is always sorted by id'
|
||||
parameters:
|
||||
- name: word
|
||||
in: query
|
||||
schema:
|
||||
type: string
|
||||
- name: limit
|
||||
in: query
|
||||
schema:
|
||||
type: integer
|
||||
format: int32
|
||||
default: 10
|
||||
- name: cursor_id
|
||||
in: query
|
||||
description: pass cursor naked
|
||||
schema:
|
||||
type: integer
|
||||
format: int32
|
||||
default: 1
|
||||
responses:
|
||||
'200':
|
||||
description: List of users with cursor
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: object
|
||||
properties:
|
||||
data:
|
||||
description: List of users
|
||||
type: array
|
||||
items:
|
||||
$ref: '#/components/schemas/User'
|
||||
cursor:
|
||||
type: integer
|
||||
format: int64
|
||||
default: 1
|
||||
required:
|
||||
- data
|
||||
- cursor
|
||||
'204':
|
||||
description: No users found
|
||||
'400':
|
||||
description: Request params are not correct
|
||||
'500':
|
||||
description: Unknown server error
|
||||
'/users/{user_id}':
|
||||
get:
|
||||
operationId: getUsersId
|
||||
|
|
@ -348,6 +395,9 @@ paths:
|
|||
rate:
|
||||
type: integer
|
||||
format: int32
|
||||
ftime:
|
||||
type: string
|
||||
format: date-time
|
||||
required:
|
||||
- title_id
|
||||
- status
|
||||
|
|
@ -431,6 +481,9 @@ paths:
|
|||
rate:
|
||||
type: integer
|
||||
format: int32
|
||||
ftime:
|
||||
type: string
|
||||
format: date-time
|
||||
responses:
|
||||
'200':
|
||||
description: Title successfully updated
|
||||
|
|
@ -480,6 +533,42 @@ paths:
|
|||
description: Internal server error
|
||||
security:
|
||||
- XsrfAuthHeader: []
|
||||
/media/upload:
|
||||
post:
|
||||
summary: 'Upload an image (PNG, JPEG, or WebP)'
|
||||
description: |
|
||||
Uploads a single image file. Supported formats: **PNG**, **JPEG/JPG**, **WebP**.
|
||||
requestBody:
|
||||
required: true
|
||||
content:
|
||||
encoding:
|
||||
image:
|
||||
contentType: 'image/png, image/jpeg, image/webp'
|
||||
multipart/form-data:
|
||||
schema:
|
||||
image:
|
||||
type: string
|
||||
format: binary
|
||||
description: 'Image file (PNG, JPEG, or WebP)'
|
||||
responses:
|
||||
'200':
|
||||
description: Image uploaded successfully
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
$ref: '#/components/schemas/Image'
|
||||
'400':
|
||||
description: 'Bad request — e.g., invalid/malformed image, empty file'
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
type: string
|
||||
'415':
|
||||
description: |
|
||||
Unsupported Media Type — e.g., request `Content-Type` is not `multipart/form-data`,
|
||||
or the `image` part has an unsupported `Content-Type` (not image/png, image/jpeg, or image/webp)
|
||||
'500':
|
||||
description: Internal server error
|
||||
components:
|
||||
parameters:
|
||||
cursor:
|
||||
|
|
@ -593,6 +682,11 @@ components:
|
|||
example:
|
||||
- Attack on Titan
|
||||
- AoT
|
||||
title_desc:
|
||||
description: 'Localized description. Key = language (ISO 639-1), value = description.'
|
||||
type: object
|
||||
additionalProperties:
|
||||
type: string
|
||||
studio:
|
||||
$ref: '#/components/schemas/Studio'
|
||||
tags:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue