Skip to Content
Slloy Docs
Business, Pricing & Channels

Pricing, Credit Valuation & Margin Guardrails

Complete reference for Slloy's 9 subscription and credit pack plans, credit expiration buckets, dual-line margin guardrails, frontend CNY anchor, and video true-up rules.

All pricing, credit unit valuations, and cost-accounting rules live in a single authoritative module: server/src/pricing.ts. Routes and admin reports never compute prices or margins inline; they call pricing.ts functions and are enforced at startup by server/src/marginGuard.ts.

1. The 9 Active Plans (PLANS)

Slloy sells 2 monthly auto-renewing subscriptions, 2 one-time annual plans, and 5 one-time credit packs. Every catalog price is settled in USD via Stripe (currency = usd).

Plan IDBilling ModePrice (USD)Intro OfferCredits GrantedTier (users.plan)Credit ExpiryUnit Value (FX = 7.15)
basic_monthlySubscription (monthly)$14.90 (1490 cents)$9.90 first month ($5.00 off, duration=once)1,000basic60 days¥0.1065 / credit
pro_monthlySubscription (monthly)$39.90 (3990 cents)None5,000pro60 days¥0.0571 / credit (Base Plan)
basic_annualOne-time (payment)$139.90 (13990 cents)None12,000basic365 days¥0.0834 / credit
pro_annualOne-time (payment)$419.90 (41990 cents)None60,000pro365 days¥0.0500 / credit
pack_starterOne-time (payment)$29.90 (2990 cents)None1,000basic365 days¥0.2138 / credit
pack_creatorOne-time (payment)$49.90 (4990 cents)None3,000basic365 days¥0.1189 / credit
pack_businessOne-time (payment)$99.90 (9990 cents)None8,000basic365 days¥0.0893 / credit
pack_scaleOne-time (payment)$499.90 (49990 cents)None75,000basic365 days¥0.0477 / credit
pack_enterpriseOne-time (payment)$949.90 (94990 cents)None150,000basic365 days¥0.0453 / credit (Stress Floor)

Free Credit Grants & Credit Buckets

  • Signup Bonus: 100 credits upon account creation (reason = 'signup'), permitting 10 generations on z-image-turbo (10 credits) or 3 generations on seedream / seedream-5-5 (30 credits).
  • Daily Check-in: 10 credits per calendar day in Asia/Shanghai timezone (reason = 'checkin').
  • Bucket Consumption Order (credit_buckets): Every grant is stored in credit_buckets with an optional expires_at. Deductions (chargeCredit) consume buckets in earliest-expiring-first (FIFO by expires_at ASC NULLS LAST) order so expiring subscription credits (60 days) are spent before annual/pack credits (365 days) or non-expiring bonus credits.

2. Valuation Constants & Cost Anchors

Two distinct CNY-per-credit constants exist in server/src/pricing.ts for different accounting purposes:

ConstantValuePurpose & Rules
CREDIT_CNY¥0.011Historical Cost Anchor (¥0.22 / 20 credits). Used only for nominal cost reference (chargedCny baseline in true-up comparisons). Never use CREDIT_CNY as user revenue or to calculate margin, as doing so undervalues revenue by 5.2x.
FX_USD_CNY7.15Backend Settlement Exchange Rate (USD -> CNY). Used to convert Stripe USD order cents into CNY revenue (paidCny = (amount_cents / 100) * 7.15) and to compute per-credit revenue across plans.
BASE_PLAN"pro_monthly"Catalog Pricing Benchmark Plan ($39.90 for 5,000 credits). Selected as the pricing anchor instead of pack_enterprise (¥0.0453) so standard retail prices are not artificially inflated by deep wholesale discounts.
BASE_UNIT_CNY¥0.057057 (≈ ¥0.0571)Real Revenue Per Credit on pro_monthly: (39.90 * 7.15) / 5000. All catalog margin audits and credit price formulas use BASE_UNIT_CNY.

Catalog Pricing Formula & Rounding Step

All user-facing credit prices for images, videos, and effects must be integer multiples of ROUNDING_STEP = 10:

minCredits = ceil((costCny * SAFETY) / ((1 - TARGET_MARGIN) * BASE_UNIT_CNY))
catalogCredits = ceilToNearest10(minCredits)

3. Dual-Line Margin Guard (marginGuard.ts)

At Worker startup (and in CI via server/scripts/audit-margins.ts), assertMargins() audits every active product SKU:

  • All 12 video models across every supported resolution (480p, 720p, 1080p) and duration (5s, 10s, 15s)
  • All 5 image models (checking each aspect ratio individually for pixel-tiered Ark models)
  • All 15 photo and video effects
  • Subscription introductory coupons (introPriceProblem checks that first-month per-credit price does not undercut pack_enterprise)

Safety Multipliers (MARGIN_SAFETY)

Because upstream channel costs can fluctuate or rely on token estimation, assertNoThinMargin() multiplies estimated cost by a safety factor before computing worstMargin:

worstMargin = (credits * BASE_UNIT_CNY - costCny * SAFETY) / (credits * BASE_UNIT_CNY)
  • 1.05: Bill-calibrated Ark video models (doubao-seedance-2-0-mini-260615, doubao-seedance-2-0-fast-260128) where token-per-second constants already include a +3% buffer.
  • 1.10: Fixed per-image or per-second official price tables (Ark doubao-seedream-5-0-pro-260628, doubao-seedream-5-5-261028; DashScope qwen-image-3.0, qwen-image-3.0-pro, z-image-turbo, wan2.2-*, wan2.6-*, wan2.7-*, wan3.0-video; Kling kling-3.0, kling-4.0).
  • 1.20 (MARGIN_SAFETY_DEFAULT): Unbilled/estimated token-priced models (doubao-seedance-2-0-260128, doubao-seedance-2-5-260628, doubao-seedance-2-5-flash-261115) and any unknown model ID.

Dual-Line Thresholds

  1. TARGET_MARGIN = 0.50 (50% Soft Line):
    • Any SKU with worstMargin < 0.50 emits a [margin-guard] ⚠ warning log with the recommended minCredits, but allows the Worker to start.
    • Example: pro 1080p rounded to 600 credits has a 49.6% worst-case margin under a 1.20 safety multiplier.
  2. HARD_MARGIN_FLOOR = 0.20 (20% Hard Floor):
    • Any SKU with worstMargin < 0.20, any non-multiple-of-10 catalog price, or any invalid effect model reference is recorded in audit.problems.
    • assertMargins() throws an error and refuses to start the Worker (unless SKIP_MARGIN_GUARD=1 is explicitly set during emergency observation).

4. Frontend CNY Price Anchor (plan-prices.ts)

On Chinese locale pages (zh-CN), pricing cards display an approximate RMB anchor (e.g., ≈ ¥104) next to the USD price via frontend/site/components/plan-prices.ts:

  • Static Exchange Rate (fx):
    export const fx = { asOf: "2026-11-17", cny: 7.0 } as const;
  • Design Rules:
    1. Never fetch live exchange rates on the rendering path (avoids external latency and hydration mismatches).
    2. Always prefix with ≈ ¥ and state that settlement is in USD via Stripe; format thousands using a deterministic regex (grouped()) rather than toLocaleString() to prevent Node SSR vs. browser ICU hydration mismatches.
    3. 365-Day CI Freshness Guard (tests/server/plan-prices.test.ts): A unit test asserts Date.now() - Date.parse(fx.asOf) < 365 days and verifies that monthlyPrice, annualPrice, packPrice, monthlyCredits, and annualCredits in plan-prices.ts match server/src/pricing.ts (PLANS) and config.subscriptions.introOffCents.

5. Video Post-Settlement True-Up (TRUEUP_THRESHOLD = 1.2)

For token-billed video models (Volcengine Ark Seedance), actual token consumption (usage_tokens) is only known when the video finishes rendering.

  • Trigger Condition:
    1. Video settlement runs on the foreground browser polling path (allowTrueUp = true in GET /api/video/status/:id; background videoSweeper.ts passes allowTrueUp = false so users are never surprise-charged after closing the tab).
    2. The runtime setting app_settings.videoTrueUp is "1".
    3. The upstream response includes measured realTokens > 0.
    4. Real cost exceeds 1.2x (TRUEUP_THRESHOLD = 1.2) of the nominal cost anchor (chargedCny = chargedCredits * CREDIT_CNY).
  • Calculation (trueUpCredits):
    const fairCredits = Math.ceil(realCny / BASE_UNIT_CNY);
    const surcharged = Math.max(0, fairCredits - chargedCredits);
    Note that fairCredits divides by BASE_UNIT_CNY (¥0.0571), not CREDIT_CNY (¥0.011). Because catalog prices already include a 50% margin buffer, true-up only fires on extreme token anomalies and never double-charges normal generations.

On this page