This runbook deliberately separates code proof, database migration, deployment, provider changes, UAT, and public activation. Completing one gate does not authorize the next.
- Run lint, type checking, unit tests, a credential-free production build, database integration tests, and
pnpm wordpress:check. - Run
pnpm wordpress:package, inspect the ZIP contents, and confirm only the plugin directory is included. - Review
dogfood-output/report.mdand repeat authenticated dashboard UAT against the candidate deployment.
- Back up the target PostgreSQL database.
- Apply migrations
0006through0018in order withpnpm db:migrate. - Confirm
forms,formOrigins,wordpressConnections,usagePeriods,formRateBuckets,formPlacementMilestones, andformCacheInvalidationexist, and thatformCacheInvalidationhas no cascading foreign key toform(migration0018). - Confirm the
wordpress_connection_active_owner_site_uniqueindex (migration0016) and theuser.stripeBillingIntervalcolumn (migration0015) exist. - Confirm usage notification lease/limit columns, the Enterprise contract allowance columns, the Stripe subscription creation timestamp, and the form-lead lookup index exist; existing Enterprise accounts should have the compatibility allowance from
0013. - Confirm existing endpoint and lead counts are unchanged and the current UTC usage backfill is plausible.
- Configure
FORM_SUBMISSION_SECRET, email settings, PostHog settings, Stripe webhook secret, and the four new price IDs. - Deploy app code with
FORMS_NAV_ENABLED=falseso direct routes are available for UAT while Forms navigation and endpoint CTAs remain hidden. - Smoke the legacy endpoint GET and authenticated POST contracts before testing any public form.
- Create a blank form, publish it, open the hosted route, submit it, and confirm the attributed lead and webhook log.
- Repeat with an approved generic origin and a connected WordPress test site.
- Attach
forms.router.soonly after the application smoke passes. - Verify TLS, middleware routing,
/embed/v1.js, hosted render sessions, public submissions, ETags, and unpublish behavior on the actual host. - Test a stale cached definition by publishing a new revision and confirming the next definition request changes ETag and content.
- Test the ZIP on WordPress 6.6 and current stable, using one block theme and one classic theme on PHP 7.4+.
- Verify activation, connection, nonce-protected picker, token revocation, Gutenberg preview, block frontend, shortcode frontend, and multiple forms per page.
- Publish the already verified ZIP for download. WordPress.org submission remains deferred.
- Create and activate the four new Stripe Prices, then configure their IDs in the app and allow those Prices in Billing Portal subscription updates. Archive the legacy Prices only after verifying entitlement continuity, and set the Portal's proration behavior deliberately before customers can change plans.
- Run
pnpm stripe:legacy-migrationwithout--apply; review every subscription in the dry-run output. - After explicit authorization, re-run with
--applyand verify Stripe webhook readback recordscancel_at_period_endand the period end for each affected user. - Send the approved customer communications from
legacy-customer-email-drafts.mdon the stated schedule.
- Publish the Router website and docs changes.
- Set
FORMS_NAV_ENABLED=trueonly after authenticated UAT and all hosted/embed/WordPress smoke tests pass. - Watch form creation, publishing, placement connection, first-lead events, quota errors, rate limits, and webhook failures without capturing lead values.
Set FORMS_NAV_ENABLED=false and FORMS_PUBLIC_ENABLED=false. Do not roll back or edit applied migrations. Existing endpoint APIs, leads, and webhooks must remain operational. If public traffic is unsafe, detach forms.router.so after disabling routes; leave the core authenticated endpoint path untouched.