refactor: simplify auth and subscription links

This commit is contained in:
2026-07-28 10:32:21 +08:00
parent b7a7cd9c71
commit fc8c23beee
41 changed files with 739 additions and 1468 deletions
+2 -2
View File
@@ -269,9 +269,9 @@ sub-store-cloudflare/
| GET | `/api/link/collection/:name` | 生成下载链接 |
| GET | `/api/source/flow/:name` | 流量信息(解析 subscription-userinfo 头) |
### 5.3 下载 API (`/download/*`)
### 5.3 下载 API
**路由**: `GET /download/collection/:name/:target?/:token?` 和 `GET /download/source/:name/:target?/:token?`
**路由**: `GET /collections/:name/:token` 和 `GET /sources/:name/:token`,目标格式通过 `?target=` 指定
**鉴权**:
1. 先校验全局 `SUB_STORE_PUBLIC_DOWNLOAD_TOKEN`(timingSafeEqual)