default:
$ref: '#/components/responses/DefaultErrorResponse'
- '/application/{applicationId}/roles/accounts':
- post:
- summary: 获取应用下的多个角色的用户帐号
- description: 获取应用下的多个角色的用户帐号
- operationId: loadAccountsByApplicationRole
+ '/application/{applicationId}/role/{rolecode}/groups':
+ get:
+ summary: 获取应用下的一个角色关联的用户组
+ description: 获取应用下的一个角色关联的用户组
+ operationId: loadApplicationRoleGroups
tags:
- Role
security:
description: 应用标识
schema:
type: string
+ - name: rolecode
+ in: path
+ required: true
+ description: 角色代码
+ schema:
+ type: string
+ - name: groupType
+ in: path
+ required: false
+ description: 用户组类型(1 普通,2 岗位)
+ schema:
+ type: string
+ responses:
+ '200':
+ description: 角色关联的用户组列表
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ApplicationRoleGroupsResponse'
+ default:
+ $ref: '#/components/responses/DefaultErrorResponse'
+
+
+ '/application/{applicationId}/externalRole/{externalId}/accounts':
+ get:
+ summary: 获取应用下的一个角色的用户帐号
+ description: 获取应用下的一个角色的用户帐号
+ operationId: loadAccountsByApplicationExternalRole
+ tags:
+ - Role
+ security:
+ - oauth2:
+ - "authz:v1:readRole"
+ parameters:
+ - name: applicationId
+ in: path
+ required: true
+ description: 应用标识
+ schema:
+ type: string
+ - name: externalId
+ in: path
+ required: true
+ description: 应用内角色ID
+ schema:
+ type: string
- name: loadAll
in: query
required: false
type: integer
format: int32
default: 1000
- requestBody:
- description: 角色ID
- required: true
- content:
- application/json:
- schema:
- type: array
- items:
- title: 角色ID
- type: string
responses:
'200':
- description: 用户的帐号ID
+ description: 角色关联的帐号ID
content:
application/json:
schema:
- $ref: '#/components/schemas/ApplicationRolesAccountsResponse'
+ $ref: '#/components/schemas/ApplicationExternalRoleAccountsResponse'
default:
$ref: '#/components/responses/DefaultErrorResponse'
-
- '/application/{applicationId}/role/{rolecode}/groups':
- get:
- summary: 获取应用下的一个角色关联的用户组
- description: 获取应用下的一个角色关联的用户组
- operationId: loadApplicationRoleGroups
+ '/application/{applicationId}/externalRoles/accounts':
+ post:
+ summary: 获取应用下的多个角色的用户帐号
+ description: 获取应用下的多个角色的用户帐号
+ operationId: loadAccountsByApplicationExternalRoles
tags:
- Role
security:
description: 应用标识
schema:
type: string
- - name: rolecode
- in: path
- required: true
- description: 角色代码
+ - name: loadAll
+ in: query
+ required: false
+ description: 分页-是否返回所有(当为 true 时,不分页,参数 pageIndex、pageSize 无效)
schema:
- type: string
- - name: groupType
- in: path
+ type: boolean
+ default: false
+ - name: pageIndex
+ in: query
required: false
- description: 用户组类型(1 普通,2 岗位)
+ description: 分页-页码
schema:
- type: string
+ type: integer
+ format: int32
+ default: 0
+ - name: pageSize
+ in: query
+ required: false
+ description: 分页-每页记录数
+ schema:
+ type: integer
+ format: int32
+ default: 1000
+ requestBody:
+ description: 应用内角色ID列表
+ required: true
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ title: 应用内角色ID
+ type: string
responses:
'200':
- description: 角色关联的用户组列表
+ description: 角色关联的帐号ID
content:
application/json:
schema:
- $ref: '#/components/schemas/ApplicationRoleGroupsResponse'
+ $ref: '#/components/schemas/ApplicationExternalRolesAccountsResponse'
default:
$ref: '#/components/responses/DefaultErrorResponse'
$ref: '#/components/schemas/Role'
- ApplicationRolesAccountsResponse:
+ ApplicationRoleGroupsResponse:
allOf:
- $ref: '#/components/schemas/DefaultApiResponse'
- type: object
applicationId:
title: 应用标识
type: string
- roleIds:
- title: 角色IDs
+ rolecode:
+ title: 角色代码
+ type: string
+ groupIds:
+ title: 用户组ID列表
type: array
items:
- title: 角色ID
+ title: 用户组ID
type: string
+ groups:
+ title: 用户组列表
+ type: array
+ items:
+ $ref: '#/components/schemas/GroupModel'
+
+
+ ApplicationExternalRoleAccountsResponse:
+ allOf:
+ - $ref: '#/components/schemas/DefaultApiResponse'
+ - type: object
+ title: 响应数据
+ properties:
+ data:
+ allOf:
+ - type: object
+ title: 数据
+ properties:
+ applicationId:
+ title: 应用标识
+ type: string
+ externalId:
+ title: 应用内角色ID
+ type: string
accounts:
title: 用户帐号数据
type: array
title: 用户的帐号ID
type: string
-
- ApplicationRoleGroupsResponse:
+ ApplicationExternalRolesAccountsResponse:
allOf:
- $ref: '#/components/schemas/DefaultApiResponse'
- type: object
applicationId:
title: 应用标识
type: string
- rolecode:
- title: 角色代码
- type: string
- groupIds:
- title: 用户组ID列表
+ externalIds:
+ title: 应用内角色IDs
type: array
items:
- title: 用户组ID
+ title: 角色ID
type: string
- groups:
- title: 用户组列表
+ accounts:
+ title: 用户帐号数据
type: array
items:
- $ref: '#/components/schemas/GroupModel'
-
+ title: 用户的帐号ID
+ type: string