Files
cloudpods/docs/schemas/roleassignments.yaml

100 lines
2.0 KiB
YAML

RoleAssignmentListResponse:
type: object
properties:
limit:
type: integer
example: 20
offset:
type: integer
example: 0
total:
type: integer
description: 总量
role_assignments:
type: array
items:
$ref: "./roleassignments.yaml#/RoleAssignment"
RoleAssignment:
type: object
description: RoleAssignment
properties:
scope:
type: object
description: 角色分配的范围
$ref: './roleassignments.yaml#/Scope'
user:
type: object
description: 角色分配的用户
$ref: './roleassignments.yaml#/DomainObject'
group:
type: object
description: 角色分配的组
$ref: './roleassignments.yaml#/DomainObject'
role:
type: object
description: 角色
$ref: './roleassignments.yaml#/DomainObject'
policies:
type: object
description: 匹配的权限列表
$ref: './roleassignments.yaml#/PolicyObject'
PolicyObject:
type: object
description: 匹配的权限列表
properties:
project:
type: array
items:
type: string
domain:
type: array
items:
type: string
system:
type: array
items:
type: string
Scope:
type: object
description: 角色分配的范围
properties:
project:
type: object
description: 角色分配关联的项目
$ref: '#/DomainObject'
domain:
type: object
description: 角色分配的域
$ref: '#/Domain'
DomainObject:
type: object
description: 域下的资源,可能为用户,组,项目
properties:
id:
type: string
description: 资源ID
name:
type: string
description: 资源名称
domain:
type: object
description: 资源归属的域信息
$ref: './roleassignments.yaml#/Domain'
Domain:
type: object
description: 域的信息
properties:
id:
type: string
description: 域ID
name:
type: string
description: 域名称