Skip to content

Add 14-day free trial to the Team plan#1160

Merged
RhysSullivan merged 1 commit into
mainfrom
feat/team-14day-trial
Jun 27, 2026
Merged

Add 14-day free trial to the Team plan#1160
RhysSullivan merged 1 commit into
mainfrom
feat/team-14day-trial

Conversation

@RhysSullivan

@RhysSullivan RhysSullivan commented Jun 27, 2026

Copy link
Copy Markdown
Collaborator

What

Adds a 14-day free trial to the $150/mo Team plan, and reflects it across every customer-facing surface.

The trial is card-required and converts automatically: the customer enters a card up front and billing starts when the 14 days end (on_end: bill).

Changes

  • autumn.config.tsfreeTrial on the team plan (14 days, cardRequired: true). This is the deploy-time source synced via atmn, so the trial goes live when the config is pushed.
  • Marketing pricing (apps/marketing/src/pages/index.astro) — Team card now leads with "14-day free trial, cancel anytime", a Start free trial CTA, and a "14-day free trial, then $150 / month" line item.
  • In-app Choose-a-plan (apps/cloud/src/routes/app/billing_.plans.tsx) — reads plan.freeTrial from Autumn (no hard-coded copy), so the Team card shows "14-day free trial, then $150 / month" and a Start free trial button while the customer is still trial-eligible (trialAvailable).
  • In-app Billing (apps/cloud/src/routes/app/billing.tsx) — shows a Free trial badge and "Trial ends, then billing starts " while a customer is mid-trial.

Screenshots

Marketing pricing — Team plan
marketing-pricing-team-trial

In-app "Choose a plan" — trial offer on Team
in-app-choose-a-plan-start-free-trial

In-app Billing — mid-trial state
in-app-billing-mid-trial

Verification

  • bun run typecheck (42/42), bun run lint, bun run format:check all clean.
  • The two in-app shots were captured against a local cloud stack (real app, WorkOS emulator auth) with the listPlans/getOrCreateCustomer responses stubbed to the payload production Autumn returns once the config is deployed. The Autumn emulator doesn't serve plan definitions, so the trial UI is exercised against the real component + real code path with that injected plan data.

Notes

  • The config change does not take effect until the Autumn config is deployed (atmn push). The live $150 Team plan was left untouched.

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jun 27, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
executor-marketing 60d56ec Commit Preview URL

Branch Preview URL
Jun 27 2026, 11:37 PM

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jun 27, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
✅ Deployment successful!
View logs
executor-cloud 60d56ec Jun 27 2026, 11:39 PM

@greptile-apps

greptile-apps Bot commented Jun 27, 2026

Copy link
Copy Markdown

Greptile Summary

Adds a 14-day, card-required free trial to the Team plan across the Autumn config, in-app billing/plans pages, and marketing page.

  • autumn.config.ts: single source of truth; trial goes live only after atmn push.
  • In-app pages: trial label and pricing copy are derived dynamically from the Autumn plan object, keeping them in sync with config changes; the trialAvailable gate prevents customers from starting a second trial.
  • Marketing page: CTA and feature list item are hardcoded strings, so a future trial duration change in autumn.config.ts would require a manual update here too.

Confidence Score: 5/5

Safe to merge; changes are additive, behind an atmn push deploy gate, and do not touch any shared payment or auth logic.

All in-app trial UI is gated on data returned from Autumn (trialAvailable, trialing, freeTrial), so no hard-coded state controls billing behavior. The existing subscription lookup already filtered for status="trialing", the trialAvailable guard blocks repeat trials, and isCanceling/isSwitching priority ordering is consistent. The only hardcoded surface is the static marketing copy, which is a copy-staleness concern rather than a functional defect.

apps/marketing/src/pages/index.astro — the "14-day" duration string is hardcoded in two places and will drift silently if autumn.config.ts is updated later.

Important Files Changed

Filename Overview
autumn.config.ts Adds freeTrial (14 days, card required) to the team plan definition; the source-of-truth config that drives Autumn plan sync via atmn push.
apps/cloud/src/routes/app/billing.tsx Adds isTrialing flag from customerEligibility.trialing, a "Free trial" badge, and updated period-end copy; the existing subscription lookup already covers status="trialing" so sub.currentPeriodEnd is populated during trials.
apps/cloud/src/routes/app/billing_.plans.tsx Adds trialLabel helper and trialOffered gate (respects trialAvailable so repeat trials are blocked), swaps button label to "Start free trial", and renders trial pricing copy dynamically from the Autumn plan object.
apps/marketing/src/pages/index.astro Updates Team card CTA to "Start free trial" and prepends a hardcoded "14-day free trial, then $150 / month" feature list entry; duration is not read from autumn.config.ts, so a config change would require a manual update here.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Customer visits Team plan card] --> B{freeTrial != null?}
    B -- No --> C[Show normal Subscribe/Upgrade button]
    B -- Yes --> D{eligibility.trialAvailable !== false?}
    D -- No --> C
    D -- Yes --> E{action == activate or upgrade?}
    E -- No --> C
    E -- Yes --> F[trialOffered = true]
    F --> G[Label: Start free trial]
    F --> H[Show: 14-day free trial, then $150/month]
    G --> I[attach planId team]
    I --> J[Autumn starts 14-day trial]
    J --> K[billing.tsx: isTrialing=true]
    K --> L[Badge: Free trial]
    K --> M[Copy: Trial ends, then billing starts DATE]
    J --> N[After 14 days: auto-bill $150/mo]
Loading
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
    A[Customer visits Team plan card] --> B{freeTrial != null?}
    B -- No --> C[Show normal Subscribe/Upgrade button]
    B -- Yes --> D{eligibility.trialAvailable !== false?}
    D -- No --> C
    D -- Yes --> E{action == activate or upgrade?}
    E -- No --> C
    E -- Yes --> F[trialOffered = true]
    F --> G[Label: Start free trial]
    F --> H[Show: 14-day free trial, then $150/month]
    G --> I[attach planId team]
    I --> J[Autumn starts 14-day trial]
    J --> K[billing.tsx: isTrialing=true]
    K --> L[Badge: Free trial]
    K --> M[Copy: Trial ends, then billing starts DATE]
    J --> N[After 14 days: auto-bill $150/mo]
Loading

Reviews (2): Last reviewed commit: "Add 14-day free trial to the Team plan" | Re-trigger Greptile

Comment thread apps/cloud/src/routes/app/billing_.plans.tsx
@github-actions

github-actions Bot commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

Cloudflare preview

Torn down — the PR is closed.

@pkg-pr-new

pkg-pr-new Bot commented Jun 27, 2026

Copy link
Copy Markdown

Open in StackBlitz

@executor-js/cli

npm i https://pkg.pr.new/@executor-js/cli@1160

@executor-js/config

npm i https://pkg.pr.new/@executor-js/config@1160

@executor-js/execution

npm i https://pkg.pr.new/@executor-js/execution@1160

@executor-js/sdk

npm i https://pkg.pr.new/@executor-js/sdk@1160

@executor-js/codemode-core

npm i https://pkg.pr.new/@executor-js/codemode-core@1160

@executor-js/runtime-quickjs

npm i https://pkg.pr.new/@executor-js/runtime-quickjs@1160

@executor-js/plugin-file-secrets

npm i https://pkg.pr.new/@executor-js/plugin-file-secrets@1160

@executor-js/plugin-graphql

npm i https://pkg.pr.new/@executor-js/plugin-graphql@1160

@executor-js/plugin-keychain

npm i https://pkg.pr.new/@executor-js/plugin-keychain@1160

@executor-js/plugin-mcp

npm i https://pkg.pr.new/@executor-js/plugin-mcp@1160

@executor-js/plugin-onepassword

npm i https://pkg.pr.new/@executor-js/plugin-onepassword@1160

@executor-js/plugin-openapi

npm i https://pkg.pr.new/@executor-js/plugin-openapi@1160

executor

npm i https://pkg.pr.new/executor@1160

commit: 60d56ec

Adds a 14-day free trial to the $150/mo Team plan and reflects it across
the surfaces customers see:

- autumn.config.ts: freeTrial on the team plan (14 days, card required,
  bills automatically when the trial ends). This is the deploy-time source
  synced via atmn.
- marketing pricing: Team card now leads with "14-day free trial, cancel
  anytime", a "Start free trial" CTA, and a "14-day free trial, then $150 /
  month" line item.
- in-app Choose-a-plan page: reads plan.freeTrial from Autumn, so the Team
  card shows "14-day free trial, then $150 / month" and a "Start free trial"
  button while the customer is still trial-eligible.
- in-app Billing page: shows a "Free trial" badge and "Trial ends, then
  billing starts <date>" while a customer is mid-trial.
@RhysSullivan RhysSullivan force-pushed the feat/team-14day-trial branch from 820ac50 to 60d56ec Compare June 27, 2026 23:36
@RhysSullivan RhysSullivan merged commit e92d23e into main Jun 27, 2026
15 checks passed
@RhysSullivan RhysSullivan deleted the feat/team-14day-trial branch June 27, 2026 23:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant