Documentation ¶
Index ¶
- Variables
- func WithContext(ctx context.Context, gqlContext *Context) context.Context
- type AuditLogFacade
- type AuditLogLoader
- type AuthenticatorFacade
- type AuthenticatorLoader
- type AuthorizationFacade
- type Context
- type EntityRef
- type EventService
- type ForgotPasswordService
- type GroupLoader
- type IdentityFacade
- type IdentityLoader
- type Logger
- type OAuthFacade
- type OTPCodeService
- type OTPPurpose
- type Resolver
- type RoleLoader
- type RolesGroupsFacade
- type SessionFacade
- type SessionListingService
- type UserFacade
- type UserLoader
- type UserProfileFacade
- type VerificationFacade
Constants ¶
This section is empty.
Variables ¶
View Source
var AuditLogData = graphqlutil.NewJSONObjectScalar(
"AuditLogData",
"The `AuditLogData` scalar type represents the data of the audit log",
)
View Source
var AuthenticatorClaims = graphqlutil.NewJSONObjectScalar(
"AuthenticatorClaims",
"The `AuthenticatorClaims` scalar type represents a set of claims belonging to an authenticator",
)
View Source
var IdentityClaims = graphqlutil.NewJSONObjectScalar(
"IdentityClaims",
"The `IdentityClaims` scalar type represents a set of claims belonging to an identity",
)
View Source
var Schema *graphql.Schema
View Source
var UserCustomAttributes = graphqlutil.NewJSONObjectScalar(
"UserCustomAttributes",
"The `UserCustomAttributes` scalar type represents the custom attributes of the user",
)
View Source
var UserStandardAttributes = graphqlutil.NewJSONObjectScalar(
"UserStandardAttributes",
"The `UserStandardAttributes` scalar type represents the standard attributes of the user",
)
View Source
var Web3Claims = graphqlutil.NewJSONObjectScalar(
"Web3Claims",
"The `Web3Claims` scalar type represents the scalar type of the user",
)
Functions ¶
Types ¶
type AuditLogFacade ¶
type AuditLogFacade interface {
QueryPage(ctx context.Context, opts audit.QueryPageOptions, pageArgs graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error)
}
type AuditLogLoader ¶
type AuditLogLoader interface { graphqlutil.DataLoaderInterface }
type AuthenticatorFacade ¶
type AuthenticatorFacade interface { Get(ctx context.Context, id string) (*authenticator.Info, error) List(ctx context.Context, userID string, authenticatorType *apimodel.AuthenticatorType, authenticatorKind *authenticator.Kind) ([]*authenticator.Ref, error) Remove(ctx context.Context, authenticatorInfo *authenticator.Info) error CreateBySpec(ctx context.Context, spec *authenticator.Spec) (*authenticator.Info, error) }
type AuthenticatorLoader ¶
type AuthenticatorLoader interface { graphqlutil.DataLoaderInterface }
type AuthorizationFacade ¶
type AuthorizationFacade interface { Get(ctx context.Context, id string) (*oauth.Authorization, error) List(ctx context.Context, userID string, filters ...oauth.AuthorizationFilter) ([]*oauth.Authorization, error) Delete(ctx context.Context, a *oauth.Authorization) error }
type Context ¶
type Context struct { GQLLogger Logger Config *config.AppConfig OAuthConfig *config.OAuthConfig AdminAPIFeatureConfig *config.AdminAPIFeatureConfig Users UserLoader Identities IdentityLoader Authenticators AuthenticatorLoader Roles RoleLoader Groups GroupLoader AuditLogs AuditLogLoader UserFacade UserFacade RolesGroupsFacade RolesGroupsFacade AuditLogFacade AuditLogFacade IdentityFacade IdentityFacade AuthenticatorFacade AuthenticatorFacade VerificationFacade VerificationFacade SessionFacade SessionFacade UserProfileFacade UserProfileFacade AuthorizationFacade AuthorizationFacade OAuthFacade OAuthFacade SessionListing SessionListingService OTPCode OTPCodeService ForgotPassword ForgotPasswordService Events EventService }
func GQLContext ¶
type EventService ¶
type ForgotPasswordService ¶
type ForgotPasswordService interface {
SendCode(ctx context.Context, loginID string, options *forgotpassword.CodeOptions) error
}
type GroupLoader ¶
type GroupLoader interface { graphqlutil.DataLoaderInterface }
type IdentityFacade ¶
type IdentityFacade interface { Get(ctx context.Context, id string) (*identity.Info, error) List(ctx context.Context, userID string, identityType *apimodel.IdentityType) ([]*apimodel.IdentityRef, error) Remove(ctx context.Context, identityInfo *identity.Info) error Create(ctx context.Context, userID string, identityDef model.IdentityDef, password string) (*apimodel.IdentityRef, error) Update(ctx context.Context, identityID string, userID string, identityDef model.IdentityDef) (*apimodel.IdentityRef, error) }
type IdentityLoader ¶
type IdentityLoader interface { graphqlutil.DataLoaderInterface }
type OAuthFacade ¶
type OAuthFacade interface {
CreateSession(ctx context.Context, clientID string, userID string) (session.ListableSession, protocol.TokenResponse, error)
}
type OTPCodeService ¶
type OTPPurpose ¶
type OTPPurpose string
const ( OTPPurposeLogin OTPPurpose = "login" OTPPurposeVerification OTPPurpose = "verification" )
type RoleLoader ¶
type RoleLoader interface { graphqlutil.DataLoaderInterface }
type RolesGroupsFacade ¶
type RolesGroupsFacade interface { CreateRole(ctx context.Context, options *rolesgroups.NewRoleOptions) (string, error) UpdateRole(ctx context.Context, options *rolesgroups.UpdateRoleOptions) error DeleteRole(ctx context.Context, id string) error ListGroupsByRoleID(ctx context.Context, roleID string) ([]*apimodel.Group, error) ListRoles(ctx context.Context, options *rolesgroups.ListRolesOptions, pageArgs graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) CreateGroup(ctx context.Context, options *rolesgroups.NewGroupOptions) (string, error) UpdateGroup(ctx context.Context, options *rolesgroups.UpdateGroupOptions) error DeleteGroup(ctx context.Context, id string) error ListRolesByGroupID(ctx context.Context, groupID string) ([]*apimodel.Role, error) ListGroups(ctx context.Context, options *rolesgroups.ListGroupsOptions, pageArgs graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) AddRoleToGroups(ctx context.Context, options *rolesgroups.AddRoleToGroupsOptions) (string, error) RemoveRoleFromGroups(ctx context.Context, options *rolesgroups.RemoveRoleFromGroupsOptions) (string, error) AddRoleToUsers(ctx context.Context, options *rolesgroups.AddRoleToUsersOptions) (string, error) RemoveRoleFromUsers(ctx context.Context, options *rolesgroups.RemoveRoleFromUsersOptions) (string, error) AddGroupToUsers(ctx context.Context, options *rolesgroups.AddGroupToUsersOptions) (groupID string, err error) RemoveGroupFromUsers(ctx context.Context, options *rolesgroups.RemoveGroupFromUsersOptions) (groupID string, err error) AddGroupToRoles(ctx context.Context, options *rolesgroups.AddGroupToRolesOptions) (groupID string, err error) RemoveGroupFromRoles(ctx context.Context, options *rolesgroups.RemoveGroupFromRolesOptions) (groupID string, err error) AddUserToRoles(ctx context.Context, options *rolesgroups.AddUserToRolesOptions) (err error) RemoveUserFromRoles(ctx context.Context, options *rolesgroups.RemoveUserFromRolesOptions) (err error) AddUserToGroups(ctx context.Context, options *rolesgroups.AddUserToGroupsOptions) (err error) RemoveUserFromGroups(ctx context.Context, options *rolesgroups.RemoveUserFromGroupsOptions) (err error) ListRolesByUserID(ctx context.Context, userID string) ([]*apimodel.Role, error) ListGroupsByUserID(ctx context.Context, userID string) ([]*apimodel.Group, error) ListUserIDsByRoleID(ctx context.Context, roleID string, pageArgs graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) ListUserIDsByGroupID(ctx context.Context, groupID string, pageArgs graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) ListEffectiveRolesByUserID(ctx context.Context, userID string) ([]*apimodel.Role, error) ListAllUserIDsByGroupIDs(ctx context.Context, groupIDs []string) ([]string, error) ListAllUserIDsByGroupKeys(ctx context.Context, groupKeys []string) ([]string, error) ListAllUserIDsByRoleIDs(ctx context.Context, roleIDs []string) ([]string, error) ListAllUserIDsByEffectiveRoleIDs(ctx context.Context, roleIDs []string) ([]string, error) ListAllRolesByKeys(ctx context.Context, keys []string) ([]*apimodel.Role, error) ListAllGroupsByKeys(ctx context.Context, keys []string) ([]*apimodel.Group, error) GetRole(ctx context.Context, roleID string) (*apimodel.Role, error) GetGroup(ctx context.Context, groupID string) (*apimodel.Group, error) }
type SessionFacade ¶
type SessionListingService ¶
type SessionListingService interface {
FilterForDisplay(ctx context.Context, sessions []session.ListableSession, currentSession session.ResolvedSession) ([]*sessionlisting.Session, error)
}
type UserFacade ¶
type UserFacade interface { ListPage(ctx context.Context, listOption libuser.ListOptions, args graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) SearchPage( ctx context.Context, searchKeyword string, filterOptions libuser.FilterOptions, sortOption libuser.SortOption, args graphqlutil.PageArgs) ([]apimodel.PageItemRef, *graphqlutil.PageResult, error) Create(ctx context.Context, identityDef model.IdentityDef, password string, generatePassword bool, sendPassword bool, setPasswordExpired bool) (string, error) ResetPassword(ctx context.Context, id string, password string, generatePassword bool, sendPassword bool, changeOnLogin bool) error SetPasswordExpired(ctx context.Context, id string, isExpired bool) error SetDisabled(ctx context.Context, id string, isDisabled bool, reason *string) error ScheduleDeletion(ctx context.Context, id string) error UnscheduleDeletion(ctx context.Context, id string) error Delete(ctx context.Context, id string) error ScheduleAnonymization(ctx context.Context, id string) error UnscheduleAnonymization(ctx context.Context, id string) error Anonymize(ctx context.Context, id string) error SetMFAGracePeriod(ctx context.Context, id string, endAt *time.Time) error GetUsersByStandardAttribute(ctx context.Context, attributeKey string, attributeValue string) ([]string, error) GetUserByLoginID(ctx context.Context, loginIDKey string, loginIDValue string) (string, error) GetUserByOAuth(ctx context.Context, oauthProviderAlias string, oauthProviderUserID string) (string, error) }
type UserLoader ¶
type UserLoader interface { graphqlutil.DataLoaderInterface }
type UserProfileFacade ¶
type UserProfileFacade interface { DeriveStandardAttributes(ctx context.Context, role accesscontrol.Role, userID string, updatedAt time.Time, attrs map[string]interface{}) (map[string]interface{}, error) ReadCustomAttributesInStorageForm(ctx context.Context, role accesscontrol.Role, userID string, storageForm map[string]interface{}) (map[string]interface{}, error) UpdateUserProfile( ctx context.Context, role accesscontrol.Role, userID string, stdAttrs map[string]interface{}, customAttrs map[string]interface{}, ) error }
Source Files ¶
- audit_log.go
- authenticator.go
- authenticator_def.go
- authenticator_mutation.go
- authorization.go
- authorization_mutation.go
- context.go
- deps.go
- entity.go
- group.go
- group_mutation.go
- group_role_mutation.go
- group_user_mutation.go
- identity.go
- identity_def.go
- identity_mutation.go
- models.go
- mutation.go
- nodes.go
- query.go
- role.go
- role_mutation.go
- role_user_mutation.go
- scalars.go
- schema.go
- session.go
- session_mutation.go
- user.go
- user_mutation.go
Click to show internal directories.
Click to hide internal directories.