Skip to content

Files

File upload and management operations


Upload Image

POST
/api/v1/files/images

Upload image file (supports jpg, jpeg, png, gif, webp, max 10MB)

Authorizations

BearerAuth

Bearer token authentication. Can be either a user JWT token or an API key.
Example: Authorization: Bearer <token_or_key>

TypeHTTP (bearer)

Request Body

multipart/form-data
object

Image file

Format"binary"

Responses

Upload successful

application/json
JSON
{
"code": 0,
"msg": "ok",
"data": {
"file_key": "string"
}
}

Playground

Server
Authorization
Body

Samples


Upload Document

POST
/api/v1/files/documents

Upload document file (max 10MB)

Authorizations

BearerAuth

Bearer token authentication. Can be either a user JWT token or an API key.
Example: Authorization: Bearer <token_or_key>

TypeHTTP (bearer)

Request Body

multipart/form-data
object

Document file

Format"binary"

Responses

Upload successful

application/json
JSON
{
"code": 0,
"msg": "ok",
"data": {
"file_id": "string"
}
}

Playground

Server
Authorization
Body

Samples


Powered by VitePress OpenAPI