1import authgear from "@authgear/web";2 3const login = async () => {4 await authgear.startAuthentication({5 redirectURI: "https://www.myapps.com/auth-redirect"6 })7} 1import authgear from "@authgear/web";2 3const login = async () => {4 await authgear.startAuthentication({5 redirectURI: "https://www.myapps.com/auth-redirect"6 })7} 1import authgear from "@authgear/web";2 3startLogin(): void {4 authgear.startAuthentication({5 redirectURI: 'http://localhost:4000/auth-redirect'6 })7} 1import authgear from "@authgear/react-native";2 3const authenticate = useCallback(async () => {4 try {5 authgear.authenticate({6 redirectURI: 'com.authgear.example.rn://host/path',7 });8 } catch (error) {9 // Login failed10 }11}, []); 1import 'package:flutter_authgear/flutter_authgear.dart';2 3late Authgear _authgear;4UserInfo? _userInfo;5 6Future<void> _onPressedAuthenticate() async {7 try {8 final userInfo = await _authgear.authenticate(redirectURI: "com.example.authgeardemo.flutter://host/path");9 setState(() {10 _userInfo = userInfo;11 });12 } catch (e) {13 // Login failed14 } finally {15 // Finally16 }17} 1authgear.authenticate(redirectURI: "com.example.authgear://host/path", handler: { result in2 switch result {3 case let .success(userInfo):4 // login successfully5 loginState = authgear.sessionState6 userId = userInfo.sub7 case let .failure(error):8 if let authgearError = error as? AuthgearError, case .cancel = authgearError {9 // user cancel10 } else {11 // Something went wrong12 }13 }14}) 1fun startLogin() {2 val options = AuthenticateOptions("com.example.authgear://host/path")3 authgear.authenticate(options, object : OnAuthenticateListener {4 override fun onAuthenticated(userInfo: UserInfo) {5 // Login successfully6 }7 override fun onAuthenticationFailed(throwable: Throwable) {8 // Login failed9 }10 })11} 可以!您可使用 Authgear Cloud 免費方案探索功能。雖有應用程式與專案成員數等限制,並保留 Authgear 品牌,但核心功能皆可測試。
內含 2 年持續更新。可透過指令輕鬆更新;Authgear ONCE 會連線檢查更新,由您決定何時下載與安裝。
提供 Discord 支援;基本問題也歡迎來信:once@authgear.com
我們提供 Import API,可將使用者從既有系統匯入 Authgear ONCE。可從 Auth0、Okta、PingIdentity 等遷移。詳見 文件。
搭配完整 SDK 與文件,多數開發者可在 10 分鐘內完成 Authgear ONCE 導入。
透過自架託管取得完整資料自主權,您可完全掌控客戶身份資料的存放、處理與保護方式,讓 GDPR 合規更直接。