Kernel API, reference: Auth
Kernel API, reference: BaseAuth
AuthModel is the authenticator used in NocoBase applications (Authenticator, reference: AuthManager - setStorer and Auth - constructor) data model, providing some methods for interacting with the user data collection. In addition, methods provided by Sequelize Model can also be used.
findUser(uuid: string): UserModel - Query user by uuid.
uuid - User unique identifier from the current authentication typenewUser(uuid: string, userValues?: any): UserModel - Create a new user, bind the user to the current authenticator through uuid.
uuid - User unique identifier from the current authentication typeuserValues - Optional. Other user information. When not passed, uuid will be used as the user's nickname.findOrCreateUser(uuid: string, userValues?: any): UserModel - Find or create a new user, the creation rule is the same as above.
uuid - User unique identifier from the current authentication typeuserValues - Optional. Other user information.plugin.registerType()Register the client of the authentication type.
registerType(authType: string, options: AuthOptions)SignInForm - Sign in formSignInButton - Sign in (third-party) button, can be used as an alternative to the sign-in formSignUpForm - Sign up formAdminSettingsForm - Admin configuration formThe frontend routes for registering the auth plugin are as follows:
Auth Layout
auth-AuthLayoutSignIn Page
auth.signin/signinSignInPageSignUp Page
auth.signup/signupSignUpPage