其他接口

查询所有对接的应用

查询用户的入口授权

新增应用信息、应用权限信息对外接口

编辑应用信息、应用权限信息对外接口

删除应用信息、应用权限信息对外接口

标签新增用户对外接口

一、查询所有对接的应用

门户应用获取已对接的应用列表, 展示应用相关信息

请求⽅式: GET(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/api/aggregate/app/public/find/clientId/name/all

注:https方式类似。

请求参数:

请求示例:
https://ljw.sso.rghall.com.cn/linkid/api/aggregate/app/public/find/clientId/name/all

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": [
        {
            "clientId": "OC4wNS4wNS4wNy4wMC4wMy4wMS4wMS4w",
            "name": "智慧身份源系统",
            "url": "http://id.ruijie.com.cn",
            "describe": "智慧身份源系统",
            "isDeleted": false
        },
        {
            "clientId": "11111111111111",
            "name": "11111111111111111",
            "url": "http://www.1111111.com",
            "describe": "11111111111111111111111",
            "isDeleted": false
        }
    ]
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data 自定义对象 自定义对象
clientId string 应用的clientId
name string 应用名称
url string 应用url
describe string 应用描述
isDeleted boolean 是否已删除, true:已删除, false: 未删除

二、查询用户有入口授权的应用

查询用户的有入口授权的应用

请求⽅式: GET(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/remote/permission/entrance/public/find/entancePermissions/{userId}

注:https方式类似。

请求参数:

请求示例:
https://ljw.sso.rghall.com.cn/linkid/remote/permission/entrance/public/find/entancePermissions/admin

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": [
        {
            "clientId": "OC4wNS4wNS4wNy4wMC4wMy4wMS4wMS4w",
            "name": "智慧身份源系统",
            "url": "http://id.ruijie.com.cn",
            "describe": "智慧身份源系统",
            "isDeleted": null
        },
        {
            "clientId": "11111111111111",
            "name": "11111111111111111",
            "url": "http://www.1111111.com",
            "describe": "11111111111111111111111",
            "isDeleted": null
        }
    ]
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data 自定义对象 自定义对象
clientId string 应用的clientId
name string 应用名称
url string 应用url
describe string 应用描述
isDeleted null 无用字段

三、新增应用信息、应用权限信息对外接口

新增应用信息,以及生成与应用信息同名的标签,并根据是否授权建立关系

请求⽅式: POST(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/remote/permission/entrance/public/saveApp

注:https方式类似。

设置请求头 Authorization: Bearer {access_token} img

请求参数包:

{
    "appId":"123456002",
    "isPermission": true,
    "isEnable": true,
    "accessTerminal": "[\"PC\"]",
    "address":"http://james23.com",
    "appCategory":"生活服务类",
    "appName":"詹姆士23号网",
    "appType":"APP应用",
    "departmentId":"RJXZZZ",
    "departmentName":"行政组织",
    "description":"詹姆斯季中赛mvp",
    "securityLevel":"普通",
    "protocol":"CAS",
    "callbackAddr":"james23.com",
    "callbackAddrType":"^(https|http)://",
    "logoutAddr":"james.com",
    "logoutAddrType":"http://",
    "logoutType":"BACK_CHANNEL",
    "timeEffectParam": {},
    "timeEffectType": "-1"
}

请求参数说明:

参数 类型 必须 说明
appId String 应用ID
appLogo String 应用头像
isPermission Boolean 是否生成授权
isEnable Boolean 是否开启单点
accessTerminal String 终端
address String 应用地址
appCategory String 应用类别
appName String 应用名称
appType String 应用类型
departmentId String 所属部门ID
departmentName String 所属部门名称
description String 应用描述
securityLevel String 安全级别(1: 普通对应"1",2:中级对应"2",3:高级对应"3")
protocol String 协议(CAS/OAUTH/SAML)
callbackAddr String 回调地址
callbackAddrType String 回调地址类型(http://、https://、(https或http:// 注:此处因为分隔符传参应调整为下方示例))
logoutAddr String 登出地址
logoutAddrType String 登出地址类型(http://、https://)
timeEffectParam String 时效配置参数(1. 当为-1时,为{}, 2.当为0自定义时,为{startTime: "", endTime: ""},3. 选择生效时间,为{startTime:""}, 4.选择截至时间同2)
timeEffectType String 对接时效类型(-1:永久 0:自定义 1:选择生效时间 2: 选择截止时间)
isGenerateRefreshToken String 当protocol为oauth时,为必填(true/false)是否下发刷新令牌
tokenType String 当protocol为oauth时,为必填 令牌格式(OCTOTHORPE:以#分隔属性信息 ,JSON:JSON格式)
spEntityId String 当protocol为SAML时,为必填 对端应用提供得标示,这个要根据真实的数据,不能填入已存在的spEntityId

注: 回调地址传参 https或http:// 对应 ^(https|http)://

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": "123052" //标签code,新增标签为默认分类,标签名称与应用名称一致,标签code与应用id一致
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data String 成功则返回标签code

四、编辑应用信息、应用权限信息对外接口

更新应用信息以及标签信息

请求⽅式: POST(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/remote/permission/entrance/public/updateApp

注:https方式类似。

设置请求头 Authorization: Bearer {access_token} img

请求参数包:

{
  "appId": "123456001",
  "appLogo": "",
  "appName": "科比网",
  "description": "科比得分王",
  "address": "http://kobe24.com",
  "appType": "APP应用",
  "appCategory": "生活服务类",
  "accessTerminal": "[\"PC\"]",
  "charge": null,
  "contact": null,
  "departmentId": "RJXZZZ",
  "departmentName": "行政组织",
  "securityLevel": "普通",
  "chargeUserId": null,
  "id": "65af6f35e69f5875f416cbbe",
  "protocol":"CAS",
  "callbackAddr":"james23.com",
  "callbackAddrType":"^(https|http)://",
  "logoutAddr":"james.com",
  "logoutAddrType":"http://",
  "logoutType":"BACK_CHANNEL",
  "timeEffectParam": {},
  "timeEffectType": "-1"
}

请求参数说明:

参数 类型 必须 说明
appId String 应用ID
appLogo String 应用头像
isEnable Boolean 是否开启单点
accessTerminal String 终端
address String 应用地址
appCategory String 应用类别
appName String 应用名称
appType String 应用类型
departmentId String 所属部门ID
departmentName String 所属部门名称
description String 应用描述
securityLevel String 安全级别(1: 普通对应"1",2:中级对应"2",3:高级对应"3")
protocol String 协议(CAS/OAUTH/SAML)
callbackAddr String 回调地址
callbackAddrType String 回调地址类型(http://、https://、https或http://)
logoutAddr String 登出地址
logoutAddrType String 登出地址类型(http://、https://)
timeEffectParam String 时效配置参数(1. 当为-1时,为{}, 2.当为0自定义时,为{startTime: "", endTime: ""},3. 选择生效时间,为{startTime:""}, 4.选择截至时间同2)
timeEffectType String 对接时效类型(-1:永久 0:自定义 1:选择生效时间 2: 选择截止时间)
isGenerateRefreshToken String 当protocol为oauth时,为必填(true/false)是否下发刷新令牌
tokenType String 当protocol为oauth时,为必填 令牌格式(OCTOTHORPE:以#分隔属性信息 ,JSON:JSON格式)
spEntityId String 当protocol为SAML时,为必填 对端应用提供得标示,这个要根据真实的数据,不能填入已存在的spEntityId

注: 回调地址传参 https或http:// 对应 ^(https|http)://

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": null
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data String 成功则返回null

五、删除应用信息、应用权限信息对外接口

更新应用信息以及标签信息

请求⽅式: DELETE(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/remote/permission/entrance/public/deleteApp/{id}

注:https方式类似。

设置请求头 Authorization: Bearer {access_token} img

请求参数说明:

参数 类型 必须 说明
id String 应用appID

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": null
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data String 成功则返回null

六、标签新增用户对外接口

往标签内新增用户信息

请求⽅式: POST(HTTPS或HTTP

请求地址: http://self.xxx.edu.cn/linkid/remote/permission/entrance/public/saveUsers

注:https方式类似。

设置请求头 Authorization: Bearer {access_token} img

请求参数包:

{
    "userIdList":["0120231004","022023281120","052023281106"],
    "labelId":"65af9f43e69f5862e0d3d5d1",
    "operateType":"add"
}

请求参数说明:

参数 类型 必须 说明
userIdList String 用户学工号列表
labelId String 标签ID
operateType String 操作类型(add:新增, remove:移除)

返回结果:

{
    "code": 200,
    "message": "OK",
    "data": null
}

参数说明:

参数 类型 说明
code int 返回状态code
message String 返回状态消息
data String 成功则返回null

接口调用失败请查看开发指南-Token与Api调用失败须知

©2020 锐捷网络股份有限公司 all right reserved,powered by Gitbook该文章修订时间: 2025-02-18 14:26:09

results matching ""

    No results matching ""