Skip to content

Rebuild permit cancellation alert worker#55

Merged
Trailgenic merged 1 commit into
mainfrom
codex/rebuild-permit-cancellation-alerts
Jul 19, 2026
Merged

Rebuild permit cancellation alert worker#55
Trailgenic merged 1 commit into
mainfrom
codex/rebuild-permit-cancellation-alerts

Conversation

@Trailgenic

Copy link
Copy Markdown
Owner

What changed

  • Rebuilt the permit poller around exact permit, selected-date, and party-size inventory alerts.
  • Added verified adapters for Mt. Whitney Day Use, Mt. Whitney Overnight, and Half Dome Daily.
  • Replaced KV-style state with D1 snapshots, tracker state, transition history, and an idempotent notification outbox.
  • Added separate poll and notification queues with dead-letter queues.
  • Added Twilio Verify enrollment, Twilio SMS delivery, Turnstile enforcement, CORS controls, masked phone responses, and bearer-token tracker management.
  • Added idempotent Cloudflare resource provisioning, D1 migrations, Worker secret installation, and deployment through GitHub Actions.
  • Added fixture, parser, matching, HTTP, and workerd/D1 integration coverage.

Why

The prior Worker mixed permit divisions, used incorrect Recreation.gov API families and facility identifiers, treated invalid or missing inventory as availability changes, and was never deployed by the repository workflow. Cloudflare itself was not the core failure.

Impact

This intentionally supports one product: cancellation/inventory alerts when a validated, immediately bookable quantity satisfies the user's exact dates and party size. Lottery calendars and deadline reminders remain excluded.

Validation

  • npm run lint
  • npm test — 2 passed
  • npm run test:permit-poller — 15 passed
  • npm run test:workers — 24 passed
  • npm run validate:json
  • npm run validate:registry
  • Wrangler dry-runs for both Workers
  • Live Recreation.gov contract check for all three initial products
  • git diff --check

@vercel

vercel Bot commented Jul 19, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
workers Ready Ready Preview, Comment Jul 19, 2026 8:41pm

Request Review

@Trailgenic
Trailgenic marked this pull request as ready for review July 19, 2026 20:52
@Trailgenic
Trailgenic merged commit bd5aa56 into main Jul 19, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant