AI-Native Website Setup — Quick Reference

Companion to ai-native-website-setup-playbook.md Use this to prep before starting a new client site build.


Pre-Build Checklist (Gather Before Starting)

Client Must Provide

  • Company name + legal entity name
  • Domain name (purchased and ready)
  • Tagline / one-line description
  • Primary contact email
  • Phone number
  • Physical location (city, state)
  • Brand colors (primary, accent, background at minimum; ideally full palette)
  • Font choice (Google Fonts name)
  • Logo files (horizontal, PNG + SVG)
  • Headshots for team members (500x500 min)
  • Social media links (LinkedIn, X/Twitter)
  • Service descriptions (3-8 services)
  • FAQ content (6-15 questions)
  • Legal disclaimer text (if regulated industry)
  • Cal.com (or other scheduler) booking link
  • Content/copy for key pages (or a brief to write from)

Accounts to Create (Section 1)

AccountURLWhat You Need
GitHubgithub.comRepo for code
Cloudflarecloudflare.comHosting + DNS + security
Brevobrevo.comTransactional email (free tier)
Cloudflare Turnstiledash.cloudflare.comCAPTCHA (free, privacy-respecting)
Cal.comcal.comScheduling (free tier)
Umamicloud.umami.isAnalytics (free tier, GDPR-friendly)

Credentials to Collect

CredentialWhere to Find
TURNSTILE_SITE_KEYCloudflare > Turnstile > Widget settings
TURNSTILE_SECRET_KEYSame (secret key)
BREVO_API_KEYBrevo > Settings > SMTP & API
BREVO_LIST_IDBrevo > Contacts > Lists (usually “2”)
CLOUDFLARE_ACCOUNT_IDCloudflare dashboard URL bar
CLOUDFLARE_API_TOKENCloudflare > Profile > API Tokens
UMAMI_WEBSITE_IDUmami > Settings > Websites

Build Phases (13 Sections)

PhaseSectionWhat Gets BuiltKey Files
1PrerequisitesAccounts, DNS, credentials.env, .dev.vars
2ScaffoldingAstro project, config, design tokensastro.config.mjs, tailwind.config.mjs, wrangler.toml
3ComponentsAll reusable UI components + layoutsBaseLayout, Nav, Footer, ContactForm, + 8 more
4API RoutesContact form, newsletter, middlewaresend-email.ts, newsletter-subscribe.ts, middleware.ts
5ContentBlog system, pages, verticals, resourcescontent.config.ts, blog pages, /for/*, PrintLayout
6SecurityHeaders, CSP, WAF, security.txt, SRI_headers, .well-known/security.txt
7TestingFull E2E test suite10+ spec files in tests/e2e/
8CI/CDDeploy, test, scheduled publish3 workflow files + dependabot
9AssetsImages, favicons, PDFsgenerate-pdfs.mjs, CREDITS.md
10DeployFirst deploy, custom domain, monitoringCloudflare Pages dashboard
11WP Migration(Optional) WordPress to Astro conversionwordpress-export-to-markdown
12QALighthouse, a11y, cross-browser, reviewerSenior Reviewer workflow
13Post-LaunchDNS verify, SEO submission, docsCLAUDE.md, .env.example

Run This First (After Section 1 is Complete)

# 1. Scaffold
mkdir project-name && cd project-name
npm create astro@latest . -- --template minimal --typescript strict --install --git
 
# 2. Install dependencies
npm install @astrojs/cloudflare @astrojs/tailwind @astrojs/sitemap @astrojs/rss tailwindcss @tailwindcss/typography lucide-astro sharp @fontsource/inter
npm install -D @playwright/test typescript
 
# 3. Install test browsers
npx playwright install chromium
 
# 4. Copy .dev.vars from template and fill in credentials
 
# 5. Start dev server
npm run dev

Critical Files (Must Exist Before Deploy)

src/lib/constants.ts          # Site-wide constants (NEVER hardcode URLs)
src/lib/api-helpers.ts         # Shared validation + security utilities
src/layouts/BaseLayout.astro   # Base layout with meta tags, OG, analytics
src/components/Nav.astro       # Sticky nav with mobile hamburger
src/components/Footer.astro    # Footer with newsletter + email obfuscation
src/components/ContactForm.astro # Contact form with honeypot + Turnstile
public/_headers                # Security headers (CSP, HSTS, etc.)
wrangler.toml                  # Cloudflare config with public vars
playwright.config.ts           # Test config with build+preview webServer
.github/workflows/deploy.yml   # Push-to-main auto-deploy
.dev.vars                      # Local secrets (NEVER commit)

Quality Gates

After every major section:

  1. npm run build (must succeed)
  2. npx playwright test (must pass)
  3. Commit with descriptive message
  4. Senior Reviewer audit (for final deploy)

Target: 90+ on all four Lighthouse categories (Performance, Accessibility, Best Practices, SEO)


Key Patterns to Remember

PatternWhy
BOOKING_URL from constants.ts, never hardcodedSingle source of truth for booking link
data-cal-link + href={BOOKING_URL} on every CTACal.com modal + no-JS fallback
<picture> with WebP source + JPG fallbackPerformance + browser compatibility
escapeHtml() on all user input in emailsXSS prevention
MAX_LENGTHS validation on all API inputsInput boundary protection
export const prerender = false on API routesRequired for Cloudflare SSR
Turnstile test key in playwright.config.tsTests pass without real CAPTCHA
data.date <= new Date() for blog filteringFuture-dated posts hidden until publish date
Daily cron deploy for blog auto-publishFuture posts go live automatically

Template Variables Quick Count

CategoryCount
Company identity6
Contact info5
Booking/scheduling3
Social media2
Brand colors10
Typography2
Infrastructure4
Content3
Structure (JSON)9
Total44

All variables defined in Section 0.1 of the main playbook.


Generated by Solanasis LLC.