ruma-client-api 0.23.1

Types for the endpoints in the Matrix client-server API.
Documentation
//! Endpoints for user session management.

use ruma_common::serde::StringEnum;

use crate::PrivOwnedStr;

pub mod get_login_token;
pub mod get_login_types;
pub mod login;
pub mod login_fallback;
pub mod logout;
pub mod logout_all;
pub mod refresh_token;
pub mod sso_login;
pub mod sso_login_with_provider;

/// Possible actions that a user wishes to take at the SSO redirect endpoints.
#[doc = include_str!(concat!(env!("CARGO_MANIFEST_DIR"), "/src/doc/string_enum.md"))]
#[derive(Clone, StringEnum)]
#[ruma_enum(rename_all = "lowercase")]
#[non_exhaustive]
pub enum SsoRedirectAction {
    /// The SSO redirect is for the purpose of signing an existing user in.
    Login,

    /// The SSO redirect is for the purpose of registering a new user account.
    Register,

    #[doc(hidden)]
    _Custom(PrivOwnedStr),
}