Better Auth plugin integrating Fayda (Ethiopian national digital ID) OAuth2 authentication. Current stable version is 0.0.14, released with monthly cadence. It provides client ID and private key configuration, automatic account linking via better-auth, and requires proper redirect URL setup. Key differentiator: bridges Ethiopian national ID system with the better-auth ecosystem, enabling domestic authentication flows. Requires better-auth ^1.3.4 as a peer dependency.
npm install faydaNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Configures better-auth with the Fayda plugin, sets up client-side OAuth, and triggers sign-in flow.
Configure your Fayda client's redirectURL to exactly your base URL plus `/api/auth/oauth2/callback/fayda`.
Implement a server-side redirect (e.g., SvelteKit endpoint) that forwards callbacks to the correct better-auth handler.
Use named import: import { fayda } from 'fayda' instead of import fayda from 'fayda'.Change to: import { fayda } from 'fayda'Set redirectURL to `<baseUrl>/api/auth/oauth2/callback/fayda` exactly.
Add account: { accountLinking: { enabled: true, trustedProviders: ['fayda'] } } to betterAuth config.