feat: add unified authorization middleware

This commit is contained in:
2026-08-12 11:46:48 +08:00
parent 2d1deb54f0
commit fa6898aef8
31 changed files with 341 additions and 490 deletions

View File

@@ -9,7 +9,7 @@
- 动态 HTTP`POST /rpc/ads/{Service}/{Method}`
- 原生 gRPC`/ads.{Service}/{Method}`
- grpc-gateway`POST /ads.{Service}/{Method}`
- 鉴权:需要登录的接口通过 `Authorization: Bearer <token>` 传递凭证
- 鉴权:需要登录的接口通过 `Authorization: <JWT>` 传递裸 JWT不添加 `Bearer` 前缀
- 动态 HTTP 成功或失败均返回 HTTP 200业务状态见 `code``message``details`
## 服务概览
@@ -28,7 +28,6 @@
- 动态 HTTP`POST /rpc/ads/Fetch/ByPos`
- gRPC`/ads.Fetch/ByPos`
- 白名单键:`ads.Fetch.ByPos`
- 请求示例:
```json