认证

登陆

接口描述:

接口地址:/api/base/token/login

请求方式POST

consumes:["application/json"]

produces:["*/*"]

请求示例

{
    "appId": "",
    "appKey": "",
    "appSecret": "",
    "loginType": ""
}

请求参数

参数名称 参数说明 in 是否必须 数据类型 schema
loginDto loginDto body true LoginDto LoginDto

schema属性说明

LoginDto

参数名称 参数说明 in 是否必须 数据类型 schema
appId body true string
appKey body true string
appSecret body true string
loginType 当前固定APP_KEY body true string

响应示例:

{
    "accessToken": "",
    "expiresTime": "",
    "loginUser": {
        "id": 0,
        "loginType": "",
        "loginUserType": "",
        "orgProduct": {
            "name": "",
            "orgId": 0,
            "productId": 0
        },
        "userOrg": {
            "account": "",
            "id": 0,
            "mobile": "",
            "name": "",
            "org": {
                "logo": "",
                "name": "",
                "type": ""
            },
            "orgId": 0,
            "portrait": ""
        },
        "userProduct": {
            "id": 0,
            "orgId": 0,
            "productId": 0,
            "systemAdmin": true
        }
    },
    "refreshToken": ""
}

响应参数:

参数名称 参数说明 类型 schema
accessToken string
expiresTime string(date-time) string(date-time)
loginUser LoginUser LoginUser
refreshToken string

schema属性说明

LoginUser

参数名称 参数说明 类型 schema
id integer(int64)
loginType 当前固定APP_KEY string
loginUserType 可用值:USER,CLIENT string
orgProduct OrgProduct OrgProduct
userOrg UserOrg UserOrg
userProduct UserProduct UserProduct

OrgProduct

参数名称 参数说明 类型 schema
name string
orgId integer(int64)
productId integer(int64)

UserOrg

参数名称 参数说明 类型 schema
account string
id integer(int64)
mobile string
name string
org Org Org
orgId integer(int64)
portrait string

Org

参数名称 参数说明 类型 schema
logo string
name string
type 可用值:CHANNEL,SERVICE,SAAS string

UserProduct

参数名称 参数说明 类型 schema
id integer(int64)
orgId integer(int64)
productId integer(int64)
systemAdmin boolean

响应状态:

状态码 说明 schema
200 OK Token
201 Created
401 Unauthorized
403 Forbidden
404 Not Found

刷新token

接口描述:

接口地址:/api/base/token/refresh

请求方式POST

consumes:["application/json"]

produces:["*/*"]

请求参数

参数名称 参数说明 in 是否必须 数据类型 schema
refreshToken refreshToken query true string

响应示例:

{
    "accessToken": "",
    "expiresTime": "",
    "loginUser": {
        "id": 0,
        "loginType": "",
        "loginUserType": "",
        "orgProduct": {
            "name": "",
            "orgId": 0,
            "productId": 0
        },
        "userOrg": {
            "account": "",
            "id": 0,
            "mobile": "",
            "name": "",
            "org": {
                "logo": "",
                "name": "",
                "type": ""
            },
            "orgId": 0,
            "portrait": ""
        },
        "userProduct": {
            "id": 0,
            "orgId": 0,
            "productId": 0,
            "systemAdmin": true
        }
    },
    "refreshToken": ""
}

响应参数:

参数名称 参数说明 类型 schema
accessToken string
expiresTime string(date-time) string(date-time)
loginUser LoginUser LoginUser
refreshToken string

schema属性说明

LoginUser

参数名称 参数说明 类型 schema
id integer(int64)
loginType 当前固定APP_KEY string
loginUserType 可用值:USER,CLIENT string
orgProduct OrgProduct OrgProduct
userOrg UserOrg UserOrg
userProduct UserProduct UserProduct

OrgProduct

参数名称 参数说明 类型 schema
name string
orgId integer(int64)
productId integer(int64)

UserOrg

参数名称 参数说明 类型 schema
account string
id integer(int64)
mobile string
name string
org Org Org
orgId integer(int64)
portrait string

Org

参数名称 参数说明 类型 schema
logo string
name string
type 可用值:CHANNEL,SERVICE,SAAS string

UserProduct

参数名称 参数说明 类型 schema
id integer(int64)
orgId integer(int64)
productId integer(int64)
systemAdmin boolean

响应状态:

状态码 说明 schema
200 OK Token
201 Created
401 Unauthorized
403 Forbidden
404 Not Found

results matching ""

    No results matching ""