Pre-launch — Gluecron is in final validation. Public signups and git hosting for non-owner users open after launch review.
CodeIssuesDiscussionsWikiPull RequestsProjectsCommitsActionsReleasesContributorsPulse● GatesSecuritySettingsDeploymentsPipelineInsightsAgents✨ Explain✨ Ask AI✨ Workspace✨ Spec✨ Tests▓ Debt Map✨ NL Search🏛 Archaeology
Blame · Line-by-line history

0038_stripe_billing.sql

Each line is annotated with the commit that last touched it. Click any SHA to jump to that commit and see the surrounding change.

0038_stripe_billing.sqlBlame18 lines · 1 contributor
619109aClaude1-- Stripe billing columns on user_quotas. Adds subscription linkage + lifecycle
2-- state so the webhook handler can auto-assign plans and enforce grace periods.
3
4ALTER TABLE user_quotas
5 ADD COLUMN IF NOT EXISTS stripe_customer_id TEXT,
6 ADD COLUMN IF NOT EXISTS stripe_subscription_id TEXT,
7 ADD COLUMN IF NOT EXISTS stripe_subscription_status TEXT,
8 ADD COLUMN IF NOT EXISTS current_period_end TIMESTAMPTZ;
9--> statement-breakpoint
10
11CREATE UNIQUE INDEX IF NOT EXISTS user_quotas_stripe_customer_id_idx
12 ON user_quotas (stripe_customer_id)
13 WHERE stripe_customer_id IS NOT NULL;
14--> statement-breakpoint
15
16CREATE INDEX IF NOT EXISTS user_quotas_stripe_subscription_status_idx
17 ON user_quotas (stripe_subscription_status)
18 WHERE stripe_subscription_status IS NOT NULL;