GET
/
api
/
auth
/
session
读取当前浏览器或 Bearer 登录态
curl --request GET \
  --url https://wfapi.yuhe.space/api/auth/session
{
  "errCode": 123,
  "errMessage": "<string>",
  "data": {
    "authenticated": true,
    "principal": {
      "userId": "<string>",
      "displayName": "<string>",
      "email": "jsmith@example.com",
      "permissions": [],
      "apiKeyId": "<string>",
      "roleNames": [
        "<string>"
      ]
    }
  }
}

Response

200 - application/json

未登录时返回 authenticated: false;已登录时带上 principal 摘要。

errCode
integer
required
errMessage
string
required
Allowed value: ""
data
object
required