Skip to content

Accounts

[account]
name = "personal"
maildir = "personal"       # reserved; the store folder is
                           # the account name for now
archive = "archive"        # where `a` files mail, as the
                           # folder appears in the sidebar;
                           # this is also the default

[folder_names]             # sidebar aliases; typed folder
                           # names accept either side
"inbox/accounts" = "accounts"

[imap]
host = "imap.example.com"
port = 993                 # optional, defaults to 993
user = "you@example.com"
password_cmd = "pass show mail/personal"

[smtp]
host = "smtp.example.com"
port = 587                 # optional
user = "you@example.com"   # optional
password_cmd = "..."       # optional

[[identity]]
address = "you@example.com"
name = "Your Name"         # optional display name
signature = "personal"     # optional; a file in signatures/
match = [
    "you@example.com",     # literal
    "you+*@example.com",   # plus-addressing
    "*@you.example.com",   # catch-all domain
]
pgp_sign = false           # sign mail from this identity
# optional; the full fingerprint (gpg --fingerprint shows it),
# otherwise the key is picked by the identity address
pgp_key = "8F0EA48BF8BE9D3B9E1B2B9C6E5F0D3A1C2B4D5E"

[[rules]]
match_list = "~lists/somewhere"   # or match_sender
move_to = "lists/somewhere"       # or tag

[oauth]
provider = "google"        # google | microsoft
client_id = "..."          # optional

[graph]
send = false               # send via Microsoft Graph rather
                           # than SMTP

Identity match patterns allow one *, only in the local part; antiphon doctor validates every pattern and names any bad one. On reply, the most specific match wins (literal, then plus-pattern, then catch-all) and the From is the delivered address verbatim.

Folder aliases

[folder_names] gives folders friendlier sidebar names; the alias also works wherever a folder name is typed (:move, for one). The left side is the folder path as the store knows it: lowercase, /-separated.

[folder_names]
"inbox/accounts" = "accounts"
"lists/rust-users" = "rust"

The archive and trash folders

a files mail to the account's archive folder and d moves it to trash, unless the account names others:

[account]
archive = "archive"
trash = "trash"

Both are folder paths as the sidebar shows them. Deleting inside the trash folder is the only permanent delete, and it asks first.

OAuth accounts (Microsoft 365, Google)

The setup wizard and the settings form cover password and app-password accounts. An OAuth account (Microsoft 365, Google Workspace) is set up in files instead: add the [oauth] table shown below to the account file, then run antiphon oauth login <account> to complete the browser or device-code flow. The settings view can still edit such an account's other fields afterwards.