{
  "openapi": "3.0.3",
  "servers": [
    {
      "description": "唯一公网 API 入口（HTTPS）",
      "url": "https://miaoassistant.api.tolike.com.cn"
    }
  ],
  "paths": {
    "/api/admin/announcements/{id}": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "编辑公告",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Announcement"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_announcements_id_",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AnnouncementSave"
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "删除公告",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_announcements_id_"
      }
    },
    "/api/admin/titles/{id}": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "status=APPROVED/REJECTED；不能设为PENDING；通过后写入用户头衔。",
        "summary": "审核头衔申请",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "status",
            "in": "query",
            "schema": {
              "enum": [
                "APPROVED",
                "REJECTED"
              ],
              "type": "string"
            },
            "description": "状态值，具体枚举见接口说明"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/TitleItem"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_titles_id_"
      }
    },
    "/api/client/users/me": {
      "get": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "当前用户",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserProfile"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "get_api_client_users_me"
      }
    },
    "/api/client/users/{id}/avatar": {
      "get": {
        "security": [],
        "description": "id 为账号ID或用户名，不是内部数字主键；无头像返回404；缓存7天。",
        "summary": "获取头像",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "image/*": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_users_id_avatar"
      }
    },
    "/api/admin/stats": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "todayUsers/totalUsers 实际统计监控设备，不是注册账号；online 为两分钟内活跃且启用设备。",
        "summary": "业务统计",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Stats"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_stats"
      }
    },
    "/api/client/chat/messages/{id}/pin": {
      "patch": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "用户角色仅AUTHOR/SYSTEM_ADMIN允许，普通用户拒绝；成功广播/topic/chat。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "置顶聊天消息",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "pinned",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否置顶"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/ChatItem"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "patch_api_client_chat_messages_id_pin"
      }
    },
    "/api/client/login": {
      "post": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "区别于用户登录；返回卡密会话token，默认有效期由server配置决定。 正常登录不返回bypass字段。该接口不替代validate-card的使用次数/云端设备授权校验。",
        "summary": "卡密设备会话登录",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "nullable": true,
                      "$ref": "#/components/schemas/LicenseSession"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "post_api_client_login",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClientLogin"
              }
            }
          }
        }
      }
    },
    "/api/client/chat/messages": {
      "post": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "非空，trim后最多500字符；禁言/封禁不能发送。成功广播/topic/chat。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "发送消息",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/ChatItem"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "post_api_client_chat_messages",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "content": {
                    "description": "内容；聊天文本trim后1–500字符",
                    "type": "string",
                    "example": "你好"
                  }
                },
                "type": "object",
                "required": [
                  "content"
                ]
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "after<=0 最近100条并按ID升序；after>0 返回ID更大的最多200条。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "用户聊天消息",
        "parameters": [
          {
            "required": false,
            "name": "after",
            "in": "query",
            "schema": {
              "format": "int64",
              "type": "integer",
              "default": 0
            },
            "description": "增量消息ID游标，<=0返回最近100条"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/ChatItem"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "get_api_client_chat_messages"
      }
    },
    "/api/admin/devices/{id}/enabled": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "启停绑定设备",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "enabled",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否启用 / 授权"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_devices_id_enabled"
      }
    },
    "/api/client/presets": {
      "post": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "上传开关需开放；name 1–80字；description默认空，publicVisible默认true；.mnd文件1B–2MB。上传仅校验扩展名和大小，解密有效性由预览检查。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。 注意Spring当前未显式配置multipart限制，默认单文件1MB可能先于业务2MB上限生效；建议控制在1MB内。",
        "summary": "上传预设",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetClient"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "post_api_client_presets",
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "properties": {
                  "description": {
                    "description": "简介",
                    "type": "string"
                  },
                  "name": {
                    "description": "名称",
                    "type": "string"
                  },
                  "publicVisible": {
                    "description": "上传者是否允许公开；还需published=true才进入公开列表",
                    "type": "boolean"
                  },
                  "file": {
                    "format": "binary",
                    "type": "string",
                    "description": "上传文件；头像最大200KB，预设业务2MB且注意Spring默认1MB限制"
                  }
                },
                "type": "object",
                "required": [
                  "name",
                  "file"
                ]
              }
            }
          }
        }
      },
      "get": {
        "security": [],
        "description": "仅published=true 且 publicVisible=true。",
        "summary": "公开预设",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/PresetClient"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_presets"
      }
    },
    "/api/reviewer/presets/{id}/download": {
      "get": {
        "security": [
          {
            "reviewer": []
          }
        ],
        "description": "返回原始MND；新接入优先用preview，不增加下载次数。",
        "summary": "兼容旧版审核下载",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "审核员"
        ],
        "operationId": "get_api_reviewer_presets_id_download"
      }
    },
    "/api/admin/chat/messages": {
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "全量删除，不可恢复。",
        "summary": "清空所有聊天消息",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_chat_messages"
      },
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "最近300条，ID倒序。",
        "summary": "管理聊天消息",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/AdminChatItem"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_chat_messages"
      }
    },
    "/api/client/users/register": {
      "post": {
        "security": [],
        "description": "账号2–20位文字/字母/数字/_/-；密码6–64位且两次相同；头像≤200KB；设备字段兼容但不绑定。注册不自动登录。",
        "summary": "注册用户",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserProfile"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "post_api_client_users_register",
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "properties": {
                  "deviceCode": {
                    "description": "设备唯一标识；请保持稳定",
                    "type": "string"
                  },
                  "password": {
                    "description": "密码；仅发送到受信任服务器，不写日志",
                    "minLength": 6,
                    "maxLength": 64,
                    "type": "string",
                    "example": "<PASSWORD>"
                  },
                  "confirmPassword": {
                    "description": "确认密码，必须与新密码一致",
                    "minLength": 6,
                    "maxLength": 64,
                    "type": "string",
                    "example": "<PASSWORD>"
                  },
                  "username": {
                    "description": "用户名 / 登录账号",
                    "type": "string"
                  },
                  "deviceName": {
                    "description": "设备显示名称",
                    "type": "string"
                  },
                  "avatar": {
                    "format": "binary",
                    "type": "string",
                    "description": "可选头像文件，最大200KB"
                  }
                },
                "type": "object",
                "required": [
                  "username",
                  "password",
                  "confirmPassword"
                ]
              }
            }
          }
        }
      }
    },
    "/api/reviewer/presets/{id}/decision": {
      "post": {
        "security": [
          {
            "reviewer": []
          }
        ],
        "description": "approved 必须显式传递，否则默认false；name/description可选。当前线上只保存published，无独立驳回枚举。",
        "summary": "审核决定",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetSummary"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "审核员"
        ],
        "operationId": "post_api_reviewer_presets_id_decision",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "description": {
                    "description": "简介",
                    "type": "string",
                    "example": "简介"
                  },
                  "name": {
                    "description": "名称",
                    "type": "string",
                    "example": "示例预设"
                  },
                  "approved": {
                    "description": "是否审核通过；必须显式传入，否则默认false",
                    "type": "boolean",
                    "example": true
                  }
                },
                "type": "object"
              }
            }
          }
        }
      }
    },
    "/api/admin/monitored-devices/{id}/enabled": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "设备码授权开关",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "enabled",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否启用 / 授权"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_monitored_devices_id_enabled"
      }
    },
    "/api/admin/devices/{id}/rebind": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "重新绑定后启用该设备；同一卡密下设备码不能重复。",
        "summary": "重绑设备",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Device"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_devices_id_rebind",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeviceRebind"
              }
            }
          }
        }
      }
    },
    "/api/client/users/login": {
      "post": {
        "security": [],
        "description": "撤销旧用户会话；新会话3天有效；deviceCode可省略。",
        "summary": "用户登录",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserLogin"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "post_api_client_users_login",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "deviceCode": {
                    "description": "设备唯一标识；请保持稳定",
                    "type": "string",
                    "example": ""
                  },
                  "login": {
                    "description": "用户名或九位账号ID",
                    "type": "string",
                    "example": "用户名或账号ID"
                  },
                  "password": {
                    "description": "密码；仅发送到受信任服务器，不写日志",
                    "type": "string",
                    "example": "<PASSWORD>"
                  }
                },
                "type": "object",
                "required": [
                  "login",
                  "password"
                ]
              }
            }
          }
        }
      }
    },
    "/api/admin/reviewers/generate": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "count 1–100；明文密码仅本次返回。",
        "summary": "生成审核员",
        "parameters": [
          {
            "required": false,
            "name": "count",
            "in": "query",
            "schema": {
              "format": "int64",
              "minimum": 1,
              "maximum": 100,
              "default": 1,
              "type": "integer"
            },
            "description": "生成数量或结果数量"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/Credentials"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_reviewers_generate"
      }
    },
    "/api/client/announcements": {
      "get": {
        "security": [],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "公开公告",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/Announcement"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_announcements"
      }
    },
    "/api/admin/reviewers/{id}/reset-password": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "撤销旧会话；返回一次性明文 password。",
        "summary": "重置审核员密码",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Credentials"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_reviewers_id_reset_password"
      }
    },
    "/api/admin/announcements": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "新建公告",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Announcement"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_announcements",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AnnouncementSave"
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "公告列表",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/Announcement"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_announcements"
      }
    },
    "/api/admin/monitored-devices": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "额外返回 online、activity：在线为两分钟内访问；activity 为高/中/低。",
        "summary": "设备访问列表",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/MonitoredDevice"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_monitored_devices"
      }
    },
    "/api/client/device-status": {
      "post": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "新设备默认未启用；更新最后访问和IP。",
        "summary": "登记并查询设备授权",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/DeviceState"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "post_api_client_device_status",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeviceStatus"
              }
            }
          }
        }
      }
    },
    "/api/admin/prediction/status": {
      "get": {
        "tags": [
          "智能联想运维"
        ],
        "description": "管理员鉴权；不返回模型密钥或输入内容。恢复不重置预算，不解除异常锁定。",
        "summary": "智能联想预算与状态",
        "security": [
          {
            "admin": []
          }
        ],
        "responses": {
          "200": {
            "description": "操作结果",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/api/client/users/me/password": {
      "patch": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。 当前实现修改密码后不会撤销既有用户会话。",
        "summary": "修改密码",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Changed"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "patch_api_client_users_me_password",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "confirmPassword": {
                    "description": "确认密码，必须与新密码一致",
                    "type": "string",
                    "example": "<NEW>"
                  },
                  "oldPassword": {
                    "description": "当前密码",
                    "type": "string",
                    "example": "<OLD>"
                  },
                  "newPassword": {
                    "description": "新密码，6–64位",
                    "type": "string",
                    "example": "<NEW>"
                  }
                },
                "type": "object",
                "required": [
                  "oldPassword",
                  "newPassword",
                  "confirmPassword"
                ]
              }
            }
          }
        }
      }
    },
    "/api/admin/users/{id}": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "可选字段 username、enabled；用户名2–20位文字/字母/数字/下划线/横线；忽略设备字段；撤销全部会话。",
        "summary": "编辑用户",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/AdminUser"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_users_id_",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "enabled": {
                    "description": "是否启用 / 授权",
                    "type": "boolean",
                    "example": true
                  },
                  "username": {
                    "description": "用户名 / 登录账号",
                    "type": "string",
                    "example": "示例用户"
                  }
                },
                "type": "object"
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "删除用户、其会话、预设和聊天；不可恢复，其他关联可能阻止删除。",
        "summary": "删除用户",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_users_id_"
      }
    },
    "/api/client/runtime-config": {
      "get": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "运行模式配置",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/RuntimeConfig"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "get_api_client_runtime_config"
      }
    },
    "/api/reviewer/presets/{id}/preview": {
      "get": {
        "security": [
          {
            "reviewer": []
          }
        ],
        "description": "未发布/私有也可预览；不计下载。",
        "summary": "审核员在线预览",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetPreview"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "审核员"
        ],
        "operationId": "get_api_reviewer_presets_id_preview"
      }
    },
    "/api/admin/stats/history": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "采样记录按服务实现返回。",
        "summary": "活跃历史",
        "parameters": [
          {
            "required": false,
            "name": "hours",
            "in": "query",
            "schema": {
              "format": "int64",
              "type": "integer",
              "default": 24
            },
            "description": "历史小时数，默认24"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/ActivitySnapshot"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_stats_history"
      }
    },
    "/api/admin/users/{id}/logout": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "强制用户下线",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_users_id_logout"
      }
    },
    "/api/admin/users/{id}/reset-password": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "返回一次性明文 password；撤销全部会话，勿记录到日志。",
        "summary": "重置用户密码",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Credentials"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_users_id_reset_password"
      }
    },
    "/api/admin/chat/users/{id}/ban": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "返回用户简要状态。",
        "summary": "封禁或解除聊天",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "banned",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否封禁公共聊天"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/AdminChatUser"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_chat_users_id_ban"
      }
    },
    "/api/admin/users": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "deviceCode 非空优先；keyword 匹配用户名/账号ID；当前新用户不绑定设备码，设备码查询主要兼容旧数据。",
        "summary": "用户列表与搜索",
        "parameters": [
          {
            "required": false,
            "name": "keyword",
            "in": "query",
            "schema": {
              "type": "string",
              "default": ""
            },
            "description": "用户名或账号ID子串；空字符串返回全部"
          },
          {
            "required": false,
            "name": "deviceCode",
            "in": "query",
            "schema": {
              "type": "string",
              "default": ""
            },
            "description": "设备唯一标识；请保持稳定"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/AdminUser"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_users"
      }
    },
    "/api/admin/licenses/{id}": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "仅更新非 null 字段；expiresAt 同步调整卡密 ACTIVE/EXPIRED 状态。",
        "summary": "修改卡密",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/LicenseKey"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_licenses_id_",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/LicenseUpdate"
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "不可恢复；关联外键可能使删除失败，应先处理绑定关系。",
        "summary": "删除卡密",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_licenses_id_"
      }
    },
    "/api/admin/presets": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "全部在线预设",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/PresetSummary"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_presets"
      }
    },
    "/api/client/users/me/avatar": {
      "post": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "file不能为空，≤200KB。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "更换头像",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserProfile"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "post_api_client_users_me_avatar",
        "requestBody": {
          "required": true,
          "content": {
            "multipart/form-data": {
              "schema": {
                "properties": {
                  "file": {
                    "format": "binary",
                    "type": "string",
                    "description": "上传文件；头像最大200KB，预设业务2MB且注意Spring默认1MB限制"
                  }
                },
                "type": "object",
                "required": [
                  "file"
                ]
              }
            }
          }
        }
      }
    },
    "/api/client/heartbeat": {
      "post": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "JSON body携带卡密token，不是Authorization用户令牌。",
        "summary": "卡密会话心跳",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "nullable": true,
                      "$ref": "#/components/schemas/HeartbeatResult"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "post_api_client_heartbeat",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Heartbeat"
              }
            }
          }
        }
      }
    },
    "/api/admin/titles/users/{id}": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "role=USER/AUTHOR/SYSTEM_ADMIN；此为用户社区角色，不是后台登录权限。title留空时作者/管理员使用默认头衔。 兼容注意：旧实现直接序列化UserAccount，可能包含passwordHash等敏感字段；只提取所需角色字段，禁止记录完整响应。",
        "summary": "授予用户角色头衔",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "role",
            "in": "query",
            "schema": {
              "enum": [
                "USER",
                "AUTHOR",
                "SYSTEM_ADMIN"
              ],
              "type": "string"
            },
            "description": "社区角色，不是管理员后台权限"
          },
          {
            "required": false,
            "name": "title",
            "in": "query",
            "schema": {
              "type": "string",
              "default": ""
            },
            "description": "公告标题或自定义头衔；参照各接口限制"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserAccount"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_titles_users_id_"
      }
    },
    "/api/admin/runtime-config": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "字段均可选；null不更新；afdianToken/ donateUrl 空白不更新；afdianUserId 空白可清空。",
        "summary": "更新云端配置",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/RuntimeConfig"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_runtime_config",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RuntimeConfigSave"
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "afdianToken 不回显。",
        "summary": "云端配置",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/RuntimeConfig"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_runtime_config"
      }
    },
    "/api/admin/devices": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "全部绑定设备",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/BoundDevice"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_devices"
      }
    },
    "/api/admin/logout": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "注销管理员会话",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_logout"
      }
    },
    "/api/reviewer/login": {
      "post": {
        "security": [],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "审核员登录",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Token"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "post_api_reviewer_login",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "username": {
                    "description": "用户名 / 登录账号",
                    "type": "string",
                    "example": "审核员账号"
                  },
                  "password": {
                    "description": "密码；仅发送到受信任服务器，不写日志",
                    "type": "string",
                    "example": "<PASSWORD>"
                  }
                },
                "type": "object",
                "required": [
                  "username",
                  "password"
                ]
              }
            }
          }
        }
      }
    },
    "/api/admin/reviewers/{id}": {
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "删除审核员及会话",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_reviewers_id_"
      }
    },
    "/api/client/presets/{id}/download": {
      "get": {
        "security": [],
        "description": "下载开关需开放；必须审核通过且公开；每次成功增加下载次数。",
        "summary": "下载公开预设",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_presets_id_download"
      }
    },
    "/api/client/sponsors": {
      "get": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "爱发电需服务端配置；第三方不可用/未配置时可能返回400。",
        "summary": "赞助名单",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/SponsorResult"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "get_api_client_sponsors"
      }
    },
    "/api/client/presets/mine/{id}/visibility": {
      "patch": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "只能本人上传；公开仍需通过审核。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "修改公开范围",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "publicVisible",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "上传者是否允许公开；还需published=true才进入公开列表"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetClient"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "patch_api_client_presets_mine_id_visibility"
      }
    },
    "/api/admin/chat/users/{id}/mute": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "minutes<=0 解除，最大43200分钟；返回用户简要状态，不是完整用户实体。",
        "summary": "禁言或解除",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "minutes",
            "in": "query",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "禁言分钟数，<=0解除，最多43200"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/AdminChatUser"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_chat_users_id_mute"
      }
    },
    "/api/client/users/titles": {
      "post": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "title为2–32个非空白字符，禁止申请作者/管理员身份名；reason可选。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "申请自定义头衔",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/MyTitle"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "post_api_client_users_titles",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "title": {
                    "description": "公告标题或自定义头衔；参照各接口限制",
                    "type": "string",
                    "example": "示例头衔"
                  },
                  "reason": {
                    "description": "头衔申请理由",
                    "type": "string",
                    "example": "申请理由"
                  }
                },
                "type": "object",
                "required": [
                  "title"
                ]
              }
            }
          }
        }
      },
      "get": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "我的头衔申请",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/MyTitle"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "get_api_client_users_titles"
      }
    },
    "/api/admin/reviewers/{id}/enabled": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "启停审核员",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "enabled",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否启用 / 授权"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_reviewers_id_enabled"
      }
    },
    "/api/client/presets/mine/{id}/download": {
      "get": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "下载开关需开放；只能本人；不增加公开下载次数。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "下载自己的预设",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "get_api_client_presets_mine_id_download"
      }
    },
    "/api/admin/presets/{id}": {
      "put": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "字段均可选；published 控制审核发布，客户端公开可见还须 publicVisible=true；不修改加密文件内部名称。",
        "summary": "编辑和审核预设",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetSummary"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "put_api_admin_presets_id_",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "description": {
                    "description": "简介",
                    "type": "string",
                    "example": "简介"
                  },
                  "name": {
                    "description": "名称",
                    "type": "string",
                    "example": "示例预设"
                  },
                  "published": {
                    "description": "是否发布 / 审核通过",
                    "type": "boolean",
                    "example": true
                  }
                },
                "type": "object"
              }
            }
          }
        }
      },
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "删除在线预设",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_presets_id_"
      }
    },
    "/api/reviewer/presets": {
      "get": {
        "security": [
          {
            "reviewer": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "待审核与历史预设",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/PresetSummary"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "审核员"
        ],
        "operationId": "get_api_reviewer_presets"
      }
    },
    "/api/admin/presets/{id}/preview": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "支持未发布/私有；MND1 AES-GCM 校验；损坏返回400；不返回原文件、不增加下载次数。",
        "summary": "解密预览预设",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetPreview"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_presets_id_preview"
      }
    },
    "/api/admin/licenses/generate": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "count 1–1000；自定义 customCode 仅允许 count=1；maxUses=0 不限；缺省设备开关为 true。",
        "summary": "生成卡密",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/LicenseKey"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "post_api_admin_licenses_generate",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateKeys"
              }
            }
          }
        }
      }
    },
    "/api/client/presets/mine": {
      "get": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "我的全部上传",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/PresetClient"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "get_api_client_presets_mine"
      }
    },
    "/api/admin/login": {
      "post": {
        "security": [],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "管理员登录",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Token"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "post_api_admin_login",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AdminLogin"
              }
            }
          }
        }
      }
    },
    "/api/admin/chat/messages/{id}": {
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "删除单条消息",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_chat_messages_id_"
      }
    },
    "/api/client/presets/{id}": {
      "get": {
        "security": [],
        "description": "仅数字ID；这不是解密预览接口。",
        "summary": "公开预设元信息",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetClient"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_presets_id_"
      }
    },
    "/api/client/users/me/name": {
      "patch": {
        "security": [
          {
            "user": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。 用户会话无效可能返回HTTP 400（业务异常），不应只处理401。",
        "summary": "修改名字",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/UserProfile"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "用户账号"
        ],
        "operationId": "patch_api_client_users_me_name",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "properties": {
                  "username": {
                    "description": "用户名 / 登录账号",
                    "type": "string",
                    "example": "新名字"
                  }
                },
                "type": "object",
                "required": [
                  "username"
                ]
              }
            }
          }
        }
      }
    },
    "/api/admin/licenses/{id}/status": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "status：UNUSED / ACTIVE / DISABLED / EXPIRED。",
        "summary": "启停卡密",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "status",
            "in": "query",
            "schema": {
              "enum": [
                "UNUSED",
                "ACTIVE",
                "DISABLED",
                "EXPIRED"
              ],
              "type": "string"
            },
            "description": "状态值，具体枚举见接口说明"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_licenses_id_status"
      }
    },
    "/api/admin/devices/{id}": {
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "不可恢复，关联会话可能受影响。",
        "summary": "解绑设备",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_devices_id_"
      }
    },
    "/api/client/validate-card": {
      "post": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "有副作用：成功增加使用次数、首次激活计算到期；依卡密配置要求云端设备启用。",
        "summary": "验证卡密",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/CardState"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "post_api_client_validate_card",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ValidateCard"
              }
            }
          }
        }
      }
    },
    "/api/admin/users/{id}/enabled": {
      "patch": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "撤销该用户全部会话。",
        "summary": "启停用户",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          },
          {
            "required": true,
            "name": "enabled",
            "in": "query",
            "schema": {
              "type": "boolean"
            },
            "description": "是否启用 / 授权"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/AdminUser"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "patch_api_admin_users_id_enabled"
      }
    },
    "/api/overview": {
      "get": {
        "security": [],
        "description": "历史兼容路由，当前没有管理员拦截；建议新接入使用/api/admin/stats。",
        "summary": "兼容旧概览",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Stats"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_overview"
      }
    },
    "/api/dashboard": {
      "get": {
        "security": [],
        "description": "历史兼容路由，当前没有管理员拦截；新接入使用/api/admin/stats/history。",
        "summary": "兼容旧历史",
        "parameters": [
          {
            "required": false,
            "name": "hours",
            "in": "query",
            "schema": {
              "format": "int64",
              "type": "integer",
              "default": 24
            },
            "description": "历史小时数，默认24"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/ActivitySnapshot"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_dashboard"
      }
    },
    "/api/client/monitor": {
      "post": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "visit=true增加访问次数；需每次生成新签名nonce。",
        "summary": "设备活动上报",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PingResult"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "post_api_client_monitor",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/Ping"
              }
            }
          }
        }
      }
    },
    "/api/client/preset-api-status": {
      "get": {
        "security": [
          {
            "nonce": [],
            "timestamp": [],
            "signature": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "上传下载开关",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/PresetApiState"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "客户端签名"
        ],
        "operationId": "get_api_client_preset_api_status"
      }
    },
    "/api/client/version": {
      "get": {
        "security": [],
        "description": "返回指定appId最高已发布版本或null；服务端未比较入参versionCode，客户端自行比较。",
        "summary": "最新发布版本",
        "parameters": [
          {
            "required": true,
            "name": "appId",
            "in": "query",
            "schema": {
              "type": "string",
              "example": "com.example.u7e5f3218e9"
            },
            "description": "应用包名 / 应用标识"
          },
          {
            "required": true,
            "name": "versionCode",
            "in": "query",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "正整数版本码"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "公开/兼容"
        ],
        "operationId": "get_api_client_version"
      }
    },
    "/api/admin/licenses/{id}/devices": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "卡密绑定设备",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/BoundDevice"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_licenses_id_devices"
      }
    },
    "/api/admin/prediction/enabled": {
      "post": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "管理员鉴权；不返回模型密钥或输入内容。恢复不重置预算，不解除异常锁定。",
        "summary": "暂停/恢复智能联想",
        "responses": {
          "200": {
            "description": "操作结果",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        },
        "tags": [
          "智能联想运维"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "required": [
                  "enabled"
                ],
                "type": "object",
                "properties": {
                  "enabled": {
                    "type": "boolean"
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/admin/reviewers": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "审核员列表",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/Reviewer"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_reviewers"
      }
    },
    "/api/admin/titles": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "头衔申请列表",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/TitleItem"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_titles"
      }
    },
    "/api/admin/monitored-devices/{id}": {
      "delete": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "删除设备访问记录",
        "parameters": [
          {
            "required": true,
            "name": "id",
            "in": "path",
            "schema": {
              "format": "int64",
              "type": "integer"
            },
            "description": "路径ID；除头像说明外均为数据库内部数字主键"
          }
        ],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "$ref": "#/components/schemas/Empty"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "delete_api_admin_monitored_devices_id_"
      }
    },
    "/api/admin/licenses": {
      "get": {
        "security": [
          {
            "admin": []
          }
        ],
        "description": "参数按下方定义传递；成功结果位于统一响应 data。",
        "summary": "全部卡密",
        "parameters": [],
        "responses": {
          "200": {
            "description": "成功；data定义如下",
            "content": {
              "application/json": {
                "schema": {
                  "required": [
                    "code",
                    "message",
                    "timestamp"
                  ],
                  "properties": {
                    "message": {
                      "description": "结果或错误说明",
                      "type": "string",
                      "example": "ok"
                    },
                    "timestamp": {
                      "format": "int64",
                      "description": "Unix毫秒时间戳",
                      "type": "integer",
                      "example": 1788609600000
                    },
                    "code": {
                      "description": "业务状态码，0为成功",
                      "type": "integer",
                      "example": 0
                    },
                    "data": {
                      "description": "业务结果；可能为null，结构见下方",
                      "items": {
                        "$ref": "#/components/schemas/LicenseKey"
                      },
                      "type": "array"
                    }
                  },
                  "type": "object",
                  "description": "data 可为 null；客户端必须先检查 code 和 HTTP 状态。"
                }
              }
            }
          },
          "500": {
            "description": "内部错误；部分旧接口缺少必填请求头可能返回500",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "404": {
            "description": "接口不存在或头像不存在",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "401": {
            "description": "签名/身份无效或权限拒绝",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          },
          "400": {
            "description": "参数/业务错误或预设损坏",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Error"
                }
              }
            }
          }
        },
        "tags": [
          "管理员"
        ],
        "operationId": "get_api_admin_licenses"
      }
    }
  },
  "tags": [
    {
      "name": "管理员"
    },
    {
      "name": "审核员"
    },
    {
      "name": "用户账号"
    },
    {
      "name": "客户端签名"
    },
    {
      "name": "公开/兼容"
    }
  ],
  "info": {
    "title": "喵喵助手 · 全量 API 对接文档",
    "version": "2026.09.05-webui",
    "description": "以当前线上合并后端源代码为准，覆盖全部HTTP路由；不会自动调用写接口。时间字段多为服务器本地ISO时间，无时区偏移。鉴权token分管理员、审核员、用户、卡密会话四类，不能混用。 上传需注意Spring默认单文件1MB限制。/ws/chat为STOMP实时通道，另见WebUI接入指南。"
  },
  "components": {
    "securitySchemes": {
      "user": {
        "description": "普通用户会话token，3天有效",
        "scheme": "bearer",
        "type": "http"
      },
      "reviewer": {
        "description": "审核员会话token，12小时有效",
        "scheme": "bearer",
        "type": "http"
      },
      "signature": {
        "name": "X-Signature",
        "in": "header",
        "type": "apiKey"
      },
      "timestamp": {
        "name": "X-Timestamp",
        "in": "header",
        "type": "apiKey"
      },
      "nonce": {
        "name": "X-Nonce",
        "in": "header",
        "type": "apiKey"
      },
      "admin": {
        "description": "管理员会话token，仅由/api/admin/login获得",
        "scheme": "bearer",
        "type": "http"
      }
    },
    "schemas": {
      "MonitoredDevice": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "type": "string"
          },
          "lastIp": {
            "description": "最后来源IP",
            "type": "string"
          },
          "activity": {
            "description": "访问活跃度：高 / 中 / 低",
            "type": "string"
          },
          "online": {
            "description": "当前在线状态；统计对象中同名字段为在线数量",
            "type": "boolean"
          },
          "lastSeenAt": {
            "description": "最后活跃时间，可能为null",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "deviceName": {
            "description": "设备显示名称",
            "type": "string"
          },
          "firstSeenAt": {
            "description": "首次访问时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "visitCount": {
            "format": "int64",
            "type": "integer",
            "description": "累计访问次数"
          }
        },
        "type": "object"
      },
      "MyTitle": {
        "properties": {
          "title": {
            "description": "公告标题或自定义头衔；参照各接口限制",
            "type": "string"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "reason": {
            "description": "头衔申请理由",
            "type": "string"
          },
          "status": {
            "enum": [
              "PENDING",
              "APPROVED",
              "REJECTED"
            ],
            "description": "状态值，具体枚举见接口说明",
            "type": "string"
          }
        },
        "type": "object"
      },
      "UserLogin": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "avatarUrl": {
            "description": "相对服务器根地址的头像URL，无头像为空",
            "type": "string"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "customTitle": {
            "description": "自定义头衔，可能为空",
            "type": "string"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "systemRole": {
            "description": "社区角色：USER / AUTHOR / SYSTEM_ADMIN，不代表后台登录权限",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "expiresAt": {
            "description": "会话或授权到期时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "CardState": {
        "properties": {
          "valid": {
            "description": "验证是否成功",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "PresetClient": {
        "properties": {
          "fileSize": {
            "format": "int64",
            "type": "integer",
            "description": "文件大小，单位字节"
          },
          "description": {
            "description": "简介",
            "type": "string"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "publicVisible": {
            "description": "上传者是否允许公开；还需published=true才进入公开列表",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "updatedAt": {
            "description": "更新时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean"
          },
          "name": {
            "description": "名称",
            "type": "string"
          },
          "downloadCount": {
            "format": "int64",
            "type": "integer",
            "description": "公开下载累计次数"
          },
          "uploader": {
            "$ref": "#/components/schemas/UserProfile"
          }
        },
        "type": "object"
      },
      "Announcement": {
        "properties": {
          "updatedAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean"
          },
          "pinned": {
            "description": "是否置顶",
            "type": "boolean"
          },
          "title": {
            "description": "公告标题或自定义头衔；参照各接口限制",
            "type": "string"
          },
          "content": {
            "description": "内容；聊天文本trim后1–500字符",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          }
        },
        "type": "object"
      },
      "Credentials": {
        "properties": {
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "password": {
            "description": "只在生成或重置操作返回的明文密码；关闭结果前安全保存，勿记录日志",
            "type": "string",
            "example": "<PASSWORD>"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          }
        },
        "type": "object"
      },
      "LicenseKey": {
        "properties": {
          "code": {
            "description": "卡密内容",
            "type": "string"
          },
          "status": {
            "enum": [
              "UNUSED",
              "ACTIVE",
              "DISABLED",
              "EXPIRED"
            ],
            "description": "状态值，具体枚举见接口说明",
            "type": "string"
          },
          "maxDevices": {
            "format": "int64",
            "type": "integer",
            "description": "启用绑定设备数量上限，1–20"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "usedCount": {
            "format": "int64",
            "type": "integer",
            "description": "已使用的卡密验证次数"
          },
          "activatedAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "durationDays": {
            "format": "int64",
            "type": "integer",
            "description": "首次激活后的有效天数，最小1"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "expiresAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "deviceBindingEnabled": {
            "description": "是否启用设备绑定规则",
            "type": "boolean"
          },
          "maxUses": {
            "format": "int64",
            "type": "integer",
            "description": "卡密验证次数上限，0表示不限"
          },
          "remark": {
            "description": "备注",
            "type": "string"
          },
          "deviceVerificationEnabled": {
            "description": "validate-card是否检查云端设备授权",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "Changed": {
        "properties": {
          "changed": {
            "description": "修改是否成功",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "RuntimeConfigSave": {
        "properties": {
          "rootOpen": {
            "description": "是否开放Root模式",
            "type": "boolean"
          },
          "accessibilityOpen": {
            "description": "是否开放无障碍模式",
            "type": "boolean"
          },
          "afdianUserId": {
            "description": "爱发电用户ID",
            "maxLength": 128,
            "type": "string"
          },
          "presetDownloadOpen": {
            "description": "是否开放预设下载",
            "type": "boolean"
          },
          "presetUploadOpen": {
            "description": "是否开放预设上传",
            "type": "boolean"
          },
          "licenseValidationEnabled": {
            "description": "是否启用卡密验证",
            "type": "boolean"
          },
          "afdianToken": {
            "description": "爱发电服务密钥，仅写入，读取不返回；空白保持旧值",
            "maxLength": 256,
            "type": "string",
            "example": "<AFDIANTOKEN>"
          },
          "shizukuOpen": {
            "description": "是否开放Shizuku模式",
            "type": "boolean"
          },
          "donateUrl": {
            "description": "赞助页面URL",
            "maxLength": 500,
            "type": "string",
            "example": "https://example.com/donate"
          },
          "floatingWindowOpen": {
            "description": "是否开放悬浮窗模式",
            "type": "boolean"
          },
          "keyboardOpen": {
            "description": "是否开放键盘模式",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "Empty": {
        "nullable": true,
        "type": "object",
        "example": null
      },
      "BoundDevice": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "type": "string"
          },
          "lastIp": {
            "description": "最后来源IP",
            "type": "string"
          },
          "licenseId": {
            "format": "int64",
            "type": "integer",
            "description": "关联卡密内部数字主键"
          },
          "boundAt": {
            "description": "绑定时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "lastSeenAt": {
            "description": "最后活跃时间，可能为null",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "licenseCode": {
            "description": "关联卡密内容",
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "type": "string"
          }
        },
        "type": "object"
      },
      "UserAccount": {
        "properties": {
          "chatBanned": {
            "description": "是否禁止公共聊天",
            "type": "boolean"
          },
          "lastIp": {
            "description": "最后来源IP",
            "type": "string"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "lastLoginAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "customTitle": {
            "description": "自定义头衔，可能为空",
            "type": "string"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "avatar": {
            "format": "byte",
            "type": "string",
            "description": "旧实体接口可能返回Base64头像；普通用户接口使用avatarUrl。"
          },
          "doNotDisturb": {
            "description": "实体中的免打扰标记；当前线上没有修改此值的HTTP路由",
            "type": "boolean"
          },
          "avatarContentType": {
            "description": "avatarContentType（以接口说明为准）",
            "type": "string"
          },
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "type": "string"
          },
          "chatMutedUntil": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "passwordHash": {
            "description": "旧授予角色接口可能返回此敏感字段；不要记录、展示或传播。其他用户接口返回脱敏DTO。",
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "type": "string"
          },
          "systemRole": {
            "description": "社区角色：USER / AUTHOR / SYSTEM_ADMIN，不代表后台登录权限",
            "type": "string"
          }
        },
        "type": "object"
      },
      "Device": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "type": "string"
          },
          "lastIp": {
            "description": "最后来源IP",
            "type": "string"
          },
          "lastSeenAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "license": {
            "$ref": "#/components/schemas/LicenseKey"
          },
          "boundAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "deviceName": {
            "description": "设备显示名称",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "Ping": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "minLength": 1,
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "type": "string"
          },
          "visit": {
            "description": "本次上报是否计入访问次数",
            "type": "boolean"
          }
        },
        "type": "object",
        "required": [
          "deviceCode"
        ]
      },
      "GenerateKeys": {
        "properties": {
          "durationDays": {
            "format": "int64",
            "minimum": 1,
            "type": "integer",
            "description": "首次激活后的有效天数，最小1"
          },
          "deviceVerificationEnabled": {
            "description": "validate-card是否检查云端设备授权",
            "type": "boolean"
          },
          "count": {
            "format": "int64",
            "maximum": 1000,
            "minimum": 1,
            "type": "integer",
            "description": "生成数量或结果数量"
          },
          "maxDevices": {
            "format": "int64",
            "maximum": 20,
            "minimum": 1,
            "type": "integer",
            "description": "启用绑定设备数量上限，1–20"
          },
          "deviceBindingEnabled": {
            "description": "是否启用设备绑定规则",
            "type": "boolean"
          },
          "prefix": {
            "description": "生成卡密前缀",
            "type": "string"
          },
          "maxUses": {
            "format": "int64",
            "minimum": 0,
            "type": "integer",
            "description": "卡密验证次数上限，0表示不限"
          },
          "remark": {
            "description": "备注",
            "type": "string"
          },
          "customCode": {
            "description": "自定义卡密，仅允许单码创建，最长64字",
            "maxLength": 64,
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "count",
          "durationDays",
          "maxDevices"
        ]
      },
      "ReviewerSession": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "reviewer": {
            "$ref": "#/components/schemas/ReviewerAccount"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "expiresAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "AdminChatUser": {
        "properties": {
          "chatBanned": {
            "description": "是否禁止公共聊天",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "chatMutedUntil": {
            "description": "禁言截止时间，null表示未禁言",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "ReviewerAccount": {
        "properties": {
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "lastLoginAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "passwordHash": {
            "description": "passwordHash（以接口说明为准）",
            "type": "string"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          }
        },
        "type": "object"
      },
      "LicenseSession": {
        "properties": {
          "bypass": {
            "description": "卡密验证关闭时为true，此时卡密会话token为空",
            "type": "boolean"
          },
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "deviceId": {
            "format": "int64",
            "type": "integer",
            "description": "绑定设备内部数字主键"
          },
          "expiresAt": {
            "description": "会话或授权到期时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "licenseExpiresAt": {
            "description": "卡密到期时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "SharedPreset": {
        "properties": {
          "fileSize": {
            "format": "int64",
            "type": "integer",
            "description": "文件大小，单位字节"
          },
          "description": {
            "description": "简介",
            "type": "string"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "uploader": {
            "$ref": "#/components/schemas/UserAccount"
          },
          "updatedAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "publicVisible": {
            "description": "上传者是否允许公开；还需published=true才进入公开列表",
            "type": "boolean"
          },
          "name": {
            "description": "名称",
            "type": "string"
          },
          "downloadCount": {
            "format": "int64",
            "type": "integer",
            "description": "公开下载累计次数"
          },
          "fileData": {
            "format": "byte",
            "type": "string",
            "description": "fileData（以接口说明为准）"
          }
        },
        "type": "object"
      },
      "AdminSession": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "expiresAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "Reviewer": {
        "properties": {
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "lastLoginAt": {
            "description": "最后登录时间，可能为null",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "ChatItem": {
        "properties": {
          "userId": {
            "format": "int64",
            "type": "integer",
            "description": "关联用户内部数字主键"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "pinned": {
            "description": "是否置顶",
            "type": "boolean"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "systemRole": {
            "description": "社区角色：USER / AUTHOR / SYSTEM_ADMIN，不代表后台登录权限",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "customTitle": {
            "description": "自定义头衔，可能为空",
            "type": "string"
          },
          "avatarUrl": {
            "description": "相对服务器根地址的头像URL，无头像为空",
            "type": "string"
          },
          "content": {
            "description": "内容；聊天文本trim后1–500字符",
            "type": "string"
          },
          "ipRegion": {
            "description": "IP地区文本",
            "type": "string"
          },
          "ipAddress": {
            "description": "管理用户接口为IP；客户端聊天为地区文本，不是原始IP",
            "type": "string"
          }
        },
        "type": "object"
      },
      "Error": {
        "properties": {
          "message": {
            "description": "message（以接口说明为准）",
            "type": "string"
          },
          "timestamp": {
            "format": "int64",
            "type": "integer",
            "description": "timestamp（以接口说明为准）"
          },
          "code": {
            "description": "卡密内容",
            "type": "integer"
          },
          "data": {
            "description": "data（以接口说明为准）",
            "nullable": true
          }
        },
        "type": "object"
      },
      "HeartbeatResult": {
        "properties": {
          "serverTime": {
            "description": "服务器本地ISO日期时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "valid": {
            "description": "验证是否成功",
            "type": "boolean"
          },
          "licenseExpiresAt": {
            "description": "卡密到期时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "UserProfile": {
        "properties": {
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "avatarUrl": {
            "description": "相对服务器根地址的头像URL，无头像为空",
            "type": "string"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "customTitle": {
            "description": "自定义头衔，可能为空",
            "type": "string"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "systemRole": {
            "description": "社区角色：USER / AUTHOR / SYSTEM_ADMIN，不代表后台登录权限",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          }
        },
        "type": "object"
      },
      "AdminChatItem": {
        "properties": {
          "chatBanned": {
            "description": "是否禁止公共聊天",
            "type": "boolean"
          },
          "userId": {
            "format": "int64",
            "type": "integer",
            "description": "关联用户内部数字主键"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "content": {
            "description": "内容；聊天文本trim后1–500字符",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "chatMutedUntil": {
            "description": "禁言截止时间，null表示未禁言",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          }
        },
        "type": "object"
      },
      "PresetApiState": {
        "properties": {
          "downloadOpen": {
            "description": "预设下载是否开放",
            "type": "boolean"
          },
          "uploadOpen": {
            "description": "预设上传是否开放",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "ClientSession": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "revoked": {
            "description": "revoked（以接口说明为准）",
            "type": "boolean"
          },
          "device": {
            "$ref": "#/components/schemas/Device"
          },
          "loginAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "expiresAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "lastHeartbeatAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "PresetPreview": {
        "properties": {
          "prefixText": {
            "description": "前缀文本",
            "type": "string"
          },
          "mode": {
            "description": "预设模式",
            "type": "string"
          },
          "prefixEnabled": {
            "description": "是否开启前缀",
            "type": "boolean"
          },
          "appendEnabled": {
            "description": "是否开启后缀",
            "type": "boolean"
          },
          "name": {
            "description": "名称",
            "type": "string"
          },
          "rules": {
            "description": "解密后的替换规则文本",
            "type": "string"
          },
          "emoticons": {
            "description": "解密后的颜文字文本",
            "type": "string"
          },
          "emoticonEnabled": {
            "description": "是否开启颜文字",
            "type": "boolean"
          },
          "appendText": {
            "description": "后缀文本",
            "type": "string"
          }
        },
        "type": "object"
      },
      "SponsorResult": {
        "properties": {
          "items": {
            "description": "结果列表",
            "items": {
              "properties": {
                "name": {
                  "type": "string"
                },
                "amount": {
                  "type": "string"
                },
                "plan": {
                  "type": "string"
                }
              },
              "type": "object"
            },
            "type": "array"
          },
          "count": {
            "format": "int64",
            "type": "integer",
            "description": "生成数量或结果数量"
          }
        },
        "type": "object"
      },
      "ActivitySnapshot": {
        "properties": {
          "activeUsers": {
            "format": "int64",
            "type": "integer",
            "description": "活跃设备数量采样"
          },
          "online": {
            "format": "int64",
            "type": "integer",
            "description": "当前在线状态；统计对象中同名字段为在线数量"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "capturedAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "visits": {
            "format": "int64",
            "type": "integer",
            "description": "累计访问量采样"
          }
        },
        "type": "object"
      },
      "AnnouncementSave": {
        "properties": {
          "pinned": {
            "description": "是否置顶",
            "type": "boolean",
            "default": false
          },
          "title": {
            "description": "公告标题或自定义头衔；参照各接口限制",
            "minLength": 1,
            "maxLength": 120,
            "type": "string"
          },
          "content": {
            "description": "内容；聊天文本trim后1–500字符",
            "minLength": 1,
            "type": "string"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean",
            "default": false
          }
        },
        "type": "object",
        "required": [
          "title",
          "content"
        ]
      },
      "LicenseUpdate": {
        "properties": {
          "durationDays": {
            "format": "int64",
            "minimum": 1,
            "type": "integer",
            "description": "首次激活后的有效天数，最小1"
          },
          "expiresAt": {
            "description": "本地 ISO 日期时间，如 2026-09-05T12:00:00；null 不修改",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "maxDevices": {
            "format": "int64",
            "maximum": 20,
            "minimum": 1,
            "type": "integer",
            "description": "启用绑定设备数量上限，1–20"
          },
          "deviceBindingEnabled": {
            "description": "是否启用设备绑定规则",
            "type": "boolean"
          },
          "maxUses": {
            "format": "int64",
            "minimum": 0,
            "type": "integer",
            "description": "卡密验证次数上限，0表示不限"
          },
          "remark": {
            "description": "备注",
            "type": "string"
          },
          "deviceVerificationEnabled": {
            "description": "validate-card是否检查云端设备授权",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "DeviceRebind": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "minLength": 1,
            "maxLength": 128,
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "maxLength": 100,
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "deviceCode"
        ]
      },
      "TitleItem": {
        "properties": {
          "userId": {
            "format": "int64",
            "type": "integer",
            "description": "关联用户内部数字主键"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "status": {
            "enum": [
              "PENDING",
              "APPROVED",
              "REJECTED"
            ],
            "description": "状态值，具体枚举见接口说明",
            "type": "string"
          },
          "reason": {
            "description": "头衔申请理由",
            "type": "string"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "title": {
            "description": "公告标题或自定义头衔；参照各接口限制",
            "type": "string"
          },
          "reviewedAt": {
            "description": "审核时间，未审核为null",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          }
        },
        "type": "object"
      },
      "VersionSave": {
        "properties": {
          "versionName": {
            "description": "展示版本名称",
            "minLength": 1,
            "type": "string"
          },
          "downloadUrl": {
            "description": "版本文件下载地址",
            "minLength": 1,
            "type": "string",
            "example": "https://example.com/app.apk"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean",
            "default": false
          },
          "forceUpdate": {
            "description": "强制更新标记；客户端当前策略还可能要求版本码完全一致",
            "type": "boolean",
            "default": false
          },
          "versionCode": {
            "format": "int64",
            "minimum": 1,
            "type": "integer",
            "description": "正整数版本码"
          },
          "appId": {
            "description": "应用包名 / 应用标识",
            "minLength": 1,
            "type": "string",
            "example": "com.example.u7e5f3218e9"
          },
          "changelog": {
            "description": "更新说明",
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "appId",
          "versionCode",
          "versionName",
          "downloadUrl"
        ]
      },
      "AdminLogin": {
        "properties": {
          "username": {
            "description": "用户名 / 登录账号",
            "minLength": 1,
            "type": "string"
          },
          "password": {
            "description": "密码；仅发送到受信任服务器，不写日志",
            "minLength": 1,
            "type": "string",
            "example": "<PASSWORD>"
          }
        },
        "type": "object",
        "required": [
          "username",
          "password"
        ]
      },
      "Stats": {
        "properties": {
          "totalKeys": {
            "format": "int64",
            "type": "integer",
            "description": "卡密总数"
          },
          "todayUsers": {
            "format": "int64",
            "type": "integer",
            "description": "今日活跃监控设备数，不是注册用户数"
          },
          "todayLogins": {
            "format": "int64",
            "type": "integer",
            "description": "今日卡密会话登录次数"
          },
          "online": {
            "format": "int64",
            "type": "integer",
            "description": "当前在线状态；统计对象中同名字段为在线数量"
          },
          "totalUsers": {
            "format": "int64",
            "type": "integer",
            "description": "监控设备总数，不是注册用户总数"
          },
          "todayDevices": {
            "format": "int64",
            "type": "integer",
            "description": "今日新增监控设备数"
          },
          "todayKeys": {
            "format": "int64",
            "type": "integer",
            "description": "今日生成卡密数"
          }
        },
        "type": "object"
      },
      "ChatMessage": {
        "properties": {
          "user": {
            "$ref": "#/components/schemas/UserAccount"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "content": {
            "description": "内容；聊天文本trim后1–500字符",
            "type": "string"
          },
          "pinned": {
            "description": "是否置顶",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "Token": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          }
        },
        "type": "object"
      },
      "PresetSummary": {
        "properties": {
          "fileSize": {
            "format": "int64",
            "type": "integer",
            "description": "文件大小，单位字节"
          },
          "description": {
            "description": "简介",
            "type": "string"
          },
          "uploaderId": {
            "description": "上传者九位字符串账号ID",
            "type": "string",
            "example": "123456789"
          },
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "published": {
            "description": "是否发布 / 审核通过",
            "type": "boolean"
          },
          "uploaderName": {
            "description": "上传用户名",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "name": {
            "description": "名称",
            "type": "string"
          },
          "downloadCount": {
            "format": "int64",
            "type": "integer",
            "description": "公开下载累计次数"
          }
        },
        "type": "object"
      },
      "Heartbeat": {
        "properties": {
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "minLength": 1,
            "type": "string",
            "example": "<TOKEN>"
          }
        },
        "type": "object",
        "required": [
          "token"
        ]
      },
      "DeviceState": {
        "properties": {
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "AdminUser": {
        "properties": {
          "createdAt": {
            "description": "创建时间",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "lastLoginAt": {
            "description": "最后登录时间，可能为null",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "avatarUrl": {
            "description": "相对服务器根地址的头像URL，无头像为空",
            "type": "string"
          },
          "accountId": {
            "description": "九位字符串账号ID；不能用作管理接口的数字主键",
            "type": "string",
            "example": "123456789"
          },
          "customTitle": {
            "description": "自定义头衔，可能为空",
            "type": "string"
          },
          "username": {
            "description": "用户名 / 登录账号",
            "type": "string"
          },
          "systemRole": {
            "description": "社区角色：USER / AUTHOR / SYSTEM_ADMIN，不代表后台登录权限",
            "type": "string"
          },
          "online": {
            "description": "当前在线状态；统计对象中同名字段为在线数量",
            "type": "boolean"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "enabled": {
            "description": "是否启用 / 授权",
            "type": "boolean"
          },
          "ipAddress": {
            "description": "管理用户接口为IP；客户端聊天为地区文本，不是原始IP",
            "type": "string"
          }
        },
        "type": "object"
      },
      "PingResult": {
        "properties": {
          "accepted": {
            "description": "设备是否已获得授权",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "RuntimeConfig": {
        "properties": {
          "rootOpen": {
            "description": "是否开放Root模式",
            "type": "boolean"
          },
          "accessibilityOpen": {
            "description": "是否开放无障碍模式",
            "type": "boolean"
          },
          "afdianUserId": {
            "description": "爱发电用户ID",
            "type": "string"
          },
          "presetDownloadOpen": {
            "description": "是否开放预设下载",
            "type": "boolean"
          },
          "presetUploadOpen": {
            "description": "是否开放预设上传",
            "type": "boolean"
          },
          "licenseValidationEnabled": {
            "description": "是否启用卡密验证",
            "type": "boolean"
          },
          "shizukuOpen": {
            "description": "是否开放Shizuku模式",
            "type": "boolean"
          },
          "donateUrl": {
            "description": "赞助页面URL",
            "type": "string"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "floatingWindowOpen": {
            "description": "是否开放悬浮窗模式",
            "type": "boolean"
          },
          "keyboardOpen": {
            "description": "是否开放键盘模式",
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "TitleApplication": {
        "properties": {
          "user": {
            "$ref": "#/components/schemas/UserAccount"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "status": {
            "description": "状态值，具体枚举见接口说明",
            "type": "string"
          },
          "title": {
            "description": "公告标题或自定义头衔；参照各接口限制",
            "type": "string"
          },
          "reviewedAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "reason": {
            "description": "头衔申请理由",
            "type": "string"
          }
        },
        "type": "object"
      },
      "DeviceStatus": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "minLength": 1,
            "maxLength": 128,
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "maxLength": 100,
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "deviceCode"
        ]
      },
      "UserSession": {
        "properties": {
          "user": {
            "$ref": "#/components/schemas/UserAccount"
          },
          "token": {
            "description": "对应身份的会话令牌；不同登录接口令牌不能混用",
            "type": "string",
            "example": "<TOKEN>"
          },
          "createdAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          },
          "id": {
            "format": "int64",
            "type": "integer",
            "description": "数据库内部数字主键，不是账号ID"
          },
          "expiresAt": {
            "description": "服务器本地日期时间，ISO-8601，不携带时区偏移",
            "nullable": true,
            "type": "string",
            "example": "2026-09-05T12:00:00"
          }
        },
        "type": "object"
      },
      "ClientLogin": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "minLength": 1,
            "maxLength": 128,
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "maxLength": 100,
            "type": "string"
          },
          "licenseKey": {
            "description": "客户端提交的卡密字符串",
            "minLength": 1,
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "licenseKey",
          "deviceCode"
        ]
      },
      "ValidateCard": {
        "properties": {
          "deviceCode": {
            "description": "设备唯一标识；请保持稳定",
            "minLength": 1,
            "maxLength": 128,
            "type": "string"
          },
          "deviceName": {
            "description": "设备显示名称",
            "maxLength": 100,
            "type": "string"
          },
          "licenseKey": {
            "description": "客户端提交的卡密字符串",
            "minLength": 1,
            "type": "string"
          }
        },
        "type": "object",
        "required": [
          "licenseKey",
          "deviceCode"
        ]
      }
    }
  },
  "x-route-count": 86
}
