Skip to main content

openauth_plugins/
lib.rs

1//! Official OpenAuth plugin module surface.
2//!
3//! Plugin modules are ported against the Better Auth upstream reference where
4//! the behavior belongs on the server side, then shaped as idiomatic Rust APIs.
5
6pub mod access;
7pub mod additional_fields;
8pub mod admin;
9pub mod anonymous;
10pub mod api_key;
11pub mod bearer;
12pub mod captcha;
13pub mod custom_session;
14pub mod device_authorization;
15pub mod email_otp;
16pub mod generic_oauth;
17pub mod haveibeenpwned;
18pub mod jwt;
19pub mod last_login_method;
20pub mod magic_link;
21pub mod mcp;
22pub mod multi_session;
23pub mod oauth_proxy;
24pub mod one_tap;
25pub mod one_time_token;
26pub mod open_api;
27pub mod organization;
28pub mod phone_number;
29pub mod siwe;
30pub mod two_factor;
31pub mod username;
32
33pub const PLUGIN_IDS: &[&str] = &[
34    access::UPSTREAM_PLUGIN_ID,
35    additional_fields::UPSTREAM_PLUGIN_ID,
36    admin::UPSTREAM_PLUGIN_ID,
37    anonymous::UPSTREAM_PLUGIN_ID,
38    api_key::UPSTREAM_PLUGIN_ID,
39    bearer::UPSTREAM_PLUGIN_ID,
40    captcha::UPSTREAM_PLUGIN_ID,
41    custom_session::UPSTREAM_PLUGIN_ID,
42    device_authorization::UPSTREAM_PLUGIN_ID,
43    email_otp::UPSTREAM_PLUGIN_ID,
44    generic_oauth::UPSTREAM_PLUGIN_ID,
45    haveibeenpwned::UPSTREAM_PLUGIN_ID,
46    jwt::UPSTREAM_PLUGIN_ID,
47    last_login_method::UPSTREAM_PLUGIN_ID,
48    magic_link::UPSTREAM_PLUGIN_ID,
49    mcp::UPSTREAM_PLUGIN_ID,
50    multi_session::UPSTREAM_PLUGIN_ID,
51    oauth_proxy::UPSTREAM_PLUGIN_ID,
52    one_tap::UPSTREAM_PLUGIN_ID,
53    one_time_token::UPSTREAM_PLUGIN_ID,
54    open_api::UPSTREAM_PLUGIN_ID,
55    organization::UPSTREAM_PLUGIN_ID,
56    phone_number::UPSTREAM_PLUGIN_ID,
57    siwe::UPSTREAM_PLUGIN_ID,
58    two_factor::UPSTREAM_PLUGIN_ID,
59    username::UPSTREAM_PLUGIN_ID,
60];
61
62pub const VERSION: &str = env!("CARGO_PKG_VERSION");