This commit is contained in:
2025-05-06 22:16:31 +08:00
commit 54f5caeeaa
33 changed files with 7191 additions and 0 deletions

View File

@@ -0,0 +1,30 @@
import api from "../interceptor"
/**
* 鉴权签名接口
* @param ctx
*/
export default async function GetAuth(ctx) {
const params = ctx.request.body
// 为了方便存在全局
global.appKey = params.appKey
global.appSecret = params.appSecret
// [只为验证鉴权,可删除]
await api
.post("/v2/app/start", {})
.then(({ data }) => {
// 非文档描述性codesign success
if (data.code === -400) {
ctx.body = {
msg: "auth success",
type: "success",
state: 200
}
} else {
ctx.body = data
}
})
.catch(err => {
ctx.body = err
})
}