Consolidate audit-fixes branch: webhooks, integrations, and deploy hardening
Batch commit of the pending working tree on security/audit-fixes-2026-07. Major areas: - Outbound webhooks / Zapier: schema + signed delivery with retries, public v1 API (REST-hook subscribe/unsubscribe), settings UI, cron drain. - Deploy hardening: email via SMTP2GO (Resend fully removed), verified DB TLS (DATABASE_SSL=require + DATABASE_CA), storage fails loud in production when Spaces is unconfigured instead of silently using ephemeral disk. - Integrations & features (concurrent work): accounting (QuickBooks/Xero), e-signature (DocuSign/Dropbox Sign), PayPal, geocoding/maps, onboarding, expanded legal pages. - DB migrations 0006–0009. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
969d5d4c8a
commit
c9968531e4
+19
-19
@@ -35,25 +35,25 @@ export const PLAN_LIMITS: Record<Plan, PlanLimits> = {
|
||||
},
|
||||
}
|
||||
|
||||
export const PLAN_PRICES: Record<string, { plan: Plan; priceId: string; amount: number; interval: string }> = {
|
||||
pro: {
|
||||
plan: "pro",
|
||||
priceId: process.env.STRIPE_PRO_MONTHLY_PRICE_ID!,
|
||||
amount: 29,
|
||||
interval: "month",
|
||||
},
|
||||
landlord: {
|
||||
plan: "landlord",
|
||||
priceId: process.env.STRIPE_LANDLORD_MONTHLY_PRICE_ID!,
|
||||
amount: 59,
|
||||
interval: "month",
|
||||
},
|
||||
lifetime: {
|
||||
plan: "lifetime",
|
||||
priceId: process.env.STRIPE_LIFETIME_PRICE_ID!,
|
||||
amount: 199,
|
||||
interval: "one_time",
|
||||
},
|
||||
// Single source of truth for DISPLAYED prices (USD). Client-safe (plain numbers,
|
||||
// no env). Billing always charges the Stripe Price ID, so a mismatch here only
|
||||
// affects what the marketing/billing UI shows — keep these in sync with the
|
||||
// amounts configured on the Stripe Prices referenced below.
|
||||
export const PLAN_AMOUNTS = { starter: 0, pro: 29, landlord: 59, lifetime: 199 } as const
|
||||
|
||||
// Plan metadata (client-safe — no env, no price IDs). The actual Stripe price
|
||||
// is resolved at runtime by lib/stripe/prices.ts using stable lookup keys, so
|
||||
// the same code works in test and live with ONLY an API-key swap.
|
||||
export const PLAN_PRICES: Record<string, { plan: Plan; amount: number; interval: string }> = {
|
||||
pro: { plan: "pro", amount: PLAN_AMOUNTS.pro, interval: "month" },
|
||||
landlord: { plan: "landlord", amount: PLAN_AMOUNTS.landlord, interval: "month" },
|
||||
lifetime: { plan: "lifetime", amount: PLAN_AMOUNTS.lifetime, interval: "one_time" },
|
||||
}
|
||||
|
||||
// Annual billing is always offered; the yearly price is resolved (and
|
||||
// auto-provisioned if missing) at checkout time by lib/stripe/prices.ts.
|
||||
export function annualEnabled(): boolean {
|
||||
return true
|
||||
}
|
||||
|
||||
export function checkLimit(
|
||||
|
||||
Reference in New Issue
Block a user