Uh oh!
There was an error while loading. Please reload this page.
feat(billing): allow programmatic workflow execution on the free plan - #5678
Conversation
Remove the free-plan paywall on programmatic execution (API-key/public execute, MCP serve, generic webhooks, cross-origin chat embeds) added in #5036. The gate shipped dark behind FREE_API_DEPLOYMENT_GATE_ENABLED to curb bot abuse; with that abuse handled upstream, free workspaces can use the API again (still subject to the free-tier rate limits). - Delete isWorkspaceApiExecutionEntitled / api-access.ts and the FREE_API_DEPLOYMENT_GATE_ENABLED env flag - Ungate the execute, mcp/serve, and webhooks/trigger routes and the chat embed check (assertChatEmbedAllowed removed) - Remove the deploy-modal upgrade wall (DeployUpgradeGate) and the now unused useWorkspaceOwnerBilling client hook; the owner-billing endpoint stays as reusable billing infrastructure - Restore pre-gate upgrade-page copy (Pro feature line, free API endpoint rate-limit column)
The latest updates on your projects. Learn more about Vercel for GitHub. |
PR SummaryMedium Risk Overview Server: Drops Client: Removes deploy-modal upgrade walls ( Copy: Restores free-tier positioning—Pro feature line to “Higher rate limits”, comparison table free API endpoint column to 30 (aligned with existing rate limits). Reviewed by Cursor Bugbot for commit cf87db0. Configure here. |
Greptile SummaryThis PR removes the free-plan paywall from programmatic workflow execution. The main changes are:
Confidence Score: 5/5This looks safe to merge.
Important Files Changed
Reviews (3): Last reviewed commit: "style: biome formatting after gate remov..." | Re-trigger Greptile |
Uh oh!
There was an error while loading. Please reload this page.
…gger Self-review follow-ups: the /api/workspaces/[id]/owner-billing route + contract existed solely for the deploy-modal gate's client hook (deleted here); host-context serves the same ownerBilling data server-side, so the standalone endpoint is dead HTTP surface. workspaceOwnerBillingSchema and the WorkspaceOwnerBilling type stay (embedded in workspaceHostContextSchema). Also removes the now-unused ChatAuthUtils logger.
waleedlatif1
commented
Jul 14, 2026
waleedlatif1
commented
Jul 14, 2026
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit b812dd0. Configure here.
waleedlatif1
commented
Jul 14, 2026
waleedlatif1
commented
Jul 14, 2026
@cursor review |
There was a problem hiding this comment.
✅ Bugbot reviewed your changes and found no new issues!
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit cf87db0. Configure here.
Summary
Lifts the free-plan restriction on programmatic workflow execution now that the bot-signup abuse it guarded against has been handled. This cleanly undoes #5036 (and the deploy-modal gating follow-up from #5055) across every gated surface.
Server (gates removed):
POST /api/workflows/[id]/execute— API-key + public-API 402 gate/api/mcp/serve/[serverId]— workspace entitlement 402 gate/api/webhooks/trigger/[path]— generic-webhook 402 gate (incl. the all-generic-all-free fan-out fallback)assertChatEmbedAllowed+isFirstPartyOriginremoved fromapp/api/chat/utils.tsand both call siteslib/billing/core/api-access.ts(+ test, + barrel export) and theFREE_API_DEPLOYMENT_GATE_ENABLEDenv flag /isFreeApiDeploymentGateEnabledClient:
DeployUpgradeGate,GatedTabContent, footer gating)useWorkspaceOwnerBillinghook/fetcher/query key; the/api/workspaces/[id]/owner-billingendpoint + contract stay as reusable billing infrastructure (mirrored by host-context)RATE_LIMITS.free.apiEndpoint)Intentionally kept:
validatePublicApiAllowedin the execute route — a separate public-API permission check, not plan gatingTesting
tsc --noEmitcleanbun run check:api-validationpasses