From a4cc42ce023d4d74e4ab165b25df0e2c593c6912 Mon Sep 17 00:00:00 2001 From: Junyan Qin Date: Tue, 19 Nov 2024 16:46:08 +0800 Subject: [PATCH] =?UTF-8?q?doc:=20=E8=A1=A5=E5=85=A8=20system.json=20?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E8=AF=B4=E6=98=8E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/config/function/system.md | 36 +++++++++++++++++++++++++++++++++- 1 file changed, 35 insertions(+), 1 deletion(-) diff --git a/docs/config/function/system.md b/docs/config/function/system.md index 5d4966df1..0183a042c 100644 --- a/docs/config/function/system.md +++ b/docs/config/function/system.md @@ -96,4 +96,38 @@ LangBot 运行期间推送遥测数据的目标地址,默认为官方地址, "help-message": "LangBot - 😎高稳定性、🧩支持插件、🦄多模态的 ChatGPT QQ 机器人🤖\n链接:https://langbot.app" ``` -`help-message`:帮助消息,用户发送 !help 命令时的输出 \ No newline at end of file +`help-message`:帮助消息,用户发送 !help 命令时的输出 + +## HTTP 接口 http-api + +配置 HTTP 服务,需要启用才能访问 WebUI。 + +```json +"http-api": { + "enable": true, + "host": "0.0.0.0", + "port": 5300, + "jwt-expire": 604800 +}, +``` + +`enable`:是否启用 HTTP 接口 +`host`:HTTP 接口监听的地址 +`port`:HTTP 接口监听的端口 +`jwt-expire`:JWT 过期时间,单位为秒 + +## 持久化配置 persistence + +配置数据库信息。 + +```json +"persistence": { + "sqlite": { + "path": "data/persistence.db" + }, + "use": "sqlite" +} +``` + +`sqlite`:使用 SQLite 数据库,`path` 为数据库文件路径 +`use`:使用哪种数据库,目前仅支持 `sqlite`