From 7adcc1b39ad00a3dd6faf21d00b8a547db426b9f Mon Sep 17 00:00:00 2001 From: RTAkland Date: Wed, 21 Dec 2022 21:18:00 +0800 Subject: [PATCH] =?UTF-8?q?migrate:=20=E5=B0=86=E9=83=A8=E5=88=86=E8=87=AA?= =?UTF-8?q?=E8=BF=B0=E6=96=87=E6=A1=A3=E5=86=85=E7=9A=84=E5=86=85=E5=AE=B9?= =?UTF-8?q?=E8=BF=81=E7=A7=BB=E5=88=B0api=E6=96=87=E6=A1=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 29 ----------------------------- docs/README.md | 33 +++++++++++++++++++++++++++++++-- 2 files changed, 31 insertions(+), 31 deletions(-) diff --git a/README.md b/README.md index 70f2521..ed5efd2 100644 --- a/README.md +++ b/README.md @@ -13,35 +13,6 @@ * 暂未支持`MongoDB` -# 安装&运行 - -```bash -$ pip3 install -r requirements.txt -$ uvicorn src:create_app --factory or -$ sh run.sh or -$ python3 main.py # 两条命令等价 -``` - -# 使用 - -* 访问`http://127.0.0.1:8000/` - -> 示例: http://127.0.0.1:8000/_redirect?length=10&theme=moebooru - -## 参数 - -* `length` - -> length: 1 ≤ x ≤ 10 - -* `theme` - -> theme: `blacked` `lewd` `lisu` `moebooru` `asoul` - -# 单元测试 - -* 没有单元测试(没写) - # 开源 - 本项目以[Apache-2.0](./LICENSE)许可开源, 即: diff --git a/docs/README.md b/docs/README.md index 7f01f5c..c85febd 100644 --- a/docs/README.md +++ b/docs/README.md @@ -6,11 +6,40 @@ * 使用sqlite, 直接填写为`sqlite3` 即默认 * 使用mysql, 需要按照以下格式填写: user:pwd@host:port/db -> 所有接口前缀都为`/api/` -> 返回类型除了 `export` 都是RESTFul风格的api +# 安装 & 运行 + +```bash +$ pip3 install -r requirements.txt +$ uvicorn src:create_app --factory or +$ sh run.sh or +$ python3 main.py # 两条命令等价 +``` + +# 使用 + +* 访问`http://127.0.0.1:8000/` + +> 示例: http://127.0.0.1:8000/_redirect?length=10&theme=moebooru + +## 参数 + +* `length` + +> length: 1 ≤ x ≤ 10 + +* `theme` + +> theme: `blacked` `lewd` `lisu` `moebooru` `asoul` + +# 单元测试 + +* 没有单元测试(没写) # 接口 +> 所有接口前缀都为`/api/` +> 返回类型除了 `export` 都是RESTFul风格的api + * 部分数据可能不同 ## query