Contact form worker

Handles POST /api/contact from the contact form on the homepage and emails the submission to the team using Cloudflare Email Service. Replies go straight to the person who filled in the form.

One-time setup

  1. In the Cloudflare dashboard, onboard slipboss.com for sending in Email Service (adds the SPF/DKIM DNS records). The CONTACT_FROM address must be on that domain.

  2. Deploy:

    cd workers/contact
    npm install
    npx wrangler login
    npm run deploy
    

Local development

npm run dev

Emails are not really sent locally; wrangler prints them and writes the body to .wrangler/tmp/email/.