Everything in Bichon is organized around accounts. This page walks through creating and configuring them; see Accounts for what each account type stores and Archive Filters for content rules.
Creating an account requires the account:create permission.
Choose the account type
On Accounts → New Account:
| Type | Use it for |
|---|---|
| IMAP | Archiving a live mailbox from a remote IMAP server |
Local account (NoSync) | Imports (EML/MBOX/PST) and SMTP delivery |
| View | A read-only, filter-scoped window onto other accounts (Pro/Enterprise) |
A View is covered in Accounts → View; the rest of this page is about IMAP and local accounts.
Step 1 — Email address and discovery
Enter the email address first. Bichon attempts automatic discovery from the domain: IMAP host, port, encryption, and a matching OAuth2 provider preset where one exists (Gmail, Outlook/Microsoft 365, Yahoo). Discovery is best-effort; every field can be overridden manually.
The address cannot be changed after the account is created.
Step 2 — IMAP server and authentication
| Field | Notes |
|---|---|
host / port | IMAP server; discovered or entered manually |
encryption | tls (implicit), starttls, or none |
auth_type | Password (PLAIN/LOGIN) or OAuth2 (SASL XOAUTH2) |
password | Required for password auth; encrypted at rest |
use_proxy | Optional proxy for this account's IMAP connections |
Self-signed certificates can be accepted per account when the server uses one.
OAuth2 accounts
OAuth2 providers are configured before the account, on the OAuth2 page (/oauth2) or via /api/v1/oauth2:
| Field | Meaning |
|---|---|
client_id / client_secret | Credentials from Google, Microsoft, Yahoo, or another provider |
client_type | Confidential (has a secret) or Public (PKCE, no secret) |
auth_url / token_url | Provider endpoints |
redirect_uri | Must exactly match the callback registered with the provider |
scopes | Provider-specific IMAP scopes (e.g. https://outlook.office.com/IMAP.AccessAsUser.All, offline_access) |
extra_params | Optional provider parameters such as access_type or prompt |
use_proxy | Route the authorization/token exchange through a proxy |
After saving the provider, create the IMAP account with auth_type: OAuth2, choose the provider, and complete the authorization flow. Tokens are stored encrypted and refreshed automatically.
Proxies
Create reusable HTTP or SOCKS5 proxies under Settings → Proxy (/settings/proxy), test them there, then select one per account or per OAuth2 provider. A proxy only affects outbound IMAP/OAuth traffic; it does not proxy the WebUI or REST API.
Step 3 — Sync schedule
Choose one of two mutually exclusive modes:
- Fixed interval — minutes between syncs (
download_interval_min). - Cron schedule — six-field cron
sec min hour day month dow, evaluated in the server's local timezone. When set, it overrides the interval.
At least one of the two is required for an IMAP account. To stop automatic syncing, disable the account rather than setting an empty schedule.
Step 4 — Download scope
| Setting | Meaning |
|---|---|
| Download All Emails | Fetch from the first message to the latest |
| Date Since | Only messages on/after a date (maps to IMAP SINCE) |
| Date Before | Only messages before a relative cut-off |
| Choose Mailboxes | Explicit folder list; only selected folders are fetched |
| Auto-download new mailboxes | Fetch folders that appear on the server later |
| Batch size | Messages per IMAP request, 10–200 |
| Max email size | Skip messages larger than this (default 100 MB) |
| IMAP quota | Optional quota guard; bytes and window must be set together |
Date Since and Date Before are mutually exclusive.
Step 5 — General and lifecycle
- Account name / login name — display name and IMAP username (defaults to the email address; custom values supported).
- Enabled — a disabled account keeps its data but does not sync or import.
- PGP key — optional key associated with the account.
- Retention window (days) — permanently purge messages older than N days. Empty or
0keeps everything. Age is the older of theDateheader and the server receive time; a legal hold suspends retention. See Storage & Backup → Account Retention. - Minimum retention / deletion lock (days) — Enterprise. Messages younger than this window cannot be deleted by any path, and the retention sweep keeps them. Only
system:rootcan set or clear it. See Minimum retention. - Source mailbox cleanup — move archived mail out of the source mailbox into
bichon_auto_created_trash. See Source Mailbox Cleanup. - Archive filtering — only matching messages are archived. See Archive Filters.
- Attachment extraction — Pro: only matching attachments are text-extracted for full-text search. See Attachment Search.
- Override From headers — optional ordered header names whose first valid mailbox replaces the stored
fromaddress.
Step 6 — Save, download, and gap-fill
Saving creates the account. Start the initial download from the account page; progress, errors, and per-folder state are shown there. Enable Check new emails and automatically backfill older missing emails to run gap-fill after a sync: it compares every remote folder's UIDs with the local archive and re-downloads anything missing.
Per-account sync state is also exposed as metrics — see Monitoring & Metrics.
Local (NoSync) accounts
A local account is the only valid target for imports and SMTP delivery. Create one with no IMAP configuration; then:
- import EML/MBOX/PST via the WebUI or
bichon-cli— see Import & Export; - deliver mail over SMTP — see Embedded SMTP Receiver;
- become the journal archive automatically when SMTP journaling is configured.
Editing and deleting
- Most settings can be changed after creation; the email address cannot.
- Deleting an account is permanent. On Enterprise,
account.deletecan be placed under dual control. - An account that a View reads from cannot be deleted until it is removed from every view — the error names the blocking views.
- Accounts count toward the license limit (IMAP, local, and View alike). See Licensing & Trials.
API
| Method | Path | Description |
|---|---|---|
GET | /api/v1/accounts | List accounts (includes type and view config) |
POST | /api/v1/account | Create an account |
GET/POST | /api/v1/account/{account_id} | Get / update one account (retention fields are rejected) |
POST | /api/v1/account/{account_id}/retention | Change retention policy (root only; weakening changes may require approval) |
DELETE | /api/v1/account/{account_id} | Delete an account |
POST | /api/v1/accounts/{account_id}/start-download | Start a sync |
POST | /api/v1/accounts/{account_id}/cancel-download | Cancel a running sync |
GET | /api/v1/accounts/{account_id}/download-stats | Per-folder sync statistics |
GET | /api/v1/accounts/{account_id}/gap-fill-stats | Gap-fill statistics |
GET | /api/v1/oauth2-list | List OAuth2 providers |
POST | /api/v1/oauth2 | Create an OAuth2 provider |
GET | /api/v1/list-proxy | List proxies |
POST | /api/v1/proxy | Create a proxy |
POST | /api/v1/accounts/access/assignments | Batch-assign an account role to users |