Export & Import
Export and import commands let you save inboxes with their encryption keys for backup, sharing, or migrating between machines.
vsb export
Section titled “vsb export”Export an inbox with its encryption keys to a JSON file.
vsb export [email-address] [flags]Arguments
Section titled “Arguments”| Argument | Description |
|---|---|
email-address | Inbox to export (uses active inbox if omitted) |
| Flag | Description |
|---|---|
--out | Output file path (default: <email>.json) |
Examples
Section titled “Examples”# Export active inboxvsb export
# Export specific inbox
# Export to specific fileOutput
Section titled “Output”✓ Export completeA security warning is displayed reminding you that the file contains private keys.
File Format
Section titled “File Format”The export file is a JSON document containing:
{ "version": 1, "inboxHash": "abc123", "expiresAt": "2024-01-16T14:30:00Z", "exportedAt": "2024-01-15T14:30:00Z", "keys": { "kemPrivate": "...", "kemPublic": "...", "serverSigPk": "..." }}vsb import
Section titled “vsb import”Import an inbox from an export file.
vsb import <file> [flags]Arguments
Section titled “Arguments”| Argument | Description |
|---|---|
file | Path to export file |
| Flag | Description |
|---|---|
-l, --local | Skip server verification |
-f, --force | Overwrite if inbox already exists |
Examples
Section titled “Examples”# Import inboxvsb import backup.json
# Import and overwrite existingvsb import backup.json -f
# Skip server verificationvsb import backup.json -lOutput
Section titled “Output”✓ Inbox verified: 5 emails
Import Complete
Address: [email protected]Expires: 720h0m0s
This inbox is now your active inbox.Run 'vsb' to see emails.Use Cases
Section titled “Use Cases”Backup Before Deletion
Section titled “Backup Before Deletion”# Export before deleting
# Later, restore if neededvsb import backup.jsonShare Between Machines
Section titled “Share Between Machines”# On machine A: Export
# Transfer file securely (scp, encrypted email, etc.)scp shared-inbox.json user@machine-b:~/
# On machine B: Importvsb import ~/shared-inbox.jsonCI/CD Persistent Inboxes
Section titled “CI/CD Persistent Inboxes”Instead of creating new inboxes for each CI run, you can use a persistent inbox:
jobs: test: steps: - name: Import test inbox run: | echo '${{ secrets.TEST_INBOX_EXPORT }}' > inbox.json vsb import inbox.json -f
- name: Run tests run: ./run-email-tests.shTeam Testing
Section titled “Team Testing”Share a test inbox with your team:
# Create and export a shared inboxvsb inbox create --ttl 30dvsb export --out team-test-inbox.json
# Store in secure location (password manager, encrypted vault)# Team members import on their machinesNext Steps
Section titled “Next Steps”- Inbox Commands - Manage inboxes
- Wait Command - CI/CD integration
- Configuration - Keystore and data storage