Skip to main content

Module send

Module send 

Source
Expand description

bw send command implementation.

Dispatches the subcommands declared on SendArgs / SendCommands in super to the underlying bitwarden_send::SendClient methods. The arg parsing surface is intentionally defined in super so the legacy-CLI shape (which is part of the user contract) stays close to the rest of the tools family.

StructsΒ§

CreateInputs πŸ”’
EditOverrides πŸ”’
SendArgs
SendCreateArgs
SendDeleteArgs
SendEditArgs
SendFileTemplate πŸ”’
SendFileTemplateBody πŸ”’
SendGetArgs
SendListArgs
SendReceiveArgs
SendRemovePasswordArgs
SendTemplateArgs
SendTextTemplate πŸ”’
SendTextTemplateBody πŸ”’

EnumsΒ§

SendCommands

ConstantsΒ§

DELETE_IN_DAYS_ALLOWED πŸ”’
Allowed values for --deleteInDays, matching the legacy CLI’s enumerated set. Kept as strings so PossibleValuesParser can surface them in --help output.

FunctionsΒ§

build_access_url πŸ”’
Build the shareable Send access URL from a decrypted bitwarden_send::SendView.
build_auth πŸ”’
build_auth_for_edit πŸ”’
Build the auth field for a SendEditRequest.
build_create_request πŸ”’
build_edit_request πŸ”’
compute_deletion_date πŸ”’
create_shortcut πŸ”’
delete_in_days_parser πŸ”’
Clap value parser for --deleteInDays. Restricts input to the legacy-CLI allowed set (also surfaced in --help) and maps it back to the u64 field type.
finalize_emails πŸ”’
get_send πŸ”’
list_sends πŸ”’
parse_emails πŸ”’
Parse the --emails argument into a list of email addresses.
render_template πŸ”’
rewrite_api_host_to_vault πŸ”’
Rewrite a leading api. host label to vault. in a scheme://host[/path] URL, e.g. https://api.bitwarden.com -> https://vault.bitwarden.com. Returns None when the URL has no scheme or the host does not start with the api. label (so apiary.example.com is not rewritten).
run_create πŸ”’
to_url_b64 πŸ”’
Convert standard base64 to URL-safe base64 without padding.
web_vault_from_api_url πŸ”’
Derive the web-vault base from an API URL when no web-vault/server URL is configured (the bw login --server and cloud paths). Pure so it can be unit-tested without a live client.
web_vault_url πŸ”’
Resolve the web-vault base URL that /#/send/<access_id>/<url_b64_key> is appended to.