[{"data":1,"prerenderedAt":776},["ShallowReactive",2],{"navigation_docs":3,"-getting-started-introduction":265,"-getting-started-introduction-surround":773},[4,35,49,89,117,164,193,235,253,257,261],{"title":5,"icon":6,"path":7,"stem":8,"children":9,"page":6},"Getting Started",false,"/getting-started","1.getting-started",[10,15,20,25,30],{"title":11,"path":12,"stem":13,"icon":14},"Introduction","/getting-started/introduction","1.getting-started/2.introduction","i-lucide-house",{"title":16,"path":17,"stem":18,"icon":19},"Installation","/getting-started/installation","1.getting-started/3.installation","i-lucide-download",{"title":21,"path":22,"stem":23,"icon":24},"Quick Start","/getting-started/quick-start","1.getting-started/4.quick-start","i-lucide-rocket",{"title":26,"path":27,"stem":28,"icon":29},"Configuration","/getting-started/configuration","1.getting-started/5.configuration","i-lucide-sliders-horizontal",{"title":31,"path":32,"stem":33,"icon":34},"First Auth","/getting-started/first-auth","1.getting-started/6.first-auth","i-lucide-key-round",{"title":36,"path":37,"stem":38,"children":39,"page":6},"Migration","/migration","10.migration",[40,45],{"title":41,"path":42,"stem":43,"icon":44},"Migration depuis Firebase Auth","/migration/from-firebase","10.migration/1.from-firebase","i-lucide-arrow-right-left",{"title":46,"path":47,"stem":48,"icon":44},"Migration depuis Supabase Auth","/migration/from-supabase","10.migration/2.from-supabase",{"title":50,"path":51,"stem":52,"children":53,"page":6},"Core Concepts","/core-concepts","2.core-concepts",[54,59,64,69,74,79,84],{"title":55,"path":56,"stem":57,"icon":58},"Architecture","/core-concepts/architecture","2.core-concepts/1.architecture","i-lucide-layers",{"title":60,"path":61,"stem":62,"icon":63},"Providers","/core-concepts/providers","2.core-concepts/2.providers","i-lucide-plug",{"title":65,"path":66,"stem":67,"icon":68},"Sessions","/core-concepts/sessions","2.core-concepts/3.sessions","i-lucide-timer",{"title":70,"path":71,"stem":72,"icon":73},"Storage","/core-concepts/storage","2.core-concepts/4.storage","i-lucide-database",{"title":75,"path":76,"stem":77,"icon":78},"Reactivity","/core-concepts/reactivity","2.core-concepts/5.reactivity","i-lucide-activity",{"title":80,"path":81,"stem":82,"icon":83},"Callbacks","/core-concepts/callbacks","2.core-concepts/6.callbacks","i-lucide-shield-check",{"title":85,"path":86,"stem":87,"icon":88},"Events","/core-concepts/events","2.core-concepts/7.events","i-lucide-radio",{"title":60,"path":90,"stem":91,"children":92,"page":6},"/providers","3.providers",[93,97,101,105,109,113],{"title":94,"path":95,"stem":96},"Credentials Provider","/providers/credentials","3.providers/1.credentials",{"title":98,"path":99,"stem":100},"OAuth2 Provider","/providers/oauth2","3.providers/2.oauth2",{"title":102,"path":103,"stem":104},"Google Provider","/providers/google","3.providers/3.google",{"title":106,"path":107,"stem":108},"GitHub Provider","/providers/github","3.providers/4.github",{"title":110,"path":111,"stem":112},"Apple Provider","/providers/apple","3.providers/5.apple",{"title":114,"path":115,"stem":116},"Proxy OAuth Provider","/providers/proxy-oauth","3.providers/6.proxy-oauth",{"title":118,"path":119,"stem":120,"children":121,"page":6},"Guides","/guides","4.guides",[122,126,131,136,141,146,151,155,159],{"title":123,"path":124,"stem":125},"Email / Password Auth","/guides/email-auth","4.guides/1.email-auth",{"title":127,"path":128,"stem":129,"icon":130},"Custom OAuth2 Flow","/guides/oauth2-flow","4.guides/2.oauth2-flow","i-lucide-workflow",{"title":132,"path":133,"stem":134,"icon":135},"Deep Links & OAuth2 Callbacks","/guides/deep-links","4.guides/3.deep-links","i-lucide-link",{"title":137,"path":138,"stem":139,"icon":140},"Token Refresh","/guides/token-refresh","4.guides/4.token-refresh","i-lucide-refresh-cw",{"title":142,"path":143,"stem":144,"icon":145},"Multi-Account","/guides/multi-account","4.guides/5.multi-account","i-lucide-users",{"title":147,"path":148,"stem":149,"icon":150},"Route Protection","/guides/route-protection","4.guides/6.route-protection","i-lucide-lock",{"title":152,"path":153,"stem":154,"icon":63},"Custom Provider","/guides/custom-provider","4.guides/7.custom-provider",{"title":156,"path":157,"stem":158,"icon":73},"Custom Storage","/guides/custom-storage","4.guides/8.custom-storage",{"title":160,"path":161,"stem":162,"icon":163},"Testing","/guides/testing","4.guides/9.testing","i-lucide-flask-conical",{"title":165,"path":166,"stem":167,"children":168,"page":6},"Flutter","/flutter","5.flutter",[169,173,178,183,188],{"title":170,"path":171,"stem":172},"Flutter Setup","/flutter/setup","5.flutter/1.setup",{"title":174,"path":175,"stem":176,"icon":177},"Secure Storage","/flutter/secure-storage","5.flutter/2.secure-storage","i-lucide-vault",{"title":179,"path":180,"stem":181,"icon":182},"Widgets","/flutter/widgets","5.flutter/3.widgets","i-lucide-layout",{"title":184,"path":185,"stem":186,"icon":187},"Router Guard","/flutter/router-guard","5.flutter/4.router-guard","i-lucide-signpost",{"title":189,"path":190,"stem":191,"icon":192},"App Binding","/flutter/app-binding","5.flutter/5.app-binding","i-lucide-cpu",{"title":194,"path":195,"stem":196,"children":197,"page":6},"API Reference","/api-reference","6.api-reference",[198,202,206,211,216,221,225,230],{"title":199,"path":200,"stem":201},"AuthyraClient","/api-reference/authyra-client","6.api-reference/1.authyra-client",{"title":203,"path":204,"stem":205},"AuthyraInstance","/api-reference/authyra-instance","6.api-reference/2.authyra-instance",{"title":207,"path":208,"stem":209,"icon":210},"AccountManager","/api-reference/account-manager","6.api-reference/3.account-manager","i-lucide-users-round",{"title":212,"path":213,"stem":214,"icon":215},"AuthProvider","/api-reference/auth-provider","6.api-reference/4.auth-provider","i-lucide-plug-zap",{"title":217,"path":218,"stem":219,"icon":220},"AuthStorage","/api-reference/auth-storage","6.api-reference/5.auth-storage","i-lucide-hard-drive",{"title":222,"path":223,"stem":224,"icon":68},"AuthSession","/api-reference/auth-session","6.api-reference/6.auth-session",{"title":226,"path":227,"stem":228,"icon":229},"AuthState","/api-reference/auth-state","6.api-reference/7.auth-state","i-lucide-toggle-right",{"title":231,"path":232,"stem":233,"icon":234},"Exceptions","/api-reference/auth-exceptions","6.api-reference/8.auth-exceptions","i-lucide-triangle-alert",{"title":236,"path":237,"stem":238,"children":239,"page":6},"Examples","/examples","7.examples",[240,244,249],{"title":241,"path":242,"stem":243},"Flutter App Example","/examples/flutter-app","7.examples/1.flutter-app",{"title":245,"path":246,"stem":247,"icon":248},"Dart Backend","/examples/dart-backend","7.examples/2.dart-backend","i-lucide-server",{"title":250,"path":251,"stem":252,"icon":163},"Testing Setup","/examples/testing-setup","7.examples/3.testing-setup",{"title":254,"path":255,"stem":256},"Troubleshooting","/troubleshooting","8.troubleshooting",{"title":258,"path":259,"stem":260},"FAQ","/faq","9.faq",{"title":262,"path":263,"stem":264},"Changelog","/changelog","changelog",{"id":266,"title":11,"body":267,"description":764,"extension":765,"links":766,"meta":767,"navigation":768,"path":12,"seo":769,"stem":13,"__hash__":772},"docs/1.getting-started/2.introduction.md",{"type":268,"value":269,"toc":752},"minimark",[270,275,279,282,285,289,292,350,363,365,369,374,391,395,403,420,424,442,446,451,519,529,531,535,718,720,724,748],[271,272,274],"h2",{"id":273},"what-is-authyra","What is Authyra?",[276,277,278],"p",{},"Authyra is an authentication framework for Dart and Flutter. It manages the full auth lifecycle — sign-in, session persistence, token refresh, and multi-account state — without coupling to a backend, a navigation framework, or a UI library.",[276,280,281],{},"Unlike a BaaS SDK (Firebase Auth, Supabase Auth), Authyra doesn't talk to any external service. It orchestrates providers you configure and delegates storage to a backend you own.",[283,284],"hr",{},[271,286,288],{"id":287},"two-packages","Two packages",[276,290,291],{},"Authyra ships as two complementary packages:",[293,294,295,317],"card-group",{},[296,297,301,302,305,306,305,308,305,311,305,314,316],"card",{"icon":298,"title":299,"to":300},"i-lucide-box","authyra","https://pub.dev/packages/authyra","Pure Dart. Zero Flutter dependency. Use on mobile, web, desktop, Dart backend (Shelf, Dart Frog), or CLI. Contains ",[303,304,199],"code",{},", ",[303,307,203],{},[303,309,310],{},"CredentialsProvider",[303,312,313],{},"SessionManager",[303,315,207],{},", and all interfaces.",[296,318,322,323,325,326,305,329,305,332,305,335,305,338,341,342,345,346,349],{"icon":319,"title":320,"to":321},"i-lucide-smartphone","authyra_flutter","https://pub.dev/packages/authyra_flutter","Flutter layer. Re-exports everything from ",[303,324,299],{},". Adds OAuth2 providers (",[303,327,328],{},"GoogleProvider",[303,330,331],{},"GitHubOAuth2Provider",[303,333,334],{},"AppleProvider",[303,336,337],{},"OAuth2Provider",[303,339,340],{},"ProxyOAuthProvider","), ",[303,343,344],{},"SecureAuthStorage",", and ",[303,347,348],{},"OAuth2CallbackHandler",".",[276,351,352,356,357,359,360,362],{},[353,354,355],"strong",{},"Rule of thumb",": depend on ",[303,358,320],{}," for Flutter apps. Depend on ",[303,361,299],{}," for Dart backends, unit tests, or any non-Flutter Dart target.",[283,364],{},[271,366,368],{"id":367},"core-principles","Core principles",[370,371,373],"h3",{"id":372},"_1-pure-logic-no-framework-coupling","1. Pure logic, no framework coupling",[276,375,376,378,379,382,383,386,387,390],{},[303,377,199],{}," is a plain Dart class — no ",[303,380,381],{},"BuildContext",", no ",[303,384,385],{},"ChangeNotifier",", no platform channel. The same code runs in a Flutter app, in a ",[303,388,389],{},"dart test"," suite, and in a Dart Frog handler.",[370,392,394],{"id":393},"_2-everything-is-an-interface","2. Everything is an interface",[276,396,397,399,400,402],{},[303,398,212],{}," and ",[303,401,217],{}," are abstract classes you implement:",[404,405,406,410,417],"ul",{},[407,408,409],"li",{},"Any strategy — credentials, OAuth2, SAML, magic link, phone OTP — plugs in through the same interface.",[407,411,412,413,416],{},"Any storage backend — ",[303,414,415],{},"flutter_secure_storage",", Redis, SQLite, an in-memory map — is swappable.",[407,418,419],{},"Tests replace providers and storage with three-line classes. No mocking framework needed.",[370,421,423],{"id":422},"_3-reactive-by-default","3. Reactive by default",[276,425,426,427,430,431,434,435,437,438,441],{},"Every state change emits on ",[303,428,429],{},"authStateChanges: Stream\u003CAuthState>",". Wire it to ",[303,432,433],{},"StreamBuilder",", Riverpod, Bloc, or a GoRouter redirect. ",[303,436,226],{}," uses ",[303,439,440],{},"Equatable",", so identical consecutive states are deduplicated — no spurious rebuilds.",[370,443,445],{"id":444},"_4-synchronous-state-when-you-need-it","4. Synchronous state when you need it",[276,447,448,450],{},[303,449,203],{}," (the singleton wrapper) maintains a synchronous cache:",[452,453,458],"pre",{"className":454,"code":455,"language":456,"meta":457,"style":457},"language-dart shiki shiki-themes material-theme-lighter material-theme material-theme-palenight","Authyra.instance.currentUser        // AuthUser?   — no await\nAuthyra.instance.isAuthenticated    // bool        — no await\nAuthyra.instance.currentState       // AuthState   — no await\n","dart","",[303,459,460,485,502],{"__ignoreMap":457},[461,462,465,469,472,476,478,481],"span",{"class":463,"line":464},"line",1,[461,466,468],{"class":467},"sBMFI","Authyra",[461,470,349],{"class":471},"sMK4o",[461,473,475],{"class":474},"sTEyZ","instance",[461,477,349],{"class":471},[461,479,480],{"class":474},"currentUser        ",[461,482,484],{"class":483},"sHwdD","// AuthUser?   — no await\n",[461,486,488,490,492,494,496,499],{"class":463,"line":487},2,[461,489,468],{"class":467},[461,491,349],{"class":471},[461,493,475],{"class":474},[461,495,349],{"class":471},[461,497,498],{"class":474},"isAuthenticated    ",[461,500,501],{"class":483},"// bool        — no await\n",[461,503,505,507,509,511,513,516],{"class":463,"line":504},3,[461,506,468],{"class":467},[461,508,349],{"class":471},[461,510,475],{"class":474},[461,512,349],{"class":471},[461,514,515],{"class":474},"currentState       ",[461,517,518],{"class":483},"// AuthState   — no await\n",[276,520,521,522,525,526,349],{},"Safe to call in ",[303,523,524],{},"build()"," methods without ",[303,527,528],{},"FutureBuilder",[283,530],{},[271,532,534],{"id":533},"package-split-what-lives-where","Package split — what lives where",[536,537,538,556],"table",{},[539,540,541],"thead",{},[542,543,544,548,552],"tr",{},[545,546,547],"th",{},"Component",[545,549,550],{},[303,551,299],{},[545,553,554],{},[303,555,320],{},[557,558,559,572,585,596,606,616,626,636,647,658,668,678,688,698,708],"tbody",{},[542,560,561,566,569],{},[562,563,564],"td",{},[303,565,199],{},[562,567,568],{},"✓",[562,570,571],{},"re-exported",[542,573,574,581,583],{},[562,575,576,578,579],{},[303,577,203],{}," / ",[303,580,468],{},[562,582,568],{},[562,584,571],{},[542,586,587,592,594],{},[562,588,589,591],{},[303,590,212],{}," interface",[562,593,568],{},[562,595,571],{},[542,597,598,602,604],{},[562,599,600,591],{},[303,601,217],{},[562,603,568],{},[562,605,571],{},[542,607,608,612,614],{},[562,609,610],{},[303,611,310],{},[562,613,568],{},[562,615,571],{},[542,617,618,622,624],{},[562,619,620],{},[303,621,313],{},[562,623,568],{},[562,625,571],{},[542,627,628,632,634],{},[562,629,630],{},[303,631,207],{},[562,633,568],{},[562,635,571],{},[542,637,638,643,645],{},[562,639,640],{},[303,641,642],{},"InMemoryStorage",[562,644,568],{},[562,646,571],{},[542,648,649,653,656],{},[562,650,651],{},[303,652,337],{},[562,654,655],{},"—",[562,657,568],{},[542,659,660,664,666],{},[562,661,662],{},[303,663,328],{},[562,665,655],{},[562,667,568],{},[542,669,670,674,676],{},[562,671,672],{},[303,673,331],{},[562,675,655],{},[562,677,568],{},[542,679,680,684,686],{},[562,681,682],{},[303,683,334],{},[562,685,655],{},[562,687,568],{},[542,689,690,694,696],{},[562,691,692],{},[303,693,340],{},[562,695,655],{},[562,697,568],{},[542,699,700,704,706],{},[562,701,702],{},[303,703,344],{},[562,705,655],{},[562,707,568],{},[542,709,710,714,716],{},[562,711,712],{},[303,713,348],{},[562,715,655],{},[562,717,568],{},[283,719],{},[271,721,723],{"id":722},"next-steps","Next steps",[404,725,726,733,739],{},[407,727,728,732],{},[729,730,731],"a",{"href":17},"Installation →"," — add the right package for your project",[407,734,735,738],{},[729,736,737],{"href":22},"Quick Start →"," — working sign-in in under 5 minutes",[407,740,741,744,745,747],{},[729,742,743],{"href":56},"Architecture →"," — how ",[303,746,199],{},", sessions, and providers fit together",[749,750,751],"style",{},"html pre.shiki code .sBMFI, html code.shiki .sBMFI{--shiki-light:#E2931D;--shiki-default:#FFCB6B;--shiki-dark:#FFCB6B}html pre.shiki code .sMK4o, html code.shiki .sMK4o{--shiki-light:#39ADB5;--shiki-default:#89DDFF;--shiki-dark:#89DDFF}html pre.shiki code .sTEyZ, html code.shiki .sTEyZ{--shiki-light:#90A4AE;--shiki-default:#EEFFFF;--shiki-dark:#BABED8}html pre.shiki code .sHwdD, html code.shiki .sHwdD{--shiki-light:#90A4AE;--shiki-light-font-style:italic;--shiki-default:#546E7A;--shiki-default-font-style:italic;--shiki-dark:#676E95;--shiki-dark-font-style:italic}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":457,"searchDepth":487,"depth":487,"links":753},[754,755,756,762,763],{"id":273,"depth":487,"text":274},{"id":287,"depth":487,"text":288},{"id":367,"depth":487,"text":368,"children":757},[758,759,760,761],{"id":372,"depth":504,"text":373},{"id":393,"depth":504,"text":394},{"id":422,"depth":504,"text":423},{"id":444,"depth":504,"text":445},{"id":533,"depth":487,"text":534},{"id":722,"depth":487,"text":723},"What Authyra is, how it's structured, and when to use each package.","md",null,{},{"icon":14},{"title":770,"description":771},"Introduction | Authyra","Authyra is a modular, interface-driven authentication framework for Dart and Flutter. Learn the two-package design and core principles.","HT960tknFiepd2u8tJHVqtm9e8mJSPsPQW6xCJx-qLc",[766,774],{"title":16,"path":17,"stem":18,"description":775,"icon":19,"children":-1},"Add Authyra to your Dart or Flutter project.",1782700506039]