Documentation
¶
Index ¶
- func GetAccessToken(client *Client) (string, error)
- func QueryAccessToken(client *Client) (*dto.GetManagementTokenRespDto, error)
- type Client
- func (c *Client) AddDepartmentMembers(reqDto *dto.AddDepartmentMembersReqDto) *dto.IsSuccessRespDto
- func (c *Client) AddGroupMembers(reqDto *dto.AddGroupMembersReqDto) *dto.IsSuccessRespDto
- func (c *Client) AssignRole(reqDto *dto.AssignRoleDto) *dto.IsSuccessRespDto
- func (c *Client) AuthorizeResources(reqDto *dto.AuthorizeResourcesDto) *dto.IsSuccessRespDto
- func (c *Client) ChangeConnState(reqDto *dto.EnableExtIdpConnDto) *dto.IsSuccessRespDto
- func (c *Client) CreateDepartment(reqDto *dto.CreateDepartmentReqDto) *dto.DepartmentSingleRespDto
- func (c *Client) CreateExtIdp(reqDto *dto.CreateExtIdpDto) *dto.ExtIdpSingleRespDto
- func (c *Client) CreateExtIdpConn(reqDto *dto.CreateExtIdpConnDto) *dto.ExtIdpConnDetailSingleRespDto
- func (c *Client) CreateGroup(reqDto *dto.CreateGroupReqDto) *dto.GroupSingleRespDto
- func (c *Client) CreateGroupsBatch(reqDto *dto.CreateGroupBatchReqDto) *dto.GroupListRespDto
- func (c *Client) CreateNamespace(reqDto *dto.CreateNamespaceDto) *dto.NamespaceRespDto
- func (c *Client) CreateNamespacesBatch(reqDto *dto.CreateNamespacesBatchDto) *dto.IsSuccessRespDto
- func (c *Client) CreateOrganization(reqDto *dto.CreateOrganizationReqDto) *dto.OrganizationSingleRespDto
- func (c *Client) CreateResource(reqDto *dto.CreateResourceDto) *dto.ResourceRespDto
- func (c *Client) CreateResourcesBatch(reqDto *dto.CreateResourcesBatchDto) *dto.IsSuccessRespDto
- func (c *Client) CreateRole(reqDto *dto.CreateRoleDto) *dto.RoleSingleRespDto
- func (c *Client) CreateRolesBatch(reqDto *dto.CreateRolesBatch) *dto.IsSuccessRespDto
- func (c *Client) CreateUser(reqDto *dto.CreateUserReqDto) *dto.UserSingleRespDto
- func (c *Client) CreateUserBatch(reqDto *dto.CreateUserBatchReqDto) *dto.UserListRespDto
- func (c *Client) DeleteDepartment(reqDto *dto.DeleteDepartmentReqDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteExtIdp(reqDto *dto.DeleteExtIdpDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteExtIdpConn(reqDto *dto.DeleteExtIdpConnDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteGroupsBatch(reqDto *dto.DeleteGroupsReqDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteNamespace(reqDto *dto.DeleteNamespaceDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteNamespacesBatch(reqDto *dto.DeleteNamespacesBatchDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteOrganization(reqDto *dto.DeleteOrganizationReqDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteResource(reqDto *dto.DeleteResourceDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteResourcesBatch(reqDto *dto.DeleteResourcesBatchDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteRolesBatch(reqDto *dto.DeleteRoleDto) *dto.IsSuccessRespDto
- func (c *Client) DeleteUsersBatch(reqDto *dto.DeleteUsersBatchDto) *dto.IsSuccessRespDto
- func (c *Client) GetAuthorizedResources(reqDto *dto.GetAuthorizedResourcesDto) *dto.AuthorizedResourcePaginatedRespDto
- func (c *Client) GetCustomData(reqDto *dto.GetCustomDataDto) *dto.GetCustomDataRespDto
- func (c *Client) GetCustomFields(reqDto *dto.GetCustomFieldsDto) *dto.CustomFieldListRespDto
- func (c *Client) GetDepartment(reqDto *dto.GetDepartmentDto) *dto.DepartmentSingleRespDto
- func (c *Client) GetExtIdp(reqDto *dto.GetExtIdpDto) *dto.ExtIdpDetailSingleRespDto
- func (c *Client) GetGroup(reqDto *dto.GetGroupDto) *dto.GroupSingleRespDto
- func (c *Client) GetGroupAuthorizedResources(reqDto *dto.GetGroupAuthorizedResourcesDto) *dto.AuthorizedResourceListRespDto
- func (c *Client) GetManagementToken(reqDto *dto.GetManagementAccessTokenDto) *dto.GetManagementTokenRespDto
- func (c *Client) GetNamespace(reqDto *dto.GetNamespaceDto) *dto.NamespaceRespDto
- func (c *Client) GetNamespacesBatch(reqDto *dto.GetNamespacesBatchDto) *dto.NamespaceListRespDto
- func (c *Client) GetParentDepartment(reqDto *dto.GetParentDepartmentDto) *dto.DepartmentSingleRespDto
- func (c *Client) GetResource(reqDto *dto.GetResourceDto) *dto.ResourceRespDto
- func (c *Client) GetResourcesBatch(reqDto *dto.GetResourcesBatchDto) *dto.ResourceListRespDto
- func (c *Client) GetRole(reqDto *dto.GetRoleDto) *dto.RoleSingleRespDto
- func (c *Client) GetRoleAuthorizedResources(reqDto *dto.GetRoleAuthorizedResourcesDto) *dto.RoleAuthorizedResourcePaginatedRespDto
- func (c *Client) GetUser(reqDto *dto.GetUserDto) *dto.UserSingleRespDto
- func (c *Client) GetUserAccessibleApps(reqDto *dto.GetUserAccessibleAppsDto) *dto.AppListRespDto
- func (c *Client) GetUserAuthorizedApps(reqDto *dto.GetUserAuthorizedAppsDto) *dto.AppListRespDto
- func (c *Client) GetUserAuthorizedResources(reqDto *dto.GetUserAuthorizedResourcesDto) *dto.AuthorizedResourcePaginatedRespDto
- func (c *Client) GetUserBatch(reqDto *dto.GetUserBatchDto) *dto.UserListRespDto
- func (c *Client) GetUserDepartments(reqDto *dto.GetUserDepartmentsDto) *dto.UserDepartmentPaginatedRespDto
- func (c *Client) GetUserGroups(reqDto *dto.GetUserGroupsDto) *dto.GroupPaginatedRespDto
- func (c *Client) GetUserIdentities(reqDto *dto.GetUserIdentitiesDto) *dto.IdentityListRespDto
- func (c *Client) GetUserLoggedInApps(reqDto *dto.GetUserLoggedinAppsDto) *dto.UserLoggedInAppsListRespDto
- func (c *Client) GetUserLoggedInIdentities(reqDto *dto.GetUserLoggedInIdentitiesDto) *dto.UserLoggedInIdentitiesRespDto
- func (c *Client) GetUserLoginHistory(reqDto *dto.GetUserLoginHistoryDto) *dto.UserLoginHistoryPaginatedRespDto
- func (c *Client) GetUserMfaInfo(reqDto *dto.GetUserMfaInfoDto) *dto.UserMfaSingleRespDto
- func (c *Client) GetUserPrincipalAuthenticationInfo(reqDto *dto.GetUserPrincipalAuthenticationInfoDto) *dto.PrincipalAuthenticationInfoPaginatedRespDto
- func (c *Client) GetUserRoles(reqDto *dto.GetUserRolesDto) *dto.RolePaginatedRespDto
- func (c *Client) HasAnyRole(reqDto *dto.HasAnyRoleReqDto) *dto.HasAnyRoleRespDto
- func (c *Client) IsUserExists(reqDto *dto.IsUserExistsReqDto) *dto.IsUserExistsRespDto
- func (c *Client) KickUsers(reqDto *dto.KickUsersDto) *dto.IsSuccessRespDto
- func (c *Client) ListArchivedUsers(reqDto *dto.ListArchivedUsersDto) *dto.ListArchivedUsersSingleRespDto
- func (c *Client) ListChildrenDepartments(reqDto *dto.ListChildrenDepartmentsDto) *dto.DepartmentPaginatedRespDto
- func (c *Client) ListDepartmentMemberIds(reqDto *dto.ListDepartmentMemberIdsDto) *dto.UserIdListRespDto
- func (c *Client) ListDepartmentMembers(reqDto *dto.ListDepartmentMembersDto) *dto.UserPaginatedRespDto
- func (c *Client) ListExtIdp(reqDto *dto.ListExtIdpDto) *dto.ExtIdpListPaginatedRespDto
- func (c *Client) ListGroupMembers(reqDto *dto.ListGroupMembersDto) *dto.UserPaginatedRespDto
- func (c *Client) ListGroups(reqDto *dto.ListGroupsDto) *dto.GroupPaginatedRespDto
- func (c *Client) ListOrganizations(reqDto *dto.ListOrganizationsDto) *dto.OrganizationPaginatedRespDto
- func (c *Client) ListResources(reqDto *dto.ListResourcesDto) *dto.ResourcePaginatedRespDto
- func (c *Client) ListRoleDepartments(reqDto *dto.ListRoleDepartmentsDto) *dto.RoleDepartmentListPaginatedRespDto
- func (c *Client) ListRoleMembers(reqDto *dto.ListRoleMembersDto) *dto.UserPaginatedRespDto
- func (c *Client) ListRoles(reqDto *dto.ListRolesDto) *dto.RolePaginatedRespDto
- func (c *Client) ListUsers(reqDto *dto.ListUsersDto) *dto.UserPaginatedRespDto
- func (c *Client) RemoveDepartmentMembers(reqDto *dto.RemoveDepartmentMembersReqDto) *dto.IsSuccessRespDto
- func (c *Client) RemoveGroupMembers(reqDto *dto.RemoveGroupMembersReqDto) *dto.IsSuccessRespDto
- func (c *Client) ResetUserPrincipalAuthenticationInfo(reqDto *dto.ResetUserPrincipalAuthenticationInfoDto) *dto.IsSuccessRespDto
- func (c *Client) RevokeRole(reqDto *dto.RevokeRoleDto) *dto.IsSuccessRespDto
- func (c *Client) SearchDepartments(reqDto *dto.SearchDepartmentsReqDto) *dto.DepartmentListRespDto
- func (c *Client) SendHttpRequest(url string, method string, reqDto interface{}) ([]byte, error)
- func (c *Client) SetCustomData(reqDto *dto.SetCustomDataReqDto) *dto.IsSuccessRespDto
- func (c *Client) SetCustomFields(reqDto *dto.SetCustomFieldsReqDto) *dto.CustomFieldListRespDto
- func (c *Client) SetUserDepartment(reqDto *dto.SetUserDepartmentsDto) *dto.IsSuccessRespDto
- func (c *Client) UpdateDepartment(reqDto *dto.UpdateDepartmentReqDto) *dto.DepartmentSingleRespDto
- func (c *Client) UpdateExtIdp(reqDto *dto.UpdateExtIdpDto) *dto.ExtIdpSingleRespDto
- func (c *Client) UpdateExtIdpConn(reqDto *dto.UpdateExtIdpConnDto) *dto.ExtIdpConnDetailSingleRespDto
- func (c *Client) UpdateGroup(reqDto *dto.UpdateGroupReqDto) *dto.GroupSingleRespDto
- func (c *Client) UpdateNamespace(reqDto *dto.UpdateNamespaceDto) *dto.UpdateNamespaceRespDto
- func (c *Client) UpdateOrganization(reqDto *dto.UpdateOrganizationReqDto) *dto.OrganizationSingleRespDto
- func (c *Client) UpdateResource(reqDto *dto.UpdateResourceDto) *dto.ResourceRespDto
- func (c *Client) UpdateRole(reqDto *dto.UpdateRoleDto) *dto.IsSuccessRespDto
- func (c *Client) UpdateUser(reqDto *dto.UpdateUserReqDto) *dto.UserSingleRespDto
- type ClientOptions
- type JwtClaims
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetAccessToken ¶
func QueryAccessToken ¶
func QueryAccessToken(client *Client) (*dto.GetManagementTokenRespDto, error)
Types ¶
type Client ¶
func NewClient ¶
func NewClient(options *ClientOptions) (*Client, error)
func (*Client) AddDepartmentMembers ¶
func (c *Client) AddDepartmentMembers(reqDto *dto.AddDepartmentMembersReqDto) *dto.IsSuccessRespDto
* @summary 部门下添加成员 * @description 部门下添加成员 * @param requestBody * @returns IsSuccessRespDto
func (*Client) AddGroupMembers ¶
func (c *Client) AddGroupMembers(reqDto *dto.AddGroupMembersReqDto) *dto.IsSuccessRespDto
* @summary 添加分组成员 * @description 添加分组成员 * @param requestBody * @returns IsSuccessRespDto
func (*Client) AssignRole ¶
func (c *Client) AssignRole(reqDto *dto.AssignRoleDto) *dto.IsSuccessRespDto
* @summary 分配角色 * @description 分配角色,被分配者可以是用户,可以是部门 * @param requestBody * @returns IsSuccessRespDto
func (*Client) AuthorizeResources ¶
func (c *Client) AuthorizeResources(reqDto *dto.AuthorizeResourcesDto) *dto.IsSuccessRespDto
* @summary 授权资源 * @description 给多个主体同时授权多个资源 * @param requestBody * @returns IsSuccessRespDto
func (*Client) ChangeConnState ¶
func (c *Client) ChangeConnState(reqDto *dto.EnableExtIdpConnDto) *dto.IsSuccessRespDto
* @summary 身份源连接开关 * @description 身份源连接开关 * @param requestBody * @returns IsSuccessRespDto
func (*Client) CreateDepartment ¶
func (c *Client) CreateDepartment(reqDto *dto.CreateDepartmentReqDto) *dto.DepartmentSingleRespDto
* @summary 创建部门 * @description 创建部门 * @param requestBody * @returns DepartmentSingleRespDto
func (*Client) CreateExtIdp ¶
func (c *Client) CreateExtIdp(reqDto *dto.CreateExtIdpDto) *dto.ExtIdpSingleRespDto
* @summary 创建身份源 * @description 创建身份源 * @param requestBody * @returns ExtIdpSingleRespDto
func (*Client) CreateExtIdpConn ¶
func (c *Client) CreateExtIdpConn(reqDto *dto.CreateExtIdpConnDto) *dto.ExtIdpConnDetailSingleRespDto
* @summary 在某个已有身份源下创建新连接 * @description 在某个已有身份源下创建新连接 * @param requestBody * @returns ExtIdpConnDetailSingleRespDto
func (*Client) CreateGroup ¶
func (c *Client) CreateGroup(reqDto *dto.CreateGroupReqDto) *dto.GroupSingleRespDto
* @summary 创建分组 * @description 创建分组,一个分组必须包含一个用户池全局唯一的标志符(code),此标志符必须为一个合法的英文标志符,如 developers;以及分组名称 * @param requestBody * @returns GroupSingleRespDto
func (*Client) CreateGroupsBatch ¶
func (c *Client) CreateGroupsBatch(reqDto *dto.CreateGroupBatchReqDto) *dto.GroupListRespDto
* @summary 批量创建分组 * @description 批量创建分组 * @param requestBody * @returns GroupListRespDto
func (*Client) CreateNamespace ¶
func (c *Client) CreateNamespace(reqDto *dto.CreateNamespaceDto) *dto.NamespaceRespDto
* @summary 创建权限分组 * @description 创建权限分组 * @param requestBody * @returns NamespaceRespDto
func (*Client) CreateNamespacesBatch ¶
func (c *Client) CreateNamespacesBatch(reqDto *dto.CreateNamespacesBatchDto) *dto.IsSuccessRespDto
* @summary 批量创建权限分组 * @description 批量创建权限分组 * @param requestBody * @returns IsSuccessRespDto
func (*Client) CreateOrganization ¶
func (c *Client) CreateOrganization(reqDto *dto.CreateOrganizationReqDto) *dto.OrganizationSingleRespDto
* @summary 创建顶层组织机构 * @description 创建组织机构,会创建一个只有一个节点的组织机构 * @param requestBody * @returns OrganizationSingleRespDto
func (*Client) CreateResource ¶
func (c *Client) CreateResource(reqDto *dto.CreateResourceDto) *dto.ResourceRespDto
* @summary 创建资源 * @description 创建资源 * @param requestBody * @returns ResourceRespDto
func (*Client) CreateResourcesBatch ¶
func (c *Client) CreateResourcesBatch(reqDto *dto.CreateResourcesBatchDto) *dto.IsSuccessRespDto
* @summary 批量创建资源 * @description 批量创建资源 * @param requestBody * @returns IsSuccessRespDto
func (*Client) CreateRole ¶
func (c *Client) CreateRole(reqDto *dto.CreateRoleDto) *dto.RoleSingleRespDto
* @summary 创建角色 * @description 创建角色,可以指定不同的权限分组 * @param requestBody * @returns RoleSingleRespDto
func (*Client) CreateRolesBatch ¶
func (c *Client) CreateRolesBatch(reqDto *dto.CreateRolesBatch) *dto.IsSuccessRespDto
* @summary 批量创建角色 * @description 批量创建角色 * @param requestBody * @returns IsSuccessRespDto
func (*Client) CreateUser ¶
func (c *Client) CreateUser(reqDto *dto.CreateUserReqDto) *dto.UserSingleRespDto
* @summary 创建用户 * @description 创建用户,邮箱、手机号、用户名必须包含其中一个 * @param requestBody * @returns UserSingleRespDto
func (*Client) CreateUserBatch ¶
func (c *Client) CreateUserBatch(reqDto *dto.CreateUserBatchReqDto) *dto.UserListRespDto
* @summary 批量创建用户 * @description 此接口将以管理员身份批量创建用户,不需要进行手机号验证码检验等安全检测。用户的手机号、邮箱、用户名、externalId 用户池内唯一。 * @param requestBody * @returns UserListRespDto
func (*Client) DeleteDepartment ¶
func (c *Client) DeleteDepartment(reqDto *dto.DeleteDepartmentReqDto) *dto.IsSuccessRespDto
* @summary 删除部门 * @description 删除部门 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteExtIdp ¶
func (c *Client) DeleteExtIdp(reqDto *dto.DeleteExtIdpDto) *dto.IsSuccessRespDto
* @summary 删除身份源 * @description 删除身份源 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteExtIdpConn ¶
func (c *Client) DeleteExtIdpConn(reqDto *dto.DeleteExtIdpConnDto) *dto.IsSuccessRespDto
* @summary 删除身份源连接 * @description 删除身份源连接 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteGroupsBatch ¶
func (c *Client) DeleteGroupsBatch(reqDto *dto.DeleteGroupsReqDto) *dto.IsSuccessRespDto
* @summary 批量删除分组 * @description 批量删除分组 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteNamespace ¶
func (c *Client) DeleteNamespace(reqDto *dto.DeleteNamespaceDto) *dto.IsSuccessRespDto
* @summary 删除权限分组信息 * @description 删除权限分组信息 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteNamespacesBatch ¶
func (c *Client) DeleteNamespacesBatch(reqDto *dto.DeleteNamespacesBatchDto) *dto.IsSuccessRespDto
* @summary 批量删除权限分组 * @description 批量删除权限分组 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteOrganization ¶
func (c *Client) DeleteOrganization(reqDto *dto.DeleteOrganizationReqDto) *dto.IsSuccessRespDto
* @summary 删除组织机构 * @description 删除组织机构树 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteResource ¶
func (c *Client) DeleteResource(reqDto *dto.DeleteResourceDto) *dto.IsSuccessRespDto
* @summary 删除资源 * @description 删除资源 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteResourcesBatch ¶
func (c *Client) DeleteResourcesBatch(reqDto *dto.DeleteResourcesBatchDto) *dto.IsSuccessRespDto
* @summary 批量删除资源 * @description 批量删除资源 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteRolesBatch ¶
func (c *Client) DeleteRolesBatch(reqDto *dto.DeleteRoleDto) *dto.IsSuccessRespDto
* @summary (批量)删除角色 * @description 删除角色 * @param requestBody * @returns IsSuccessRespDto
func (*Client) DeleteUsersBatch ¶
func (c *Client) DeleteUsersBatch(reqDto *dto.DeleteUsersBatchDto) *dto.IsSuccessRespDto
* @summary 删除用户 * @description 删除用户(支持批量删除) * @param requestBody * @returns IsSuccessRespDto
func (*Client) GetAuthorizedResources ¶
func (c *Client) GetAuthorizedResources(reqDto *dto.GetAuthorizedResourcesDto) *dto.AuthorizedResourcePaginatedRespDto
* @summary 获取某个主体被授权的资源列表 * @description 获取某个主体被授权的资源列表 * @param targetType 目标对象类型 * @param targetIdentifier 目标对象唯一标志符 * @param namespace 所属权限分组的 code * @param resourceType 资源类型,如数据、API、按钮、菜单 * @param withDenied 是否获取被拒绝的资源 * @returns AuthorizedResourcePaginatedRespDto
func (*Client) GetCustomData ¶
func (c *Client) GetCustomData(reqDto *dto.GetCustomDataDto) *dto.GetCustomDataRespDto
* @summary 获取用户、分组、角色、组织机构的自定义字段值 * @description 获取用户、分组、角色、组织机构的自定义字段值 * @param targetType 主体类型,目前支持用户、角色、分组和部门 * @param targetIdentifier 目标对象唯一标志符 * @param namespace 所属权限分组的 code,当 targetType 为角色的时候需要填写,否则可以忽略。 * @returns GetCustomDataRespDto
func (*Client) GetCustomFields ¶
func (c *Client) GetCustomFields(reqDto *dto.GetCustomFieldsDto) *dto.CustomFieldListRespDto
* @summary 获取用户池配置的自定义字段列表 * @description 获取用户池配置的自定义字段列表 * @param targetType 主体类型,目前支持用户、角色、分组和部门 * @returns CustomFieldListRespDto
func (*Client) GetDepartment ¶
func (c *Client) GetDepartment(reqDto *dto.GetDepartmentDto) *dto.DepartmentSingleRespDto
* @summary 获取部门信息 * @description 获取部门信息 * @param organizationCode 组织 code * @param departmentId 部门 id,根部门传 `root` * @param departmentIdType 此次调用中使用的部门 ID 的类型 * @returns DepartmentSingleRespDto
func (*Client) GetExtIdp ¶
func (c *Client) GetExtIdp(reqDto *dto.GetExtIdpDto) *dto.ExtIdpDetailSingleRespDto
* @summary 获取身份源详情 * @description 获取身份源详情 * @param id 身份源 id * @param tenantId 租户 ID * @returns ExtIdpDetailSingleRespDto
func (*Client) GetGroup ¶
func (c *Client) GetGroup(reqDto *dto.GetGroupDto) *dto.GroupSingleRespDto
* @summary 获取分组详情 * @description 获取分组详情,通过 code 唯一标志用户池中的一个分组 * @param code 分组 code * @returns GroupSingleRespDto
func (*Client) GetGroupAuthorizedResources ¶
func (c *Client) GetGroupAuthorizedResources(reqDto *dto.GetGroupAuthorizedResourcesDto) *dto.AuthorizedResourceListRespDto
* @summary 获取分组被授权的资源列表 * @description 获取分组被授权的资源列表 * @param code 分组 code * @param namespace 所属权限分组的 code * @param resourceType 资源类型 * @returns AuthorizedResourceListRespDto
func (*Client) GetManagementToken ¶
func (c *Client) GetManagementToken(reqDto *dto.GetManagementAccessTokenDto) *dto.GetManagementTokenRespDto
* @summary 获取 Management API Token * @description 获取 Management API Token * @param requestBody * @returns GetManagementTokenRespDto
func (*Client) GetNamespace ¶
func (c *Client) GetNamespace(reqDto *dto.GetNamespaceDto) *dto.NamespaceRespDto
* @summary 获取权限分组详情 * @description 获取权限分组详情 * @param code 权限分组唯一标志符 * @returns NamespaceRespDto
func (*Client) GetNamespacesBatch ¶
func (c *Client) GetNamespacesBatch(reqDto *dto.GetNamespacesBatchDto) *dto.NamespaceListRespDto
* @summary 批量获取权限分组详情 * @description 批量获取权限分组详情 * @param codeList 资源 code 列表,批量可以使用逗号分隔 * @returns NamespaceListRespDto
func (*Client) GetParentDepartment ¶
func (c *Client) GetParentDepartment(reqDto *dto.GetParentDepartmentDto) *dto.DepartmentSingleRespDto
* @summary 获取父部门信息 * @description 获取父部门信息 * @param organizationCode 组织 code * @param departmentId 部门 id * @param departmentIdType 此次调用中使用的部门 ID 的类型 * @returns DepartmentSingleRespDto
func (*Client) GetResource ¶
func (c *Client) GetResource(reqDto *dto.GetResourceDto) *dto.ResourceRespDto
* @summary 获取资源详情 * @description 获取资源详情 * @param code 资源唯一标志符 * @param namespace 所属权限分组的 code * @returns ResourceRespDto
func (*Client) GetResourcesBatch ¶
func (c *Client) GetResourcesBatch(reqDto *dto.GetResourcesBatchDto) *dto.ResourceListRespDto
* @summary 批量获取资源详情 * @description 批量获取资源详情 * @param codeList 资源 code 列表,批量可以使用逗号分隔 * @param namespace 所属权限分组的 code * @returns ResourceListRespDto
func (*Client) GetRole ¶
func (c *Client) GetRole(reqDto *dto.GetRoleDto) *dto.RoleSingleRespDto
* @summary 获取角色详情 * @description 获取角色详情 * @param code 权限分组内角色的唯一标识符 * @param namespace 所属权限分组的 code * @returns RoleSingleRespDto
func (*Client) GetRoleAuthorizedResources ¶
func (c *Client) GetRoleAuthorizedResources(reqDto *dto.GetRoleAuthorizedResourcesDto) *dto.RoleAuthorizedResourcePaginatedRespDto
* @summary 角色被授权的资源列表 * @description 角色被授权的资源列表 * @param code 权限分组内角色的唯一标识符 * @param namespace 所属权限分组的 code * @param resourceType 资源类型 * @returns RoleAuthorizedResourcePaginatedRespDto
func (*Client) GetUser ¶
func (c *Client) GetUser(reqDto *dto.GetUserDto) *dto.UserSingleRespDto
* @summary 获取用户信息 * @description 通过 id、username、email、phone、email、externalId 获取用户详情 * @param userId 用户 ID * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @param phone 手机号 * @param email 邮箱 * @param username 用户名 * @param externalId 原系统 ID * @returns UserSingleRespDto
func (*Client) GetUserAccessibleApps ¶
func (c *Client) GetUserAccessibleApps(reqDto *dto.GetUserAccessibleAppsDto) *dto.AppListRespDto
* @summary 获取用户可访问应用 * @description 获取用户可访问应用 * @param userId 用户 ID * @returns AppListRespDto
func (*Client) GetUserAuthorizedApps ¶
func (c *Client) GetUserAuthorizedApps(reqDto *dto.GetUserAuthorizedAppsDto) *dto.AppListRespDto
* @summary 获取用户授权的应用 * @description 获取用户授权的应用 * @param userId 用户 ID * @returns AppListRespDto
func (*Client) GetUserAuthorizedResources ¶
func (c *Client) GetUserAuthorizedResources(reqDto *dto.GetUserAuthorizedResourcesDto) *dto.AuthorizedResourcePaginatedRespDto
* @summary 获取用户被授权的所有资源 * @description 获取用户被授权的所有资源,用户被授权的资源是用户自身被授予、通过分组继承、通过角色继承、通过组织机构继承的集合 * @param userId 用户 ID * @param namespace 所属权限分组的 code * @param resourceType 资源类型 * @returns AuthorizedResourcePaginatedRespDto
func (*Client) GetUserBatch ¶
func (c *Client) GetUserBatch(reqDto *dto.GetUserBatchDto) *dto.UserListRespDto
* @summary 批量获取用户信息 * @description 根据用户 id 批量获取用户信息 * @param userIds 用户 ID 数组 * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @returns UserListRespDto
func (*Client) GetUserDepartments ¶
func (c *Client) GetUserDepartments(reqDto *dto.GetUserDepartmentsDto) *dto.UserDepartmentPaginatedRespDto
* @summary 获取用户部门列表 * @description 获取用户部门列表 * @param userId 用户 ID * @returns UserDepartmentPaginatedRespDto
func (*Client) GetUserGroups ¶
func (c *Client) GetUserGroups(reqDto *dto.GetUserGroupsDto) *dto.GroupPaginatedRespDto
* @summary 获取用户分组列表 * @description 获取用户分组列表 * @param userId 用户 ID * @returns GroupPaginatedRespDto
func (*Client) GetUserIdentities ¶
func (c *Client) GetUserIdentities(reqDto *dto.GetUserIdentitiesDto) *dto.IdentityListRespDto
* @summary 获取用户的外部身份源 * @description 获取用户的外部身份源 * @param userId 用户 ID * @returns IdentityListRespDto
func (*Client) GetUserLoggedInApps ¶
func (c *Client) GetUserLoggedInApps(reqDto *dto.GetUserLoggedinAppsDto) *dto.UserLoggedInAppsListRespDto
* @summary 获取用户曾经登录过的应用 * @description 获取用户曾经登录过的应用 * @param userId 用户 ID * @returns UserLoggedInAppsListRespDto
func (*Client) GetUserLoggedInIdentities ¶
func (c *Client) GetUserLoggedInIdentities(reqDto *dto.GetUserLoggedInIdentitiesDto) *dto.UserLoggedInIdentitiesRespDto
* @summary 获取用户曾经登录过的身份源 * @description 获取用户曾经登录过的身份源 * @param userId 用户 ID * @returns UserLoggedInIdentitiesRespDto
func (*Client) GetUserLoginHistory ¶
func (c *Client) GetUserLoginHistory(reqDto *dto.GetUserLoginHistoryDto) *dto.UserLoginHistoryPaginatedRespDto
* @summary 获取用户的登录历史记录 * @description 获取用户登录历史记录 * @param userId 用户 ID * @param appId 应用 ID * @param clientIp 客户端 IP * @param start 开始时间戳(毫秒) * @param end 结束时间戳(毫秒) * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns UserLoginHistoryPaginatedRespDto
func (*Client) GetUserMfaInfo ¶
func (c *Client) GetUserMfaInfo(reqDto *dto.GetUserMfaInfoDto) *dto.UserMfaSingleRespDto
* @summary 获取用户 MFA 绑定信息 * @description 获取用户 MFA 绑定信息 * @param userId 用户 ID * @returns UserMfaSingleRespDto
func (*Client) GetUserPrincipalAuthenticationInfo ¶
func (c *Client) GetUserPrincipalAuthenticationInfo(reqDto *dto.GetUserPrincipalAuthenticationInfoDto) *dto.PrincipalAuthenticationInfoPaginatedRespDto
* @summary 获取用户实名认证信息 * @description 获取用户实名认证信息 * @param userId 用户 ID * @returns PrincipalAuthenticationInfoPaginatedRespDto
func (*Client) GetUserRoles ¶
func (c *Client) GetUserRoles(reqDto *dto.GetUserRolesDto) *dto.RolePaginatedRespDto
* @summary 获取用户角色列表 * @description 获取用户角色列表 * @param userId 用户 ID * @param namespace 所属权限分组的 code * @returns RolePaginatedRespDto
func (*Client) HasAnyRole ¶
func (c *Client) HasAnyRole(reqDto *dto.HasAnyRoleReqDto) *dto.HasAnyRoleRespDto
* @summary 判断用户是否有某个角色 * @description 判断用户是否有某个角色,支持同时传入多个角色进行判断 * @param requestBody * @returns HasAnyRoleRespDto
func (*Client) IsUserExists ¶
func (c *Client) IsUserExists(reqDto *dto.IsUserExistsReqDto) *dto.IsUserExistsRespDto
* @summary 判断用户是否存在 * @description 根据条件判断用户是否存在 * @param requestBody * @returns IsUserExistsRespDto
func (*Client) KickUsers ¶
func (c *Client) KickUsers(reqDto *dto.KickUsersDto) *dto.IsSuccessRespDto
* @summary 强制下线用户 * @description 强制下线用户 * @param requestBody * @returns IsSuccessRespDto
func (*Client) ListArchivedUsers ¶
func (c *Client) ListArchivedUsers(reqDto *dto.ListArchivedUsersDto) *dto.ListArchivedUsersSingleRespDto
* @summary 获取已归档的用户列表 * @description 获取已归档的用户列表 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns ListArchivedUsersSingleRespDto
func (*Client) ListChildrenDepartments ¶
func (c *Client) ListChildrenDepartments(reqDto *dto.ListChildrenDepartmentsDto) *dto.DepartmentPaginatedRespDto
* @summary 获取子部门列表 * @description 获取子部门列表 * @param departmentId 需要获取的部门 ID * @param organizationCode 组织 code * @param departmentIdType 此次调用中使用的部门 ID 的类型 * @returns DepartmentPaginatedRespDto
func (*Client) ListDepartmentMemberIds ¶
func (c *Client) ListDepartmentMemberIds(reqDto *dto.ListDepartmentMemberIdsDto) *dto.UserIdListRespDto
* @summary 获取部门直属成员 ID 列表 * @description 获取部门直属成员 ID 列表 * @param organizationCode 组织 code * @param departmentId 部门 id,根部门传 `root` * @param departmentIdType 此次调用中使用的部门 ID 的类型 * @returns UserIdListRespDto
func (*Client) ListDepartmentMembers ¶
func (c *Client) ListDepartmentMembers(reqDto *dto.ListDepartmentMembersDto) *dto.UserPaginatedRespDto
* @summary 获取部门成员列表 * @description 获取部门成员列表 * @param organizationCode 组织 code * @param departmentId 部门 id,根部门传 `root` * @param departmentIdType 此次调用中使用的部门 ID 的类型 * @param includeChildrenDepartments 是否包含子部门的成员 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @returns UserPaginatedRespDto
func (*Client) ListExtIdp ¶
func (c *Client) ListExtIdp(reqDto *dto.ListExtIdpDto) *dto.ExtIdpListPaginatedRespDto
* @summary 获取身份源列表 * @description 获取身份源列表 * @param tenantId 租户 ID * @returns ExtIdpListPaginatedRespDto
func (*Client) ListGroupMembers ¶
func (c *Client) ListGroupMembers(reqDto *dto.ListGroupMembersDto) *dto.UserPaginatedRespDto
* @summary 获取分组成员列表 * @description 获取分组成员列表 * @param code 分组 code * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @returns UserPaginatedRespDto
func (*Client) ListGroups ¶
func (c *Client) ListGroups(reqDto *dto.ListGroupsDto) *dto.GroupPaginatedRespDto
* @summary 获取分组列表 * @description 获取分组列表接口,支持分页 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns GroupPaginatedRespDto
func (*Client) ListOrganizations ¶
func (c *Client) ListOrganizations(reqDto *dto.ListOrganizationsDto) *dto.OrganizationPaginatedRespDto
* @summary 获取顶层组织机构列表 * @description 获取顶层组织机构列表 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @param fetchAll 拉取所有 * @returns OrganizationPaginatedRespDto
func (*Client) ListResources ¶
func (c *Client) ListResources(reqDto *dto.ListResourcesDto) *dto.ResourcePaginatedRespDto
* @summary 分页获取资源列表 * @description 分页获取资源列表 * @param namespace 所属权限分组的 code * @param type 资源类型 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns ResourcePaginatedRespDto
func (*Client) ListRoleDepartments ¶
func (c *Client) ListRoleDepartments(reqDto *dto.ListRoleDepartmentsDto) *dto.RoleDepartmentListPaginatedRespDto
* @summary 获取角色的部门列表 * @description 获取角色的部门列表 * @param code 权限分组内角色的唯一标识符 * @param namespace 所属权限分组的 code * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns RoleDepartmentListPaginatedRespDto
func (*Client) ListRoleMembers ¶
func (c *Client) ListRoleMembers(reqDto *dto.ListRoleMembersDto) *dto.UserPaginatedRespDto
* @summary 获取角色成员列表 * @description 获取角色成员列表 * @param code 权限分组内角色的唯一标识符 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @param namespace 所属权限分组的 code * @returns UserPaginatedRespDto
func (*Client) ListRoles ¶
func (c *Client) ListRoles(reqDto *dto.ListRolesDto) *dto.RolePaginatedRespDto
* @summary 获取角色列表 * @description 获取角色列表 * @param namespace 所属权限分组的 code * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @returns RolePaginatedRespDto
func (*Client) ListUsers ¶
func (c *Client) ListUsers(reqDto *dto.ListUsersDto) *dto.UserPaginatedRespDto
* @summary 获取用户列表 * @description 获取用户列表接口,支持分页 * @param page 当前页数,从 1 开始 * @param limit 每页数目,最大不能超过 50,默认为 10 * @param withCustomData 是否获取自定义数据 * @param withIdentities 是否获取 identities * @param withDepartmentIds 是否获取部门 ID 列表 * @returns UserPaginatedRespDto
func (*Client) RemoveDepartmentMembers ¶
func (c *Client) RemoveDepartmentMembers(reqDto *dto.RemoveDepartmentMembersReqDto) *dto.IsSuccessRespDto
* @summary 部门下删除成员 * @description 部门下删除成员 * @param requestBody * @returns IsSuccessRespDto
func (*Client) RemoveGroupMembers ¶
func (c *Client) RemoveGroupMembers(reqDto *dto.RemoveGroupMembersReqDto) *dto.IsSuccessRespDto
* @summary 批量移除分组成员 * @description 批量移除分组成员 * @param requestBody * @returns IsSuccessRespDto
func (*Client) ResetUserPrincipalAuthenticationInfo ¶
func (c *Client) ResetUserPrincipalAuthenticationInfo(reqDto *dto.ResetUserPrincipalAuthenticationInfoDto) *dto.IsSuccessRespDto
* @summary 删除用户实名认证信息 * @description 删除用户实名认证信息 * @param requestBody * @returns IsSuccessRespDto
func (*Client) RevokeRole ¶
func (c *Client) RevokeRole(reqDto *dto.RevokeRoleDto) *dto.IsSuccessRespDto
* @summary 移除分配的角色 * @description 移除分配的角色,被分配者可以是用户,可以是部门 * @param requestBody * @returns IsSuccessRespDto
func (*Client) SearchDepartments ¶
func (c *Client) SearchDepartments(reqDto *dto.SearchDepartmentsReqDto) *dto.DepartmentListRespDto
* @summary 搜索部门 * @description 搜索部门 * @param requestBody * @returns DepartmentListRespDto
func (*Client) SendHttpRequest ¶
func (*Client) SetCustomData ¶
func (c *Client) SetCustomData(reqDto *dto.SetCustomDataReqDto) *dto.IsSuccessRespDto
* @summary 设置自定义字段的值 * @description 给用户、角色、部门设置自定义字段的值,如果存在则更新,不存在则创建。 * @param requestBody * @returns IsSuccessRespDto
func (*Client) SetCustomFields ¶
func (c *Client) SetCustomFields(reqDto *dto.SetCustomFieldsReqDto) *dto.CustomFieldListRespDto
* @summary 创建/修改自定义字段定义 * @description 创建/修改自定义字段定义,如果传入的 key 不存在则创建,存在则更新。 * @param requestBody * @returns CustomFieldListRespDto
func (*Client) SetUserDepartment ¶
func (c *Client) SetUserDepartment(reqDto *dto.SetUserDepartmentsDto) *dto.IsSuccessRespDto
* @summary 设置用户所在部门 * @description 设置用户所在部门 * @param requestBody * @returns IsSuccessRespDto
func (*Client) UpdateDepartment ¶
func (c *Client) UpdateDepartment(reqDto *dto.UpdateDepartmentReqDto) *dto.DepartmentSingleRespDto
* @summary 修改部门 * @description 修改部门 * @param requestBody * @returns DepartmentSingleRespDto
func (*Client) UpdateExtIdp ¶
func (c *Client) UpdateExtIdp(reqDto *dto.UpdateExtIdpDto) *dto.ExtIdpSingleRespDto
* @summary 更新身份源配置 * @description 更新身份源配置 * @param requestBody * @returns ExtIdpSingleRespDto
func (*Client) UpdateExtIdpConn ¶
func (c *Client) UpdateExtIdpConn(reqDto *dto.UpdateExtIdpConnDto) *dto.ExtIdpConnDetailSingleRespDto
* @summary 更新身份源连接 * @description 更新身份源连接 * @param requestBody * @returns ExtIdpConnDetailSingleRespDto
func (*Client) UpdateGroup ¶
func (c *Client) UpdateGroup(reqDto *dto.UpdateGroupReqDto) *dto.GroupSingleRespDto
* @summary 修改分组 * @description 修改分组,通过 code 唯一标志用户池中的一个分组。你可以修改此分组的 code * @param requestBody * @returns GroupSingleRespDto
func (*Client) UpdateNamespace ¶
func (c *Client) UpdateNamespace(reqDto *dto.UpdateNamespaceDto) *dto.UpdateNamespaceRespDto
* @summary 修改权限分组信息 * @description 修改权限分组信息 * @param requestBody * @returns UpdateNamespaceRespDto
func (*Client) UpdateOrganization ¶
func (c *Client) UpdateOrganization(reqDto *dto.UpdateOrganizationReqDto) *dto.OrganizationSingleRespDto
* @summary 修改顶层组织机构 * @description 修改顶层组织机构 * @param requestBody * @returns OrganizationSingleRespDto
func (*Client) UpdateResource ¶
func (c *Client) UpdateResource(reqDto *dto.UpdateResourceDto) *dto.ResourceRespDto
* @summary 修改资源 * @description 修改资源(Pratial Update) * @param requestBody * @returns ResourceRespDto
func (*Client) UpdateRole ¶
func (c *Client) UpdateRole(reqDto *dto.UpdateRoleDto) *dto.IsSuccessRespDto
* @summary 修改角色 * @description 修改角色 * @param requestBody * @returns IsSuccessRespDto
func (*Client) UpdateUser ¶
func (c *Client) UpdateUser(reqDto *dto.UpdateUserReqDto) *dto.UserSingleRespDto
* @summary 修改用户资料 * @description 修改用户资料 * @param requestBody * @returns UserSingleRespDto