Skip to main content

Module config

Module config 

Source

Structs§

BlossomConfig
CashuConfig
Config
NostrConfig
S3Config
S3-compatible storage configuration (works with AWS S3, Cloudflare R2, MinIO, etc.)
ServerConfig
StorageConfig
SyncConfig

Functions§

ensure_auth_cookie
Generate and save auth cookie if it doesn’t exist
ensure_keys
Ensure keys file exists, generating one if not present Returns (Keys, was_generated)
ensure_keys_string
Get nsec string, ensuring keys file exists (generate if needed) Returns (nsec_string, was_generated)
generate_auth_cookie
Generate new random auth cookie
generate_keys
Generate new keys and save to file
get_auth_cookie_path
Get the auth cookie path (~/.hashtree/auth.cookie)
get_config_path
Get the config file path (~/.hashtree/config.toml)
get_hashtree_dir
Get the hashtree directory (~/.hashtree)
get_keys_path
Get the keys file path (~/.hashtree/keys)
parse_npub
Parse npub to 32-byte pubkey
pubkey_bytes
Get 32-byte pubkey bytes from Keys.
read_auth_cookie
Read existing auth cookie
read_keys
Read existing keys