AuthOrganizationClient class final

Typed client for the opt-in organization plugin.

Constructors

AuthOrganizationClient({required AuthClientTransport transport, Map<String, AuthOrganizationPermissionSet>? staticRoles})
Creates an instance of AuthOrganizationClient.

Properties

activeOrganizationId String?
The identifier of active organization.
getter/setter pair
activeTeamId String?
The identifier of active team.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
transport AuthClientTransport
The transport used to send client requests.
final

Methods

acceptInvitation(String invitationId) Future<AuthOrganizationMutationResult<AuthOrganizationMember>>
Performs the accept invitation operation.
addTeamMember({required String teamId, required String userId, required String idempotencyKey}) Future<AuthOrganizationMutationResult<AuthOrganizationTeamMember>>
Adds team member.
cancelInvitation(String invitationId) Future<AuthOrganizationMutationResult<AuthOrganizationInvitation>>
Returns whether this value can cel invitation.
checkSlug(String slug) Future<bool>
Performs the check slug operation.
create({required String name, required String slug, required String idempotencyKey, Map<String, dynamic>? metadata, bool keepCurrentActiveOrganization = false}) Future<AuthOrganizationMutationResult<AuthOrganization>>
Creates the requested value.
createRole({required String name, required Map<String, Iterable<String>> permissions, required String idempotencyKey, String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationRole>>
Creates role.
createTeam({required String name, required String idempotencyKey, String? organizationId, Map<String, dynamic>? attributes}) Future<AuthOrganizationMutationResult<AuthOrganizationTeam>>
Creates team.
delete({String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganization>>
Deletes the requested value.
deleteRole(String name, {String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationRole>>
Deletes role.
get({String? organizationId}) Future<AuthOrganization>
Looks up the requested value.
getActiveMember({String? organizationId}) Future<AuthOrganizationMember>
Looks up active member.
getActiveMemberRole({String? organizationId}) Future<List<String>>
Looks up active member role.
getFull({String? organizationId, int membersLimit = 100}) Future<AuthOrganizationDetails>
Looks up full.
getInvitation(String invitationId) Future<AuthOrganizationInvitation>
Looks up invitation.
getRole(String name, {String? organizationId}) Future<AuthOrganizationRole>
Looks up role.
hasPermission({required String resource, required String action, String? organizationId}) Future<bool>
Returns whether this value has permission.
inviteMember({required String email, required String idempotencyKey, Iterable<String> roles = const ['member'], String? organizationId, String? teamId}) Future<AuthOrganizationMutationResult<AuthOrganizationInvitation>>
Performs the invite member operation.
leave({String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationMember>>
Performs the leave operation.
list() Future<List<AuthOrganization>>
Lists the requested value.
listInvitations({String? organizationId}) Future<List<AuthOrganizationInvitation>>
Lists invitations.
listMembers({String? organizationId, int limit = 100, int offset = 0}) Future<AuthOrganizationPage<AuthOrganizationMember>>
Lists members.
listRoles({String? organizationId}) Future<List<AuthOrganizationRole>>
Lists roles.
listTeamMembers(String teamId) Future<List<AuthOrganizationTeamMember>>
Lists team members.
listTeams({String? organizationId}) Future<List<AuthOrganizationTeam>>
Lists teams.
listUserInvitations() Future<List<AuthOrganizationInvitation>>
Lists user invitations.
listUserTeams({String? organizationId}) Future<List<AuthOrganizationTeam>>
Lists user teams.
localRoleAllows(Iterable<String> roles, String resource, String action) bool
Performs the local role allows operation.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
rejectInvitation(String invitationId) Future<AuthOrganizationMutationResult<AuthOrganizationInvitation>>
Performs the reject invitation operation.
removeMember({required String userId, String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationMember>>
Deletes member.
removeTeam(String teamId) Future<AuthOrganizationMutationResult<AuthOrganizationTeam>>
Deletes team.
removeTeamMember({required String teamId, required String userId}) Future<AuthOrganizationMutationResult<AuthOrganizationTeamMember>>
Deletes team member.
setActive(String? organizationId) Future<void>
Sets active.
setActiveTeam(String? teamId) Future<void>
Sets active team.
toString() String
A string representation of this object.
inherited
update({String? organizationId, String? name, String? slug, Object? metadata}) Future<AuthOrganizationMutationResult<AuthOrganization>>
Updates the requested value.
updateMemberRole({required String userId, required Iterable<String> roles, String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationMember>>
Updates member role.
updateRole({required String name, String? newName, Map<String, Iterable<String>>? permissions, String? organizationId}) Future<AuthOrganizationMutationResult<AuthOrganizationRole>>
Updates role.
updateTeam({required String teamId, required String name}) Future<AuthOrganizationMutationResult<AuthOrganizationTeam>>
Updates team.

Operators

operator ==(Object other) bool
The equality operator.
inherited