add first commit

This commit is contained in:
2026-07-22 17:15:16 +08:00
commit 8a20a14123
13 changed files with 188 additions and 0 deletions
+10
View File
@@ -0,0 +1,10 @@
[worker]
name = "auth"
version = "0.1.0"
description = "鉴权管理"
config_version = "1.0"
defaults = { method = "GET", ttl = 30, timeout = 2.0, auth_required = true, cacheable = false }
[worker.registration]
router_prefix = "/auth"
tags = ["auth"]
+13
View File
@@ -0,0 +1,13 @@
[POST]
cacheable = false
auth_required = false
summary = "登录"
docstring = "根据用户名和密码进行登录,登录成功返回token,获取请求需带式token进行请求"
params = ["username: str", "password: str"]
[POST.response_model]
result = {type = "str", required = true}
token = {type = "str", required = true}
message = {type = "str", required = true}
timestamp = {type = "float", required = false}