VISTAMATIONS MAIL SERVER

Network topology and data flow map

๐Ÿ“ง Admin Register โ˜๏ธ Vercel Serverless โ˜๏ธ Cloudflare ๐Ÿ“ค Brevo ๐Ÿ“ฅ Gmail ๐Ÿ”‘ Secrets
Gate 1 โ€” Password
Admin enters password (min 8 chars)
๐Ÿ“
2-gate auth
Gate 2 โ€” 4-Digit PIN
Admin PIN (e.g., 1973)
๐Ÿ”
vercel.json
Vercel Serverless
api.js handler ยท vercel.json ยท serverless functions
โ˜๏ธ
wrangler.toml
Cloudflare Worker
src/index.js ยท D1 database ยท DMARC reports
โ˜๏ธ
email routing
Brevo (SMTP)
Transactional email ยท marketing
๐Ÿ“ค
Gmail
Recipient inbox ยท DMARC โ†’ dmarc-reports@vistamations.com
๐Ÿ“ฅ

๐Ÿ“ง Email Flow

1. Client โ†’ Vercel API (register/login)
2. Vercel โ†’ Cloudflare Worker (D1)
3. Cloudflare โ†’ Brevo (SMTP)
4. Brevo โ†’ Gmail (recipient)
5. Gmail โ†’ DMARC (dmarc-reports@vistamations.com)

๐Ÿ”‘ Secrets & Credentials

DB_HOST Database host (Cloudflare D1 / RDS)
DB_USER Database username
DB_PASS Database password
CLOUDFLARE_API_TOKEN Cloudflare API token (Workers + D1)
VISTAMATIONS_API_KEY Vistamations API key
SENDER_EMAIL Email sender (info@vistamations.com)

๐Ÿ‘ค Admin Registration Flow

1. Open admin-register.html
2. Enter password (Gate 1)
3. Enter PIN (Gate 2)
4. Server validates & stores (SHA-256 hash)
5. Login with email + password + PIN
Vistamations ยท www.vistamations.com ยท admin@vistamations.com ยท DMARC โ†’ dmarc-reports@vistamations.com
Brevo โ†’ Gmail Cloudflare โ†’ Vercel Admin โ†’ 2-gate