POST /admin/tenants/{tenant_id}/applications/{app_id}/members

为用户在指定应用中分配角色和权限

租户服务 `bearerAuth` application/json

请求参数

名称位置类型必填默认值示例约束描述
tenant_id path string 是 租户ID
app_id path string 是 应用ID

请求体

Schema: service-tenant/internal/handler/dto.AssignUserAppRoleRequest

字段类型必填示例约束描述
role string 是 admin
user_id string 是 usr_xyz789
expires_at string 否
permissions array of

string

否 ['["read"', '"write"]']

响应

引用的 Schema

service-core/base/dto.SimpleResponse

字段类型必填示例约束描述
code integer 否
message string 否
timestamp string 否

service-tenant/internal/handler/dto.UserAppRoleDetailResponse

字段类型必填示例约束描述
code integer 否
data service-tenant/internal/handler/dto.UserAppRoleResponse 否
message string 否

service-tenant/internal/handler/dto.UserAppRoleResponse

用户应用角色详情

字段类型必填示例约束描述
application_id string 否 app_abc123
assigned_by string 否
created_at string 否
expires_at string 否
id string 否 uar_abc123
is_active boolean 否
permissions array of

string

否 ['["read"', '"write"]']
role string 否 admin
tenant_id string 否 tnt_abc123
updated_at string 否
user_id string 否 usr_xyz789