Using Extensions
Overview
A few lightweight extensions are included for festival fun and operations. They are intentionally simple so volunteers can read, copy commands, and run tests quickly.
Included Features
- Contact Form: sends `email` and `message` to
/api/submit. The function validates input and attempts to forward using the configured email binding. - Radio Bingo (demo): playful extension that posts random prompts to the blog for on-site games. Use only in scheduled windows.
- Operator Notice: small admin page (off-repo) to broadcast short messages via SMS or internal channels. Implementation depends on provider credentials.
How to test the contact form
From any machine with network access, run:
curl -X POST -F "email=you@example.com" -F "message=Hello from test" https://your-site.pages.dev/api/submit Response codes:
- 200 — email sent successfully.
- 202 — acceptance in preview; binding not configured.
- 400 — validation error (bad email or message).
Operator Quick Tips
- Confirm the `CONTACT_EMAIL` binding in the Pages dashboard for production email delivery.
- Use the site preview to check function logs when testing; Cloudflare logs show helpful errors.
- Keep test messages short and include the operator email for verification.
Troubleshooting
If contact submissions do not arrive: check deploy logs, verify binding configuration, and ensure the destination email is verified in Cloudflare Email Routing (if used).