FormHarbour - Universal Form Backend

  • Tech Stack: Google Apps Script V8, Google Sheets, MailApp, LockService, CacheService, PropertiesService, and JavaScript
  • GitHub URL: Repository Link

FormHarbour is a lightweight, universal form backend for websites that need reliable submissions without operating a separate server or database. One Google Apps Script Web App endpoint accepts compatible forms from multiple sites and routes each hostname into its own Google Sheet tab.

The backend is designed around durable delivery and safe retries: it saves each submission before attempting notifications, keeps a stable submission identity for duplicate protection, and recovers pending email work through a bounded queue.

  • Per-site routing - Creates and evolves a dedicated Google Sheet tab for each normalized website hostname.
  • Durable notifications - Sends formatted HTML and plain-text email through a retryable per-recipient queue.
  • Idempotent submissions - Detects duplicate requests and rejects conflicting reuse of a submission ID.
  • Abuse controls - Includes honeypot capture, hostname rate limiting, field bounds, and formula-injection protection.
  • Operational diagnostics - Provides setup, dry-run, health-check, and recovery-worker functions for Apps Script operators.
  • Site-aware controls - Routes different domains and subdomains to separate recipients, while allowing aliases to share a record sheet, honeypot review sheet, and rate limit.
  • Configurable confirmations - Supports per-site submitter confirmation emails and frontend saved-data notifications, both controlled from the site configuration sheet.
  • Honeypot review workflow - Isolates bot captures, provides editable read-status chips, and sends one combined digest after the five-day review window when needed.
  • Verification - Covered by 36 dependency-free behavioral tests, including burst, duplicate, rate-limit, retry, alias-routing, and queue-recovery scenarios.

FormHarbour keeps the integration surface small for frontend teams: add a site hostname, stable submission ID, and optional honeypot field to an existing form, then send it to the deployed Web App endpoint.

Technical approach

FormHarbour uses Google Sheets as a durable, schema-evolving store and coordinates concurrent mutations with LockService. Submission rows, idempotency records, queue items, and operational logs are persisted before mail delivery, so the Web App can return without waiting on slow email calls. A five-minute worker claims eligible recipient jobs with leases, applies retry backoff and quota protection, and recovers rows whose queue work was interrupted. Site configuration is cached for two minutes and invalidated after edits, while managed system columns are resized during setup and twice-daily maintenance.