chatmail-control — API
AuditEvent
Заголовок раздела «AuditEvent»pub struct AuditEventpub async fn log_event(pub async fn latest(pool: &SqlitePool, limit: i64) -> AppResult<Vec<AuditEvent>>pub struct AdminSession
Заголовок раздела «Session»pub struct SessionLoginRateLimiter
Заголовок раздела «LoginRateLimiter»pub struct LoginRateLimiterLoginForm
Заголовок раздела «LoginForm»pub struct LoginFormCsrfForm
Заголовок раздела «CsrfForm»pub struct CsrfFormCurrentAdmin
Заголовок раздела «CurrentAdmin»pub struct CurrentAdminpub async fn require_admin(hash_password(password:
Заголовок раздела «hash_password(password:»pub fn hash_password(password: &str) -> AppResult<String>verify_password(password:
Заголовок раздела «verify_password(password:»pub fn verify_password(password: &str, hash: &str) -> AppResult<bool>pub async fn upsert_admin(pool: &SqlitePool, username: &str, password: &str) -> AppResult<()>pub async fn authenticate(pub async fn logout(validate_csrf(current:
Заголовок раздела «validate_csrf(current:»pub fn validate_csrf(current: &CurrentAdmin, token: &str) -> AppResult<()>pub struct BanCreateBan<‘a>
Заголовок раздела «CreateBan<‘a>»pub struct CreateBan<'a>SetBanActiveByValue<‘a>
Заголовок раздела «SetBanActiveByValue<‘a>»pub struct SetBanActiveByValue<'a>pub async fn list(pool: &SqlitePool, query: Option<&str>) -> AppResult<Vec<Ban>>pub async fn active_values(pool: &SqlitePool) -> AppResult<Vec<String>>pub async fn add(pub async fn set_active(pub async fn delete(pub async fn set_active_for_value(pub async fn ensure_active_address_ban(pub async fn sync_policy_files(pool: &SqlitePool, config: &Config) -> AppResult<()>render_ban_files(bans:
Заголовок раздела «render_ban_files(bans:»pub fn render_ban_files(bans: &[Ban]) -> (String, String, String)LogSource
Заголовок раздела «LogSource»pub struct LogSourceusers_list_command()
Заголовок раздела «users_list_command()»pub fn users_list_command() -> Vec<String>user_size_command(address:
Заголовок раздела «user_size_command(address:»pub fn user_size_command(address: &str) -> Vec<String>user_message_count_command(address:
Заголовок раздела «user_message_count_command(address:»pub fn user_message_count_command(address: &str) -> Vec<String>user_mailbox_create_command(address:
Заголовок раздела «user_mailbox_create_command(address:»pub fn user_mailbox_create_command(address: &str, mailbox: &str) -> Vec<String>user_metadata_command(address:
Заголовок раздела «user_metadata_command(address:»pub fn user_metadata_command(address: &str) -> Vec<String>user_delete_mailbox_command(address:
Заголовок раздела «user_delete_mailbox_command(address:»pub fn user_delete_mailbox_command(address: &str) -> Vec<String>user_kick_command(address:
Заголовок раздела «user_kick_command(address:»pub fn user_kick_command(address: &str) -> Vec<String>user_home_command(address:
Заголовок раздела «user_home_command(address:»pub fn user_home_command(address: &str) -> Vec<String>user_auth_test_command(address:
Заголовок раздела «user_auth_test_command(address:»pub fn user_auth_test_command(address: &str, password: &str) -> Vec<String>user_mailbox_list_command(address:
Заголовок раздела «user_mailbox_list_command(address:»pub fn user_mailbox_list_command(address: &str) -> Vec<String>user_mailbox_expunge_command(address:
Заголовок раздела «user_mailbox_expunge_command(address:»pub fn user_mailbox_expunge_command(address: &str, mailbox: &str) -> Vec<String>user_quota_recalc_command(address:
Заголовок раздела «user_quota_recalc_command(address:»pub fn user_quota_recalc_command(address: &str) -> Vec<String>user_force_resync_command(address:
Заголовок раздела «user_force_resync_command(address:»pub fn user_force_resync_command(address: &str) -> Vec<String>password_hash_command(password:
Заголовок раздела «password_hash_command(password:»pub fn password_hash_command(password: &str) -> Vec<String>bans_reload_commands()
Заголовок раздела «bans_reload_commands()»pub fn bans_reload_commands() -> Vec<Vec<String>>systemctl_command(action:
Заголовок раздела «systemctl_command(action:»pub fn systemctl_command(action: &str, unit: &str) -> Vec<String>log_source_by_name(name:
Заголовок раздела «log_source_by_name(name:»pub fn log_source_by_name(name: Option<&str>) -> LogSourcepub struct ConfigServerConfig
Заголовок раздела «ServerConfig»pub struct ServerConfigAuthConfig
Заголовок раздела «AuthConfig»pub struct AuthConfigBansConfig
Заголовок раздела «BansConfig»pub struct BansConfigSettingsConfig
Заголовок раздела «SettingsConfig»pub struct SettingsConfigInvitesConfig
Заголовок раздела «InvitesConfig»pub struct InvitesConfigHealthConfig
Заголовок раздела «HealthConfig»pub struct HealthConfigpub async fn connect(database_url: &str) -> AppResult<SqlitePool>AppError
Заголовок раздела «AppError»pub enum AppErrorHealthCheck
Заголовок раздела «HealthCheck»pub struct HealthCheckpub async fn run_health_checks(shell: &Shell, config: &Config) -> Vec<HealthCheck>pub struct Invitegenerate_token()
Заголовок раздела «generate_token()»pub fn generate_token() -> Stringpub async fn list(pool: &SqlitePool) -> AppResult<Vec<Invite>>pub async fn create(pub async fn set_active(pub async fn export_active_tokens(pool: &SqlitePool, config: &Config) -> AppResult<()>LogLine
Заголовок раздела «LogLine»pub struct LogLinepub async fn read_logs(pub async fn read_journal_unit(pub async fn read_journal_identifiers(AppState
Заголовок раздела «AppState»pub struct AppStatePolicySyncResult
Заголовок раздела «PolicySyncResult»pub struct PolicySyncResultpub async fn ensure_ban_policy(shell: &Shell, config: &Config) -> AppResult<PolicySyncResult>pub async fn request_id_middleware(mut request: Request<Body>, next: Next) -> Responserouter()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<crate::AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>router()
Заголовок раздела «router()»pub fn router() -> Router<AppState>ServiceStatus
Заголовок раздела «ServiceStatus»pub struct ServiceStatusDashboardStats
Заголовок раздела «DashboardStats»pub struct DashboardStatsServiceActionResult
Заголовок раздела «ServiceActionResult»pub struct ServiceActionResultpub async fn collect_dashboard_stats(pub async fn run_service_action(SettingRow
Заголовок раздела «SettingRow»pub struct SettingRowRegistrationSettings
Заголовок раздела «RegistrationSettings»pub struct RegistrationSettingspub async fn load(pool: &SqlitePool) -> AppResult<RegistrationSettings>pub async fn save(pub async fn generate_policy_file(CommandOutput
Заголовок раздела «CommandOutput»pub struct CommandOutputpub struct Shellsubstitute_template_args(
Заголовок раздела «substitute_template_args(»pub fn substitute_template_args(command_result_details(output:
Заголовок раздела «command_result_details(output:»pub fn command_result_details(output: &CommandOutput) -> Valuepub async fn write_text_file(path: &str, content: &str) -> AppResult<()>pub async fn run_reload_commands(UserMailbox
Заголовок раздела «UserMailbox»pub struct UserMailboxManagedUser
Заголовок раздела «ManagedUser»pub struct ManagedUserpub async fn create_user_account(pub async fn list_users(shell: &Shell, blocked_values: &[String]) -> Vec<UserMailbox>pub async fn load_managed_user(shell: &Shell, address: &str) -> AppResult<ManagedUser>pub async fn delete_mailbox(shell: &Shell, address: &str) -> AppResult<CommandOutput>pub async fn disable_login(shell: &Shell, address: &str) -> AppResult<String>pub async fn enable_login(shell: &Shell, address: &str) -> AppResult<String>pub async fn delete_account_lifecycle(shell: &Shell, address: &str) -> AppResult<String>pub async fn expunge_mailbox(pub async fn quota_recalc(shell: &Shell, address: &str) -> AppResult<CommandOutput>pub async fn force_resync(shell: &Shell, address: &str) -> AppResult<CommandOutput>