Skip to main content

Module tokens

Module tokens 

Source
Expand description

Synapse admin API: registration-token endpoints.

Re-exportsยง

use std::time::Duration; ๐Ÿ”’
use ruma::MilliSecondsSinceUnixEpoch; ๐Ÿ”’
use ruma::UInt; ๐Ÿ”’
use ruma::uint; ๐Ÿ”’
use synapse_admin_api::registration_tokens::RegistrationToken; ๐Ÿ”’
use tuwunel_core::Result; ๐Ÿ”’
use tuwunel_core::utils::time::timepoint_from_epoch; ๐Ÿ”’
use tuwunel_service::registration_tokens::DatabaseTokenInfo; ๐Ÿ”’
use tuwunel_service::registration_tokens::TokenExpires; ๐Ÿ”’
use tuwunel_service::registration_tokens::TokenInfo; ๐Ÿ”’
pub(crate) use self::create::admin_create_token_route; ๐Ÿ”’
pub(crate) use self::delete::admin_delete_token_route; ๐Ÿ”’
pub(crate) use self::get::admin_get_token_route; ๐Ÿ”’
pub(crate) use self::list::admin_list_tokens_route; ๐Ÿ”’
pub(crate) use self::update::admin_update_token_route; ๐Ÿ”’

Modulesยง

create ๐Ÿ”’
delete ๐Ÿ”’
get ๐Ÿ”’
list ๐Ÿ”’
update ๐Ÿ”’

Functionsยง

database_token_response ๐Ÿ”’
Map a token and its stored metadata into the admin API wire shape. pending is always zero: tuwunel consumes uses in a single step with no two-phase registration model.
token_expires ๐Ÿ”’
token_response ๐Ÿ”’
Map a validated token into the admin API wire shape. Config-file tokens carry no usage state, so they read as unlimited, never expiring, and unused.