67 lines
1.5 KiB
YAML
67 lines
1.5 KiB
YAML
Unauthorized:
|
|
description: 未授权访问
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: UNAUTHORIZED
|
|
message: 未授权访问,请先登录
|
|
|
|
Forbidden:
|
|
description: 禁止访问
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: FORBIDDEN
|
|
message: 您没有权限执行此操作
|
|
|
|
NotFound:
|
|
description: 资源未找到
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: NOT_FOUND
|
|
message: 请求的资源不存在
|
|
|
|
ValidationError:
|
|
description: 参数验证失败
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: VALIDATION_ERROR
|
|
message: 参数验证失败
|
|
details:
|
|
field: 错误描述
|
|
|
|
TooManyRequests:
|
|
description: 请求过多
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: TOO_MANY_REQUESTS
|
|
message: 请求过于频繁,请稍后再试
|
|
|
|
InternalError:
|
|
description: 服务器内部错误
|
|
content:
|
|
application/json:
|
|
schema:
|
|
$ref: './schemas.yaml#/Error'
|
|
example:
|
|
error:
|
|
code: INTERNAL_ERROR
|
|
message: 服务器内部错误,请稍后再试
|