improvement(usage): free plan to 1000 credits (#3516)

* improvement(billing): free plan to five dollars

* fix comment

* remove per month terminology from marketing

* generate migration

* remove migration

* add migration back
This commit is contained in:
Vikhyath Mondreti
2026-03-10 23:10:37 -07:00
committed by GitHub
parent b34bb643a5
commit 4509a75a02
11 changed files with 13062 additions and 9 deletions

View File

@@ -141,7 +141,7 @@ Sim has two paid plan tiers — **Pro** and **Max**. Either can be used individu
| Plan | Price | Credits Included | Daily Refresh |
|------|-------|------------------|---------------|
| **Free** | $0 | 3,000/mo | — |
| **Community** | $0 | 1,000 (one-time) | — |
| **Pro** | $25/mo | 5,000/mo | +50/day |
| **Max** | $100/mo | 20,000/mo | +200/day |
| **Enterprise** | Custom | Custom | — |

View File

@@ -20,7 +20,7 @@ const PRICING_TIERS: PricingTier[] = [
price: 'Free',
color: '#2ABBF8',
features: [
'3,000 credits/mo',
'1,000 credits (trial)',
'5GB file storage',
'5 min execution limit',
'Limited log retention',

View File

@@ -96,7 +96,7 @@ export default function StructuredData() {
offers: [
{
'@type': 'Offer',
name: 'Community Plan — 3,000 credits included',
name: 'Community Plan — 1,000 credits included',
price: '0',
priceCurrency: 'USD',
availability: 'https://schema.org/InStock',
@@ -191,7 +191,7 @@ export default function StructuredData() {
name: 'How much does Sim cost?',
acceptedAnswer: {
'@type': 'Answer',
text: 'Sim offers a free Community plan with 3,000 credits, a Pro plan at $25/month with 6,000 credits, a Max plan at $100/month with 25,000 credits, team plans available for both tiers, and custom Enterprise pricing. All plans include CLI/SDK access.',
text: 'Sim offers a free Community plan with 1,000 credits to start, a Pro plan at $25/month with 6,000 credits, a Max plan at $100/month with 25,000 credits, team plans available for both tiers, and custom Enterprise pricing. All plans include CLI/SDK access.',
},
},
{

View File

@@ -37,7 +37,7 @@ interface PricingTier {
}
const FREE_PLAN_FEATURES: PricingFeature[] = [
{ icon: DollarSign, text: '3,000 credits/mo' },
{ icon: DollarSign, text: '1,000 credits (trial)' },
{ icon: HardDrive, text: '5GB file storage' },
{ icon: Timer, text: '5 min execution limit' },
{ icon: Database, text: 'Limited log retention' },

View File

@@ -44,7 +44,7 @@ export function WelcomeEmail({ userName }: WelcomeEmailProps) {
<div style={baseStyles.divider} />
<Text style={{ ...baseStyles.footerText, textAlign: 'left' }}>
You're on the free plan with 3,000 credits to get started.
You're on the Community plan with 1,000 credits to get started.
</Text>
</EmailLayout>
)

View File

@@ -5,7 +5,7 @@
/**
* Fallback free credits (in dollars) when env var is not set
*/
export const DEFAULT_FREE_CREDITS = 15
export const DEFAULT_FREE_CREDITS = 5
/**
* Default per-user minimum limits (in dollars) for paid plans when env vars are absent.

View File

@@ -6,7 +6,7 @@
/**
* Default free credits (in dollars) for new users
*/
export const DEFAULT_FREE_CREDITS = 20
export const DEFAULT_FREE_CREDITS = 5
/**
* Storage limit constants (in GB)

View File

@@ -0,0 +1 @@
ALTER TABLE "user_stats" ALTER COLUMN "current_usage_limit" SET DEFAULT '5';

File diff suppressed because it is too large Load Diff

View File

@@ -1184,6 +1184,13 @@
"when": 1773207052828,
"tag": "0169_quiet_marvel_boy",
"breakpoints": true
},
{
"idx": 170,
"version": "7",
"when": 1773209025121,
"tag": "0170_careful_saracen",
"breakpoints": true
}
]
}

View File

@@ -741,7 +741,7 @@ export const userStats = pgTable('user_stats', {
totalA2aExecutions: integer('total_a2a_executions').notNull().default(0),
totalTokensUsed: integer('total_tokens_used').notNull().default(0),
totalCost: decimal('total_cost').notNull().default('0'),
currentUsageLimit: decimal('current_usage_limit').default(DEFAULT_FREE_CREDITS.toString()), // Default $20 for free plan, null for team/enterprise
currentUsageLimit: decimal('current_usage_limit').default(DEFAULT_FREE_CREDITS.toString()), // Default $5 (1,000 credits) for free plan, null for team/enterprise
usageLimitUpdatedAt: timestamp('usage_limit_updated_at').defaultNow(),
// Billing period tracking
currentPeriodCost: decimal('current_period_cost').notNull().default('0'), // Usage in current billing period