{"openapi":"3.1.0","info":{"title":"QQ Bot Panel","version":"0.1.0"},"paths":{"/":{"get":{"summary":"Index","operationId":"index__get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/login":{"get":{"summary":"Login Page","operationId":"login_page_login_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/login":{"post":{"summary":"Api Login","operationId":"api_login_api_login_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/logout":{"post":{"summary":"Api Logout","operationId":"api_logout_api_logout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/bootstrap":{"get":{"summary":"Api Bootstrap","description":"登录页判断是不是首次使用，不涉及敏感信息所以不鉴权。","operationId":"api_bootstrap_api_bootstrap_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/password":{"post":{"summary":"Api Password","operationId":"api_password_api_password_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/status":{"get":{"summary":"Api Status","operationId":"api_status_api_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/memory":{"get":{"summary":"Api Memory","operationId":"api_memory_api_memory_get","parameters":[{"name":"q","in":"query","required":false,"schema":{"type":"string","default":"","title":"Q"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/memory/facts/{fid}":{"delete":{"summary":"Api Delete Fact","operationId":"api_delete_fact_api_memory_facts__fid__delete","parameters":[{"name":"fid","in":"path","required":true,"schema":{"type":"integer","title":"Fid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/memory/budget":{"post":{"summary":"Api Set Budget","description":"给某个群/某个人单独设上下文预算。budget=0 表示继承全局。","operationId":"api_set_budget_api_memory_budget_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/memory/purge":{"post":{"summary":"Api Memory Purge","description":"调试用：清空上下文 / 事实 / 全部。","operationId":"api_memory_purge_api_memory_purge_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/memory/clear":{"post":{"summary":"Api Clear Memory","description":"清空某个会话的上下文（不删事实库）。","operationId":"api_clear_memory_api_memory_clear_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/logs":{"get":{"summary":"Api Logs","operationId":"api_logs_api_logs_get","parameters":[{"name":"after","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"After"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/config":{"get":{"summary":"Api Get Config","operationId":"api_get_config_api_config_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}},"post":{"summary":"Api Save Config","operationId":"api_save_config_api_config_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/test-key":{"post":{"summary":"Api Test Key","description":"用当前配置发一次最小请求，验证 Key 是否可用。","operationId":"api_test_key_api_test_key_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/bot/{action}":{"post":{"summary":"Api Bot Action","operationId":"api_bot_action_api_bot__action__post","parameters":[{"name":"action","in":"path","required":true,"schema":{"type":"string","title":"Action"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/napcat/{action}":{"post":{"summary":"Api Napcat Action","operationId":"api_napcat_action_api_napcat__action__post","parameters":[{"name":"action","in":"path","required":true,"schema":{"type":"string","title":"Action"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/napcat/webui":{"get":{"summary":"Api Napcat Webui","description":"返回 NapCat 登录页的对外地址。\n\nNapCat WebUI 内部用 /webui/、/api/ 这类绝对路径，挂在子路径下会和面板抢 /api，\n所以给它单独一个子域名，nginx 直接反代到 6099。","operationId":"api_napcat_webui_api_napcat_webui_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/groups":{"get":{"summary":"Api Groups","operationId":"api_groups_api_groups_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/stickers":{"get":{"summary":"Api List Stickers","operationId":"api_list_stickers_api_stickers_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/stickers/upload":{"post":{"summary":"Api Upload Sticker","operationId":"api_upload_sticker_api_stickers_upload_post","requestBody":{"content":{"multipart/form-data":{"schema":{"$ref":"#/components/schemas/Body_api_upload_sticker_api_stickers_upload_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/stickers/progress":{"get":{"summary":"Api Stickers Progress","operationId":"api_stickers_progress_api_stickers_progress_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/stickers/{sid}":{"patch":{"summary":"Api Update Sticker","operationId":"api_update_sticker_api_stickers__sid__patch","parameters":[{"name":"sid","in":"path","required":true,"schema":{"type":"integer","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"summary":"Api Delete Sticker","operationId":"api_delete_sticker_api_stickers__sid__delete","parameters":[{"name":"sid","in":"path","required":true,"schema":{"type":"integer","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/stickers/{sid}/annotate":{"post":{"summary":"Api Annotate Sticker","operationId":"api_annotate_sticker_api_stickers__sid__annotate_post","parameters":[{"name":"sid","in":"path","required":true,"schema":{"type":"integer","title":"Sid"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/stickers/annotate-batch":{"post":{"summary":"Api Annotate Batch","description":"把所有没标注的排进后台任务，立即返回，前端轮询进度。","operationId":"api_annotate_batch_api_stickers_annotate_batch_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/test-vision":{"post":{"summary":"Api Test Vision","description":"用一张程序生成的纯色图验证视觉通道（不依赖任何外链）。","operationId":"api_test_vision_api_test_vision_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/persona-presets":{"get":{"summary":"Api Persona Presets","operationId":"api_persona_presets_api_persona_presets_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/persona/preview":{"post":{"summary":"Api Persona Preview","description":"把角色卡编译成最终 system prompt，方便肉眼检查。","operationId":"api_persona_preview_api_persona_preview_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/test-chat":{"post":{"summary":"Api Test Chat","operationId":"api_test_chat_api_test_chat_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}}},"components":{"schemas":{"Body_api_upload_sticker_api_stickers_upload_post":{"properties":{"files":{"items":{"type":"string","contentMediaType":"application/octet-stream"},"type":"array","title":"Files"}},"type":"object","required":["files"],"title":"Body_api_upload_sticker_api_stickers_upload_post"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}