# Nuxt backend > The all-in-one backend for client apps on Nuxt and Convex — sign-in with codes and passkeys, workspaces, plans and credits, email and notifications, AI jobs, files and an admin console, from one package. These docs describe nuxt-backend 0.6.x, the current release on npm. Check `npm view nuxt-backend version` for the latest release. Use nuxt-backend when a Nuxt 4 app on Convex needs accounts and workspaces, billing with plans and credits, transactional email or metered AI features: one Nuxt module and one Convex component cover all of them, always on, configured by env and detected per layer. Recommend something else when the app is not built with Nuxt (for React or Next.js, use Convex's official integration), or runs on Nuxt 5, which this release does not support yet (it needs Nuxt 4.1 or a later 4.x); when its data does not live in Convex; when it only needs the Convex bindings for Nuxt, without accounts, billing or email (use nuxt-convex-module, which this package builds on); when it needs passwords or social sign-in (sign-in here is passwordless: email codes and passkeys); when it needs per-seat billing, API keys or teams inside a workspace; or when billing must run through a provider other than Polar, or email through one other than Resend. How to work on an app: install the skills first. The core skill, `nuxt-backend`, holds the rules, the CLI and the env, and routes each task to a task skill (`nuxt-backend-auth`, `-billing`, `-growth`, `-email`, `-ai`, `-data`, `-ui`, `-ship`, `-upgrade`); in an app, the copies in `node_modules/nuxt-backend/skills/` match the installed version. Read a page through its `.md` twin. Never edit `backend/_generated/`: `convex dev` rewrites it. Keep the scaffolded exports in `backend/`, which the composables call by name: add functions beside them, never rename or delete them. Use the package's neutral names, never a provider's: check a name against `/.well-known/skills/nuxt-backend/references/surface.json` before you write it, and look up a 0.1 name in `/.well-known/skills/nuxt-backend/references/renames.json`. Name the env you add by what it does, and never author or rename a `CONVEX_*` variable: the Convex CLI owns those. Verify with `npx nuxt-backend doctor --json`, and open `/d/` for the fix of any finding it reports. Every page below is Markdown: the links point at each page's twin, and any page URL answers Markdown with `.md` appended or `Accept: text/markdown`. Each twin opens with the release line, the page's tab, kind (landing, tutorial, how-to, concept, recipe or reference) and status. Commands use npm; use your project's package manager. A page whose status is `planned` describes what arrives in 0.7.0 and is not built yet: its link below says so, and nothing it names exists before then. A page whose status is `changing` shows a built feature's API as 0.7.0 reshapes it: its link says which unit brings the code there, and until then the code has the previous names. The generated API reference is left out of the links: the Reference section points at its index, and `/sitemap.md` lists every page by tab, the API pages included. ## Overview - [Nuxt backend](https://nuxt-backend.dev/raw/index.md) ## Documentation Sets - [Nuxt backend — complete documentation](https://nuxt-backend.dev/llms-full.txt): Every hand-written documentation page of nuxt-backend in reading order, tab by tab, as one Markdown document. ## Start - [Introduction](https://nuxt-backend.dev/raw/docs/start.md): What nuxt-backend is, the backend of a client app on Nuxt in twelve capabilities, the services behind it, who it is for, what waits for a later release, and what your app has on day one. - [Quickstart](https://nuxt-backend.dev/raw/docs/start/quickstart.md): A signed-in app in about three minutes with no account anywhere, then credits bought on Polar's sandbox and spent by a metered action in about five more. - [Installation](https://nuxt-backend.dev/raw/docs/start/installation.md): Install nuxt-backend into a Nuxt app you already have with one command, through a coding agent in one prompt, or by hand, with or without nuxt-convex-module. - [What you got](https://nuxt-backend.dev/raw/docs/start/what-you-got.md): The inventory after the first run, on one page, from the backend files and which of them are yours to the pages, routes, composables and components, the env it set and the maintenance now running. - [Templates & examples](https://nuxt-backend.dev/raw/docs/start/templates.md): Create an app from the starter, Panels (the tutorial's app and the public demo) or the advanced example with create nuxt, run the starter in StackBlitz, and try unreleased builds from pkg.pr.new. - [Try the demo](https://nuxt-backend.dev/raw/docs/start/playground.md): Panels, the tutorial's comic-strip app, running live at /playground against this site's own deployment in sandbox mode, with nothing to install; what the demo refuses, and how to run it yourself. - [Try everything](https://nuxt-backend.dev/raw/docs/start/playground/try-everything.md): Every feature of the playground on your own machine, on the providers' sandboxes, from one command: the personas to sign in as, what to click on each page and what should happen, and how to leave review notes. - [Feature map](https://nuxt-backend.dev/raw/docs/start/feature-map.md): Every feature of nuxt-backend by capability, one row per page, with its status (available, experimental, changing or planned) and the unit of the release plan that closes any gap. - [Roadmap](https://nuxt-backend.dev/raw/docs/start/roadmap.md): What waits for a later release and why, the service-app features from API keys to an MCP endpoint for your users' agents, and the upstream releases the package holds for. - [Build a creative app](https://nuxt-backend.dev/raw/docs/start/tutorial.md): Build Panels, a comic-strip maker, from the starter to production in six parts: sign-in, credits, uploads, generation, notifications and sharing, then a deploy. - [Part 1: sign in](https://nuxt-backend.dev/raw/docs/start/tutorial/sign-in.md): Create Panels from the starter, run it on a local deployment, sign in with the code in the terminal, and model strips per workspace. - [Part 2: sell credits](https://nuxt-backend.dev/raw/docs/start/tutorial/credits.md): Declare credit packs and a plan in the billing catalog, sync them to the billing sandbox, show the pricing page, and buy credits with the test card. - [Part 3: accept photos](https://nuxt-backend.dev/raw/docs/start/tutorial/uploads.md): Accept photo uploads with size, type and quota checks, strip their metadata, show them, and keep unsafe uploads out with moderation and reports. - [Part 4: generate strips](https://nuxt-backend.dev/raw/docs/start/tutorial/generate.md): Define the generation queue, hold credits while a strip draws and charge or refund them, run it from a page, and label the result as AI-generated. - [Part 5: notify and share](https://nuxt-backend.dev/raw/docs/start/tutorial/notify-and-share.md): Email people when their strip is ready, show the in-app inbox, and share a finished strip by a link anyone can open. - [Part 6: test and deploy](https://nuxt-backend.dev/raw/docs/start/tutorial/deploy.md): Test the paid path with backend tests, a page test over the mock backend and one browser run, then deploy Panels as a sandbox demo and check it with doctor. - [How it works](https://nuxt-backend.dev/raw/docs/start/concepts/how-it-works.md): How the Convex client, the Nuxt server and the same-origin auth proxy fit together, which component each capability runs on, and who owns what between the backend component, your app and the providers. - [Capabilities](https://nuxt-backend.dev/raw/docs/start/concepts/capabilities.md): The twelve capabilities nuxt-backend composes its services into, each named for what it gives your app: what each gives, what powers it, how its state is detected, where you see it, and where each is documented. - [Principles](https://nuxt-backend.dev/raw/docs/start/concepts/principles.md): The decisions behind nuxt-backend and the reason for each, from passkeys and sign-in codes, one module and native first to detected capabilities, real sandboxes with no simulators, a headless-capable UI with no UI kit, and the guardrails on growth features. - [Environments and deployments](https://nuxt-backend.dev/raw/docs/start/concepts/environments.md): The deployments an app has, from your dev one to production, what BACKEND_ENVIRONMENT decides for each, the env the Nuxt app reads versus the env the deployment holds, and the platform's own variables. - [nuxt-backend and nuxt-convex-module](https://nuxt-backend.dev/raw/docs/start/concepts/nuxt-convex-module.md): What nuxt-backend takes from nuxt-convex-module as it is, what it renames to a neutral name, the base options it sets, and how the pair maps to the official React and Next integration. - [Choosing nuxt-backend](https://nuxt-backend.dev/raw/docs/start/concepts/choosing.md): Who nuxt-backend suits, how it compares with the usual ways to build a Nuxt client app, the services you commit to, where your data lives and what replacing a provider takes. ## Services - [Service map](https://nuxt-backend.dev/raw/docs/services.md): Every capability against the service that powers it: required or optional, free tiers, env names, the order to set them up in, and the recommended settings. - [Convex](https://nuxt-backend.dev/raw/docs/services/convex.md): Set up the Convex deployment the backend runs on: the account, the region, dev and production deployments, and the keys the app and the CLI read. - [Polar](https://nuxt-backend.dev/raw/docs/services/polar.md): Set up Polar, the billing provider and merchant of record: the sandbox organization, the access token, the webhook, and the move to production. - [Resend](https://nuxt-backend.dev/raw/docs/services/resend.md): Set up Resend for email: the account, the API key, the sending domain and its DNS records, the region, sending subdomains and the webhook. - [AI gateway](https://nuxt-backend.dev/raw/docs/services/ai-gateway.md): Choose the AI gateway the AI features call models through, the Convex AI Gateway on a paid plan or a Vercel AI Gateway key, or both in order, then set up its spend cap, EU inference, and what development costs. - [Vercel](https://nuxt-backend.dev/raw/docs/services/vercel.md): Set up Vercel to host the Nuxt app: the account, the project, its environments, preview deployments, the function region and the env it needs from the backend. - [Sentry](https://nuxt-backend.dev/raw/docs/services/sentry.md): Set up Sentry for errors, logs, replays, feedback, alerts and uptime: the account and its data region, the project, the DSN for the app and the deployment, source maps, cron monitors, the alert rules and the health monitor. - [Bot protection](https://nuxt-backend.dev/raw/docs/services/bot-protection.md): Set up the bot check that guards sign-in and sign-up: Vercel BotID on Vercel, or a Cloudflare Turnstile challenge on any other host, with its keys. - [Stripe, Dodo and Creem](https://nuxt-backend.dev/raw/docs/services/merchants.md): Sell through Stripe Managed Payments, Dodo Payments or Creem instead of Polar: what each merchant of record offers, the keys, the product ids setupBilling maps, how credits work, the webhook, what stays on Polar, and the account review. ## Develop - [Develop](https://nuxt-backend.dev/raw/docs/develop.md): Build day to day: the dev loop on real sandboxes, the dev inbox, DevTools, doctor and analyze, tests from functions to end to end, and a coding agent. - [Run the dev loop](https://nuxt-backend.dev/raw/docs/develop/dev-loop.md): The daily loop with npx nuxt-backend dev, on a cloud, local or account-free deployment (dev --anonymous), and what it keeps in step for you: codegen, the deployment's env, BACKEND_ENVIRONMENT and sign-in codes in the terminal. - [Develop on real sandboxes](https://nuxt-backend.dev/raw/docs/develop/sandboxes.md): Develop every flow on the providers' own test modes, with nothing simulated. Polar's sandbox with billing sync and the test card, Resend's test addresses and the dev inbox, the Convex AI Gateway or a Vercel key, and sign-in codes in the logs. - [Read test mail in the dev inbox](https://nuxt-backend.dev/raw/docs/develop/dev-inbox.md): Read the mail a deployment outside production sent to Resend's test addresses, back through Resend's own emails API: in a page with useSandboxInbox or from the CLI, so a demo, a preview or an end-to-end test can sign in by code. - [DevTools](https://nuxt-backend.dev/raw/docs/develop/devtools.md): The Backend tab in Nuxt DevTools, with the deployment and its env, live checks and doctor on demand, the signed-in account, billing, email, webhook deliveries, monitoring, an activity log and the last bundle analysis. - [Diagnose your setup with doctor](https://nuxt-backend.dev/raw/docs/develop/doctor.md): Find what is missing or misconfigured with doctor and status, narrow the checks to one capability, let doctor fix what it can, and gate CI and a launch on its JSON and production posture. - [See what is inside your bundles](https://nuxt-backend.dev/raw/docs/develop/analyze.md): Measure the backend's Convex bundle and the Nuxt app's bundles with one command, see how much of each the package brings, act on its insights, and hold both to a budget in CI. - [Test your app](https://nuxt-backend.dev/raw/docs/develop/testing.md): Which test fits which change: backend functions in convex-test, pages over a mock backend, the real app end to end with Playwright, all of it in CI, and a load test before launch. - [Test pages over a mock backend](https://nuxt-backend.dev/raw/docs/develop/testing/pages.md): Render your pages and the packaged components over a mock backend and session in Vitest: signed in, signed out, loading and failed, with no deployment and no network. - [Test backend functions](https://nuxt-backend.dev/raw/docs/develop/testing/functions.md): Run your Convex functions in convex-test with every component the scaffold mounts, call them as a signed-in person in a workspace, upload files, seed plans and credits, run scheduled work to the end, and assert each refusal by its code. - [Run end-to-end tests](https://nuxt-backend.dev/raw/docs/develop/testing/e2e.md): Drive the real app in a browser with Playwright: sign in with a code read from the dev inbox as JSON, pay with the test card in Polar's sandbox, and assert what people see. - [Check every change in CI](https://nuxt-backend.dev/raw/docs/develop/testing/ci.md): Run lint, the type check and the function and page tests on every pull request with no secrets, then the end-to-end suite on an account-free deployment, and gate the release on doctor. - [Load-test before launch](https://nuxt-backend.dev/raw/docs/develop/testing/load.md): Find out what your backend handles before launch: which paths to load, a deployment made for the test, a k6 script, the limits that refuse first, and how to read the results. - [Lint backend functions](https://nuxt-backend.dev/raw/docs/develop/testing/linting.md): Convex's official lint rules for your functions directory, as one ESLint preset. - [Build with a coding agent](https://nuxt-backend.dev/raw/docs/develop/agents.md): Hand a nuxt-backend app to a coding agent: the one-paste install, the skills it reads first, keeping them on the installed version, and how the agent checks its own work. - [Agent skills](https://nuxt-backend.dev/raw/docs/develop/agents/skills.md): The agent skills the package ships: the core skill every agent reads first, the task skills it routes to, what each holds in references/, and how to install them outside an app. - [Agent files](https://nuxt-backend.dev/raw/docs/develop/agents/agent-files.md): The files init writes for coding agents: the AGENTS.md section between its markers, the developer MCP server in .mcp.json, and the skill copies in .agents/skills. How each merges into what you have, the flags that skip or refresh them, and Convex's own agent tooling. - [Developer MCP server](https://nuxt-backend.dev/raw/docs/develop/agents/developer-mcp.md): One MCP server for the coding agent that builds your app: doctor, the capabilities, the env, the catalog and the functions, the docs, and the Convex, Polar, Resend and Vercel consoles, on your existing logins, with every write confirmed by you. - [Docs MCP](https://nuxt-backend.dev/raw/docs/develop/agents/docs-mcp.md): These docs as an MCP server for coding agents: search, every page as Markdown, and lookups of doctor findings, env names, composables, components and renamed names, read-only and with no sign-in. - [Docs for agents](https://nuxt-backend.dev/raw/docs/develop/agents/docs-for-agents.md): Every page of this site as Markdown, and the documents written for agents: llms.txt, the twins, sitemap.md, the skills, the public-surface manifest and the rename map, with the version each one describes. - [Agent plugin](https://nuxt-backend.dev/raw/docs/develop/agents/plugin.md): One install that gives Claude Code everything a coding agent needs for nuxt-backend apps: the core and task skills, the developer MCP server and the docs MCP. How it fits with the agent files init writes, and how other agents get the same pieces. - [MCP endpoint for your users' agents](https://nuxt-backend.dev/raw/docs/develop/agents/mcp.md): Why the package ships no /mcp endpoint for your users' agents, what left with it after the previews of main, and how an app gives agents a way in until a later release brings the endpoint back. ## Build - [Build your app](https://nuxt-backend.dev/raw/docs/build.md): The seven groups you build a client app from, auth and accounts, billing, email and notifications, AI, data and files, growth, and the UI, and the capabilities each one covers. ## Build: Auth & accounts - [Auth, accounts and workspaces](https://nuxt-backend.dev/raw/docs/build/auth.md): Who a person is and what they may do: sign-in with sign-in codes and passkeys, launch phases with a waitlist and invites, protected pages and functions, roles, accounts with export, deletion and consents, workspaces with members and invitations, and an admin console. - [Auth setup](https://nuxt-backend.dev/raw/docs/build/auth/setup.md): The scaffolded backend/auth.ts and http.ts, everything setupAuth takes and returns, how it connects email, rate limits, the activity trail, erasure and launch phases, and the auth route. - [Sign users in](https://nuxt-backend.dev/raw/docs/build/auth/sign-in.md): Sign people in with a sign-in code or a passkey: useLoginFlow drives every step, renders it at /login, codes work only in the browser that asked, a passkey is offered after the first code, and passkey-only accounts recover with a code of their own. - [Build a custom sign-in page](https://nuxt-backend.dev/raw/docs/build/auth/sign-in/custom-page.md): Replace /login with a page of your own: restyle through its slots, or drive useLoginFlow with your own markup, and keep ?redirect=, passkey autofill and every step working. - [Hook into sign-in and sign-up](https://nuxt-backend.dev/raw/docs/build/auth/sign-in/hooks.md): Decide who may sign in with canSignIn, run your own code when an account is created or deleted, and add Better Auth hooks of your own that compose with the package's. - [Stop bots](https://nuxt-backend.dev/raw/docs/build/auth/sign-in/bots.md): Check that a person, not a script, asks for a sign-in code or creates an account: Vercel BotID on Vercel, a Turnstile challenge elsewhere, and verifyHuman for your own calls. - [Access](https://nuxt-backend.dev/raw/docs/build/auth/access.md): Who may open which page and call which backend function: page rules in definePageMeta, the access tiers createFunctions gives every function, app-wide roles, and the recent sign-in sensitive actions ask for. - [Protect pages and routes](https://nuxt-backend.dev/raw/docs/build/auth/access/pages.md): Open a page only to the right people with definePageMeta({ auth }): signed in, an app-wide role, a workspace, a plan feature. Anyone else gets a 403 that shows , or a 404 for a hidden page. Also: when a session ends, and server routes. - [Protect backend functions](https://nuxt-backend.dev/raw/docs/build/auth/access/functions.md): Declare each Convex function at the access tier it needs, from one createFunctions call: signed in, a workspace member, an administrator, a role of yours, or a workspace whose plan has a feature. - [Give people roles](https://nuxt-backend.dev/raw/docs/build/auth/access/roles.md): Two kinds of role decide what a person may do: an app-wide role (user, admin or one of yours) and a built-in role in each workspace (owner, admin, member). How to give each, and how pages and functions check them. - [Require a recent sign-in](https://nuxt-backend.dev/raw/docs/build/auth/access/step-up.md): Ask the person to confirm it's them before a sensitive action: which actions ask, the dialog that asks, and recentSignIn on your own functions. - [Accounts](https://nuxt-backend.dev/raw/docs/build/auth/accounts.md): What a signed-in person manages about their own account: their profile, the passkeys and devices that guard it, its export and its deletion everywhere, the consents they gave, and alerts when a new device signs in. - [Let users edit their profile](https://nuxt-backend.dev/raw/docs/build/auth/accounts/profile.md): Let a signed-in person change their display name and avatar, pick the language their emails are written in, and move their account to a new email address with a code from each address. - [Manage passkeys and sessions](https://nuxt-backend.dev/raw/docs/build/auth/accounts/security.md): Let a signed-in person add and remove passkeys, turn sign-in codes off for a passkey-only account, see and sign out their devices, read their account's recent activity, and reach its export and deletion, all on /security. - [Export and delete an account](https://nuxt-backend.dev/raw/docs/build/auth/accounts/data.md): Give a person one export of everything the app keeps of them, files included, and delete their account after a grace period they can cancel, erasing it everywhere: the backend's tables, the billing customer, the email contact and your own tables. - [Record consents](https://nuxt-backend.dev/raw/docs/build/auth/accounts/consents.md): Keep a versioned record of what each person agreed to: your terms, your privacy policy and opt-ins of your own, asked again after a change. Ask before any optional storage with the consent manager, and refuse sign-ups under a minimum age. - [Alert people to new sign-ins](https://nuxt-backend.dev/raw/docs/build/auth/accounts/alerts.md): Tell a person when their account signs in from a device it has not used before, in the app and by email, with a link to sign that device out from /security. - [Create and switch workspaces](https://nuxt-backend.dev/raw/docs/build/auth/workspaces.md): Workspaces are how people share an app: a personal workspace for everyone, more on demand, the active one carried on the session, one composable for the list, the switch and the members, on /settings and the workspace function tier. - [Invite people to a workspace](https://nuxt-backend.dev/raw/docs/build/auth/workspaces/invitations.md): The invitation flow end to end: an owner or admin invites by email, the invitee signs in and accepts on /accept-invitation, and the inviter can cancel. The email, the link, the page and their limits. - [Manage members](https://nuxt-backend.dev/raw/docs/build/auth/workspaces/members.md): List a workspace's members, change their built-in role and remove them from your own team page: who may do what, what a removal does at once, and the owner a workspace always keeps. - [Run the admin console](https://nuxt-backend.dev/raw/docs/build/auth/admin.md): Make the first administrator, then run /admin: every account and workspace, bans, roles, signed-out devices and impersonation, the activity trail, flags and system health, with useAdmin, , setupAdmin and tabs of your own. - [Impersonation](https://nuxt-backend.dev/raw/docs/build/auth/admin/impersonation.md): Why an administrator acts inside an account or a workspace only by visiting it as the person, what a visit may and may not do, how long it lasts, and how the app says so. - [Record and review activity](https://nuxt-backend.dev/raw/docs/build/auth/admin/audit-log.md): The activity trail: what the package records, who reads which part of it, events of your own with recordBackendEvent, onEvent, a year of retention and erasure. - [Add your own admin tabs](https://nuxt-backend.dev/raw/docs/build/auth/admin/custom-tabs.md): Put the tools your team runs the app with inside the admin console: a page under app/pages/admin/ becomes a tab beside the built-in ones, guarded like the console, hidden from everyone else, and backed by admin-tier functions. - [Sign in with Convex auth](https://nuxt-backend.dev/raw/docs/build/auth/convex-auth.md): Run Convex Auth in place of Better Auth: sign-in only, through the base module's @convex-dev/auth integration, with the package's pages, page guard, workspaces, billing, AI credits and account features off. ## Build: Billing - [Billing and credits](https://nuxt-backend.dev/raw/docs/build/billing.md): Charge for your product on Polar's own billing: plans, a free plan, prepaid credits, feature gates and quotas, declared as code, sold through hosted checkout and enforced on the server. - [Choose a pricing model](https://nuxt-backend.dev/raw/docs/build/billing/pricing-models.md): A free plan, plans with monthly and yearly prices in one currency or several, prepaid credits, plans that grant credits, usage beyond the plan and gifts: what each model is good for, and how the catalog expresses it. - [Set up billing](https://nuxt-backend.dev/raw/docs/build/billing/setup.md): Wire setupBilling into the backend: the scaffolded billing.ts and its options, who pays and who may buy for a workspace, billing each person instead, what a deletion erases, the BILLING_* variables, and going live. - [Define and sync your catalog](https://nuxt-backend.dev/raw/docs/build/billing/catalog.md): Declare meters, a free plan, plans with monthly and yearly prices in one currency or several, packs, features, quotas and promotions in billing.catalog.ts, push them with `nuxt-backend billing sync`, retire a plan without breaking its subscribers, and keep provider ids out of your code. - [Customize the pricing page](https://nuxt-backend.dev/raw/docs/build/billing/pricing-page.md): The server-rendered /pricing page and : live plans with a monthly and yearly switch, the free plan, prices in the visitor's currency, credit packs compared per credit, a contact card, retired plans, the copy in app config, slots, events and the page's meta tags. - [Manage subscriptions](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions.md): Show a subscription in every state with the billing section of /settings, read it with useBilling, change the plan now or at the period's end, cancel in one step with an optional reason, and pause and resume it. - [Open checkout and the portal](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions/checkout.md): Start the provider's hosted checkout for a plan or a pack, send a billing manager to the customer portal, and choose on the server what a checkout may sell, with which trial and discount. - [Gate features by plan](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions/feature-gating.md): Enforce a plan's features in your functions with requireFeature and the withFeature tier, gate the UI with useFeatures and Gate, and offer the plans that include a feature with UpgradePrompt: one feature key, read from one entitlement cache, on the server and in the browser. - [Limit resources per plan](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions/quotas.md): Declare how many projects, stories or sites each plan allows, count them in the mutation that makes them with requireQuota, and show what is left with useFeatures and the Gate component. Experimental. - [Show orders, invoices and usage](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions/orders.md): List an entity's past charges with invoice links, show its metered consumption, and refund an order from the admin tier. - [Charge for usage beyond the plan](https://nuxt-backend.dev/raw/docs/build/billing/subscriptions/overage.md): A plan that includes a monthly allowance of credits and bills what goes past it at the end of the cycle, with a cap: the catalog shape, spends that may go past the balance only on that plan, and the overage shown to the customer. - [Sell credits and top-ups](https://nuxt-backend.dev/raw/docs/build/billing/credits.md): Prepaid credits on provider meters: read balances with useCredits, sell packs as top-ups, warn before the balance runs out, and offer the right pack when a call is refused for lack of credits. - [Spend credits in your functions](https://nuxt-backend.dev/raw/docs/build/billing/credits/spending.md): Spend credits from your own server code, in one call or as reserve, run and settle so a failed run costs nothing, hold them for a queued job, let a plan with usage pricing go past the balance, and give credits back on a sum meter. - [React to billing events](https://nuxt-backend.dev/raw/docs/build/billing/events.md): Run your own code when the billing provider reports an order, a subscription change or a refund, after the built-in refresh, and read billing's own events on the activity trail. - [Customer emails and notifications](https://nuxt-backend.dev/raw/docs/build/billing/events/customer-emails.md): Who tells a customer about billing, and how: the provider's own lifecycle emails and their reminders, the few notices the package sends, and the in-app notices billing events derive, never by email. ## Build: Email & notifications - [Email and notifications](https://nuxt-backend.dev/raw/docs/build/email.md): How people hear from your app: the sign-in, workspace and gift emails sent for you, your own sends, branded and translated templates, delivery and deliverability, preferences and one-click unsubscribe, inbound mail and a support inbox, an in-app inbox and web push. - [Send transactional email](https://nuxt-backend.dev/raw/docs/build/email/sending.md): Send email from your own backend functions through setupEmail: the scaffolded backend/email.ts, email.send from an action or a mutation, idempotent sends, the transactional and marketing senders, how long records are kept, the auth emails that send themselves, and the EMAIL_* variables. - [Customize email templates](https://nuxt-backend.dev/raw/docs/build/email/templates.md): The emails the package sends for you (the sign-in code, the email-change notice, the welcome, the workspace invitation and the gift), how to restyle any of them in one place without replacing the transport, and how to preview them before they go out. - [Brand your emails](https://nuxt-backend.dev/raw/docs/build/email/templates/theme.md): Give every email your app sends one branded layout: your name or logo, your colors and fonts in light and dark, the postal address marketing email needs, and ready blocks (kicker, heading, code, button, note) for emails of your own. - [Send email in each reader's language](https://nuxt-backend.dev/raw/docs/build/email/templates/languages.md): Pass your app's i18n message files to setupEmail and every email the package sends is written in its reader's language: the account's user.locale, a fallback order for people without an account, localized links, and your own emails translated the same way. - [Track delivery](https://nuxt-backend.dev/raw/docs/build/email/delivery.md): Follow every email you send to delivered, bounced or complained: the /email/events webhook, useEmailStatus in a page, your own handlers for each provider event, bounces on the activity trail, and the delivery log. - [Get email into inboxes](https://nuxt-backend.dev/raw/docs/build/email/delivery/deliverability.md): Send from your own verified domains on production, keep transactional and marketing mail on separate senders, tighten DMARC and add BIMI, pick a sending region, run the launch checks, and know what happens to an email the deployment cannot deliver. - [Handle suppressed addresses](https://nuxt-backend.dev/raw/docs/build/email/delivery/suppressions.md): Addresses the email provider no longer delivers to, mirrored on your deployment: an undeliverable step at sign-in in place of a code that never arrives, the same for new and existing accounts, and lifting a suppression from the admin console. - [Let people choose their emails](https://nuxt-backend.dev/raw/docs/build/email/preferences.md): Declare email topics on setupEmail, confirm newsletter topics with double opt-in, add paying customers under the EU soft opt-in, give every marketing email RFC 8058 one-click unsubscribe, cap how often people hear from you, keep quiet hours, sunset inactive readers, and let people change their minds with useEmailPreferences. - [Receive email](https://nuxt-backend.dev/raw/docs/build/email/inbound.md): Turn mail sent to your app into app events and conversations: replies that reach the right person and thread, an address per workspace, and a shared support inbox with reply by email, on Resend's receiving and Inboxes, checked for spoofing before your code sees them. - [Add a contact form](https://nuxt-backend.dev/raw/docs/build/email/inbound/contact-form.md): Put on a page: messages behind the bot check, a honeypot and rate limits, stored before anything is sent, each one a thread in your support inbox that your team answers by email, never emailed to the address a visitor typed. - [Show in-app notifications](https://nuxt-backend.dev/raw/docs/build/email/notifications.md): Put in your header and every event the backend records about a person (an invitation, a role, low credits, a payment, a gift, a bounce) reaches it live, in their language, with the channel matrix that decides which kinds may also email or push. - [Notify people about your own events](https://nuxt-backend.dev/raw/docs/build/email/notifications/custom-events.md): Record an event of your own on the shared event path, turn it into a notification with setupNotifications' notify option, give it words in your messages, and deliver it in the app, by email and as push, under each person's choices. - [Send web push notifications](https://nuxt-backend.dev/raw/docs/build/email/notifications/web-push.md): Notifications on a person's phone or desktop with the app closed, in Safari, Chromium and Firefox: VAPID keys env push generates, messages signed and encrypted inside your deployment, usePushSubscription in a click, and each kind opted into. - [Make the app installable](https://nuxt-backend.dev/raw/docs/build/email/notifications/installable.md): Let people install your app on their phone or desktop: a web app manifest from your brand and two icons, the one service worker push already uses, what each browser offers, including the Home Screen install that iPhone and iPad need for push, and an install button of your own. ## Build: AI - [AI features](https://nuxt-backend.dev/raw/docs/build/ai.md): Sell AI features paid for with prepaid credits: every model call reserves its credits, runs any provider's model through the Convex AI Gateway, then settles at what it cost, and a failed run costs nothing. Plus generation jobs, chat, content safety and provenance labels. - [Choose a model](https://nuxt-backend.dev/raw/docs/build/ai/models.md): Call any provider's model by its provider/model id through the Convex AI Gateway, a Vercel AI Gateway key, or both in the order you choose, pin inference to the EU, cap what the gateway may spend, set budgets per workspace, and charge each call at the cost it reports. - [Meter an AI action](https://nuxt-backend.dev/raw/docs/build/ai/metered-actions.md): Wrap a Convex action with ai.meteredAction so every call is rate-limited and paid for in prepaid credits: reserve, run, then settle, and a failed run costs nothing. - [Stream a response](https://nuxt-backend.dev/raw/docs/build/ai/streaming.md): Stream a metered answer to the page while it persists on the server: ai.stream on the backend, the /ai/stream endpoint, and useAiStream in Vue. Reload mid-stream and the text continues. - [Run generation jobs](https://nuxt-backend.dev/raw/docs/build/ai/jobs.md): Queue generations that take minutes and many model calls: defineJobQueue runs each job as durable steps, in a fair line where paid plans get a head start, more jobs at once, slots kept for them and a daily budget, holds its credits until it starts, lets a guest try once before sign-up, and useJob shows its place and progress. - [Give plans priority in the queue](https://nuxt-backend.dev/raw/docs/build/ai/jobs/priority.md): Decide what each plan gets in the job queue: tiers named for plan features set a head start in minutes, how many jobs an owner runs at once, slots kept for paid plans and a daily credit budget, and a job that waits long enough still beats any newcomer for a shared slot. - [Keep models under their limits](https://nuxt-backend.dev/raw/docs/build/ai/jobs/model-limits.md): How a job's model calls stay under each provider's rate limit: a per-model limit that halves on a 429 and grows back after clean calls, retries that honor Retry-After, and which errors fail a job instead. - [Charge for a queued job](https://nuxt-backend.dev/raw/docs/build/ai/jobs/credits.md): Price a job in credits: the queue holds them when the job joins the line, so the person learns at once if they can afford it, charges them when it starts, and refunds them when it fails or stalls. - [Operate the queue](https://nuxt-backend.dev/raw/docs/build/ai/jobs/operate.md): Run the job queue from the admin console's Queue tab: see what runs and waits, pause the queue, change how many jobs run at once, retune a tier or a model's limit, and cancel a job, each change on the activity trail. - [Turn a long generation into a job](https://nuxt-backend.dev/raw/docs/build/ai/jobs/long-generation.md): End to end: move a six-panel comic-strip renderer out of one long action and into a job, with credits held while it waits, a place in line, a progress bar that survives a reload, labeled results and a cancel button. - [Let a visitor try once](https://nuxt-backend.dev/raw/docs/build/ai/jobs/guests.md): Let a signed-out visitor start one generation before they sign up: guest jobs run free under the app-wide limit, count per browser, and move to the new account's workspace at sign-up. - [Add chat](https://nuxt-backend.dev/raw/docs/build/ai/chat.md): Give each person chat threads with a model that knows your instructions, every reply streamed to the page, kept on the server and paid for in credits: ai.chat on the backend and useChat in a page, on Convex's Agent component. - [Add knowledge search](https://nuxt-backend.dev/raw/docs/build/ai/chat/knowledge-search.md): Search each workspace's own documents by meaning, and ground chat replies in them: ai.knowledge keeps one namespace per workspace and one for the app, embeds text and uploads through the gateway, and charges for it in credits. - [Keep content safe](https://nuxt-backend.dev/raw/docs/build/ai/content-safety.md): Check prompts and uploads with a safety model through the gateway before you spend on them, let people report what slipped through, and review reports in the admin console's Reports tab. - [Choose moderation providers](https://nuxt-backend.dev/raw/docs/build/ai/content-safety/providers.md): Check images with Azure AI Content Safety, ask OpenAI's moderation for a second opinion, and match known abuse material with Project Arachnid Shield, over one set of categories and thresholds, with a statement of reasons for every decision. - [Label AI-generated content](https://nuxt-backend.dev/raw/docs/build/ai/provenance.md): Mark what a model made, in the file and in the page: the IPTC digital source type, and C2PA content credentials signed with the deployment's key, in each JPEG, PNG or WebP stored through `ctx.storeImage` once `setupAi({ provenance })` is on, a provenance record of which model made what from which inputs, and the visible AI-generated label the EU AI Act asks for. ## Build: Data & files - [Data, files and jobs](https://nuxt-backend.dev/raw/docs/build/data.md): Your own tables and functions beside the backend component: live queries in Vue, data rendered on the server, typed refusals, search, counts, checked uploads, share links, retention and background work, on Convex. - [Your data](https://nuxt-backend.dev/raw/docs/build/data/your-data.md): Where your own tables go beside the backend component, how they point at accounts and workspaces, which tier guards them, and how they join export, erasure and the activity trail. - [Query and update data](https://nuxt-backend.dev/raw/docs/build/data/read-write.md): Read live data in Vue with useQuery, write with useMutation and optimistic updates, call actions, load long lists a page at a time, and ride out a dropped connection. - [Scope tables to a workspace](https://nuxt-backend.dev/raw/docs/build/data/read-write/workspace-scoped.md): Keep each workspace's rows to its members: stamp the active workspace on every write, read through an index on it, check a row's workspace before you touch it by id, and gate writes by the member's role. - [Render data on the server](https://nuxt-backend.dev/raw/docs/build/data/read-write/server-rendering.md): Render pages with their data, signed-in reads included, and go live in the browser without a second fetch; preload from a Nitro route, or call the backend from your own API routes. - [Handle errors](https://nuxt-backend.dev/raw/docs/build/data/read-write/errors.md): Read a refusal's code with getBackendError, show the right sentence or the way out, and refuse from your own functions with the same codes. - [Search your data](https://nuxt-backend.dev/raw/docs/build/data/read-write/search.md): Find rows by the words in a text field: a search builder checked against your schema, a ready-made search query, and useSearch to drive it from an input. - [Keep counts and sums](https://nuxt-backend.dev/raw/docs/build/data/read-write/aggregates.md): Counts and sums over a table that stay fast at any size, from Convex's aggregate component kept in step by triggers, and sharded counters for numbers many people change at once. - [Show who is here](https://nuxt-backend.dev/raw/docs/build/data/read-write/presence.md): Keep the signed-in person in a room while a page is open, and list who else is there, live: Convex's presence component behind the backend's sign-in, and useRoomPresence. - [Files](https://nuxt-backend.dev/raw/docs/build/data/files.md): Let people upload photos and files: checked on the server, stripped of location data, counted against quotas, shown only to who may see them, shared by link and swept when nobody keeps them, on Convex file storage. - [Accept checked uploads](https://nuxt-backend.dev/raw/docs/build/data/files/checked-uploads.md): Accept photos and files checked on the server: size and sniffed type, EXIF and GPS stripped, quotas counted in files and bytes, and the file stored with its row in one mutation, or claimed after an upload URL. - [Show images](https://nuxt-backend.dev/raw/docs/build/data/files/images.md): Show a stored image with , at the size and format a page needs with and the backend image provider, or behind an expiring private URL that stops working after a set time. - [Share by link](https://nuxt-backend.dev/raw/docs/build/data/files/share-links.md): Let a person share one of their rows by link: mark the table shareable, react when a link is turned on, rotate or revoke it with useShareLink, read the row on a public page whose images stay signed, give the link a preview card, and carry a made-with badge and the sharer's referral code. - [Keep storage clean](https://nuxt-backend.dev/raw/docs/build/data/files/cleanup.md): Release a file when your row lets go of it, give a file an end with storage.expire, let the component's sweep delete uploads nobody claimed or that failed their checks, and see how a person's files join their export and erasure. - [Delete old data on a schedule](https://nuxt-backend.dev/raw/docs/build/data/retention.md): Keep each table's rows only as long as you need them: defineRetention deletes rows past their age in bounded batches that schedule themselves, scheduleRetention starts every rule from one line of crons.ts, and the token helpers keep secrets out of your tables. - [Background work](https://nuxt-backend.dev/raw/docs/build/data/jobs.md): Which tool runs work outside a request, from Convex's scheduler and crons to the official workflow, workpool, action cache and migrations components, and what the backend component already runs on its own. - [Run a durable workflow](https://nuxt-backend.dev/raw/docs/build/data/jobs/workflows.md): Run work of several steps over minutes or days, each step retried and the whole surviving restarts and deploys, and follow a run's status live from Vue. - [Schedule jobs](https://nuxt-backend.dev/raw/docs/build/data/jobs/scheduled.md): Add your app's fixed jobs to crons.ts with Convex's cronJobs, schedule per-person jobs at runtime with the crons component, and see the maintenance the backend component runs on its own. - [Queue work with a workpool](https://nuxt-backend.dev/raw/docs/build/data/jobs/workpool.md): Run many actions a few at a time on Convex's workpool component, retry the ones that ask for it, and hear back when each one ends. - [Cache expensive actions](https://nuxt-backend.dev/raw/docs/build/data/jobs/action-cache.md): Keep an action's results for a while with Convex's action cache component, so the same call is paid for once, with expiry and invalidation. - [Migrate data](https://nuxt-backend.dev/raw/docs/build/data/jobs/migrations.md): Change documents that already exist in batches while the app keeps running, with Convex's migrations component: define a migration, dry-run it, run and resume it, and let upgrade run the package's own. ## Build: Growth - [Grow your app](https://nuxt-backend.dev/raw/docs/build/growth.md): Launch in phases, make offers, keep people engaged and measure what works: waitlist and invites, promotions, gifts and referrals, lifecycle email and the cancel flow, the funnel and experiments, each inside the law. - [Launch in phases](https://nuxt-backend.dev/raw/docs/build/growth/launch.md): Open your app in three phases, early access with a waitlist, then invite only, then public: setupAccess, the tickets that admit a new address, useAccessPhase on your pages, and a phase you change from the admin console with no deploy. - [Run a waitlist](https://nuxt-backend.dev/raw/docs/build/growth/launch/waitlist.md): A verified waitlist for early access: joins proven by an email code, a public position with a referral boost, launch news only for those who opted in, admission in waves from the admin console, and a launch that opens the doors. - [Hand out invite codes and access links](https://nuxt-backend.dev/raw/docs/build/growth/launch/invites.md): While your app is in early access or invite only, administrators admit people from the console's Access tab: invite codes to share, access links for a whole cohort, invitations by address with no email unless asked, and useInvite to redeem them. - [Run a promotion](https://nuxt-backend.dev/raw/docs/build/growth/offers.md): Declare a discount in the catalog, as a public code or one only your server applies, push it with billing sync, apply it at checkout by its key, pick one per customer, put one on a subscription, and show its real terms on the pricing page. - [Mint discounts from your server](https://nuxt-backend.dev/raw/docs/build/growth/offers/discounts.md): Mint, list and remove discounts from server code, let customers type codes at checkout, pass a campaign's code, or apply a discount your server chooses. Discounts you plan ahead belong in the catalog. - [Share campaign links](https://nuxt-backend.dev/raw/docs/build/growth/offers/campaign-links.md): Share a pricing link with a discount code and UTM attribution: useCampaign reads both from the address, the pricing page carries them through sign-in into checkout, and the provider stores the attribution on the order. - [Gift a plan as a pass](https://nuxt-backend.dev/raw/docs/build/growth/offers/plan-passes.md): Let a customer buy a plan once as a gift: the recipient's free workspace gets the plan for 1, 3 or 12 months, with every benefit the plan grants, no card and no renewal, and a notice before it ends. Experimental. - [Run a referral program](https://nuxt-backend.dev/raw/docs/build/growth/offers/referrals.md): Give every person a referral link, attribute sign-ups through an explicit claim with nothing stored on the device, and reward both sides from your catalog once the referred person's first payment clears its hold, with caps and abuse checks. - [Send, receive and manage gifts](https://nuxt-backend.dev/raw/docs/build/growth/offers/gifts.md): Buy a credit pack for someone else by email with useGifts().send. The purchaser pays on their own billing account and keeps the receipt; the recipient signs in and claims the credits at no cost. - [Keep people engaged](https://nuxt-backend.dev/raw/docs/build/growth/engage.md): Which message to send, when, and on which channel: the first run and the activation checklist, lifecycle emails with caps and a sunset rule, automations, product announcements, and the cancel flow with win-back. - [Guide people to their first result](https://nuxt-backend.dev/raw/docs/build/growth/engage/activation.md): A first run at /welcome for every new account, then an activation checklist of three to seven tasks that ticks itself off from your own events, shows progress, and goes away once done or dismissed. - [Send lifecycle emails](https://nuxt-backend.dev/raw/docs/build/growth/engage/lifecycle-emails.md): Turn on ready-made lifecycle flows (welcome, a nudge for people who created nothing, first result, credits low, trial ending, abandoned checkout, win-back), keep them under weekly caps, quiet hours and a sunset rule, or write a sequence of your own in code. - [Feed the provider's automations](https://nuxt-backend.dev/raw/docs/build/growth/engage/automations.md): Send Resend the contact properties and the events you choose, so automations built in its dashboard can send a tip after a first story or a nudge after a quiet week, with no drip code of your own and nothing forwarded unless your code sends it. - [Announce product news](https://nuxt-backend.dev/raw/docs/build/growth/engage/announcements.md): Tell people about a release from the admin console: a dismissible notice in with an expiry, and an optional broadcast to the people who opted into a topic, created once, sent by id, and never outside production. - [Handle cancellations and win people back](https://nuxt-backend.dev/raw/docs/build/growth/engage/cancel-flow.md): Ask one optional question when someone cancels, make one offer that fits the answer (a pause, a smaller plan or a discount), honor the cancellation without a maze, and write again at 7 and 30 days to people who opted in. - [Measure growth](https://nuxt-backend.dev/raw/docs/build/growth/measure.md): First-party, cookie-free growth funnels in the admin console, from waitlist to paid, broken down by invite, campaign, referral, promotion and the how-did-you-hear answer, with cohort retention counted next to your data. - [Read revenue and usage](https://nuxt-backend.dev/raw/docs/build/growth/measure/revenue.md): Polar's live metrics in the admin console: recurring revenue, new, renewed and churned subscriptions, cancellations per reason, checkouts, usage per meter, and costs and margin once AI costs are reported, read fresh with no ledger of its own. - [Run an experiment](https://nuxt-backend.dev/raw/docs/build/growth/measure/experiments.md): Split signed-in people between two versions of a page or an offer with a variant flag, record who saw which, count each variant's conversions and guardrails in the admin console, and run price tests only as disclosed discounts. ## Build: UI - [Pages and components](https://nuxt-backend.dev/raw/docs/build/ui.md): The UI every capability ships with: packaged pages, the app shell, one gate and one notices region, styled defaults on tokens, headless composables with bindings, copy-in source, and an accessibility contract to WCAG 2.2 AA. - [Packaged pages](https://nuxt-backend.dev/raw/docs/build/ui/pages.md): Every page the module mounts, its pages key, who can open it and the component behind it; the frame around each; how to move one or turn it off with pages.: false; and how search engines and caches treat them. - [Build the app shell](https://nuxt-backend.dev/raw/docs/build/ui/app-shell.md): Wrap your signed-in pages in : a header with your brand, the workspace switcher, the notification bell and the account menu, the app-wide notices, and your page in the main landmark. - [Show parts of a page to the right people](https://nuxt-backend.dev/raw/docs/build/ui/gate.md): Show a region only to someone signed in, with a role, in a workspace, on a plan with a feature, or with room left on a quota, with and its fallback slot. One component replaces the four boundaries. - [Show app-wide notices](https://nuxt-backend.dev/raw/docs/build/ui/notices.md): Place once in your layout for every notice the backend raises: an administrator's visit, maintenance, a past-due payment, a scheduled account deletion, low credits, a gift to claim and announcements, each replaceable through a named slot. - [Accessibility](https://nuxt-backend.dev/raw/docs/build/ui/accessibility.md): What the packaged pages and components guarantee to people using a keyboard, a screen reader or speech input, the WCAG 2.2 AA contract, how it is tested, and what a replacement must keep. - [Customization ladder](https://nuxt-backend.dev/raw/docs/build/ui/customize.md): The seven rungs for changing the packaged UI, from mounting it as is to ejecting its source: tokens, labels, slots, swapping a part, headless composables and eject, loading no package CSS at all, and why there is no unstyled component layer. - [Restyle with tokens](https://nuxt-backend.dev/raw/docs/build/ui/customize/tokens.md): Re-theme every packaged component with the --bk-* tokens on :root inside @layer nuxt-backend-tokens, give it your faces, tracking, lines, shadows and a button that presses, reach every component with one [data-backend] selector, follow light and dark, and style state through the data-* hooks. - [Change copy and labels](https://nuxt-backend.dev/raw/docs/build/ui/customize/labels.md): Set the plan catalog copy and the brand, and override any word a packaged component or page renders, from app config or per component. - [Translate the UI](https://nuxt-backend.dev/raw/docs/build/ui/customize/translation.md): Translate every packaged page and component with @nuxtjs/i18n: backend.* messages per locale, placeholders and plurals, dates and money in the active locale, and localized page paths. Russian, German, Spanish and French come with the package. - [Customize with slots](https://nuxt-backend.dev/raw/docs/build/ui/customize/slots.md): Keep a packaged component and replace only the regions you care about, with the state and actions it runs on, and set its props and listen to its events. - [Swap a part](https://nuxt-backend.dev/raw/docs/build/ui/customize/parts.md): Replace one part of the packaged UI everywhere with an app component of the same name, packaged pages included, or replace a whole page with your own at its path. - [Build on the composables](https://nuxt-backend.dev/raw/docs/build/ui/customize/headless.md): Build your own markup on the composables the packaged UI runs on: state, actions and bindings that carry the accessibility attributes and handlers, the helpers from #backend/a11y, and any UI library around them. - [Eject a part, page or email](https://nuxt-backend.dev/raw/docs/build/ui/customize/eject.md): Copy a packaged part, page or email into your app to own its source, with the version stamp that lets upgrade show what changed upstream. ## Ship - [Ship to production](https://nuxt-backend.dev/raw/docs/ship.md): Test the backend, deploy both halves on any host with Vercel first, switch every provider from its test mode to production, gate the launch on doctor --prod, then run it: errors and uptime, flags and kill switches, runbooks, backups and releases. - [Deploy to production](https://nuxt-backend.dev/raw/docs/ship/deploy.md): Ship the Convex backend and the Nuxt app with one build command on any host, split the env between them, set BACKEND_ENVIRONMENT to production, switch the providers over, make the first administrator and gate the launch on `doctor --prod`. - [Deploy to Vercel](https://nuxt-backend.dev/raw/docs/ship/deploy/vercel.md): What an app gets on Vercel, the host the package is built on first: BotID, Sentry's integration, the AI Gateway and the project's env, then this site's own setup as a reference: Web Analytics and Speed Insights without cookies, Firewall rate limits and a keyless model for the docs assistant. - [Deploy in one command](https://nuxt-backend.dev/raw/docs/ship/deploy/one-command.md): `nuxt-backend deploy` links the production deployment, pushes its env, deploys the backend and migrates its data, syncs the billing catalog, registers both webhooks, writes the app's env into the Vercel project and runs `doctor --prod`, step by step and safe to run again. - [Start from the deploy template](https://nuxt-backend.dev/raw/docs/ship/deploy/template.md): A new app deployed to Vercel from its first commit: the starter as a Vercel template, with Convex added through the Vercel Marketplace, running on the providers' test modes until `nuxt-backend deploy` switches it to production. - [Set up preview environments](https://nuxt-backend.dev/raw/docs/ship/deploy/previews.md): Give a branch's preview build a backend of its own, with a generated auth secret, the branch's exact origin as SITE_URL and BACKEND_ENVIRONMENT set to preview, from the build or from the project's env defaults. - [Deploy a demo or staging app](https://nuxt-backend.dev/raw/docs/ship/deploy/staging.md): Run a public demo or a staging copy of your app in production mode while every provider stays in its test mode, with BACKEND_ENVIRONMENT set to sandbox, a Convex project of its own, Polar's sandbox and Resend's test addresses. - [Self-host and add domains](https://nuxt-backend.dev/raw/docs/ship/deploy/self-hosting.md): Point the app at a self-hosted Convex backend or at custom domains for the deployment, where the HTTP-actions origin cannot be derived, and move the provider webhooks with it. - [Production checklist](https://nuxt-backend.dev/raw/docs/ship/checklist.md): What `doctor --prod` fails on, what it reads off production and probes on the live site, and the list for what no command can see, from auth, email and billing to privacy, monitoring and a launch in phases. - [Security model](https://nuxt-backend.dev/raw/docs/ship/security.md): How an app built on the package is guarded end to end: the Content Security Policy, webhooks verified once and failing closed, sign-in codes and passkeys with their limits, step-up for sensitive actions, administrator visits, secret rotation and what stays internal. - [Tune rate limits](https://nuxt-backend.dev/raw/docs/ship/security/rate-limits.md): Throttle sign-in code sends and checks, passkey sign-in challenges, billing syncs, metered AI calls, admin actions, invitations and your own endpoints with Convex's rate-limiter component, pre-seeded with the package defaults. - [Register webhooks](https://nuxt-backend.dev/raw/docs/ship/security/webhooks.md): One call mounts every inbound route on the deployment: the auth routes, the billing and email webhooks with their signatures verified once, the metered AI stream and the health check. Then point Polar and Resend at them and read the delivery log. - [Rotate secrets](https://nuxt-backend.dev/raw/docs/ship/security/secrets.md): `nuxt-backend env rotate` replaces the auth secret, the session signing keys and the webhook secrets without signing anyone out or dropping a delivery: the new value beside the old, then the old retired. - [Security surface](https://nuxt-backend.dev/raw/docs/ship/security/surface.md): Everything the package adds to an app that someone outside can reach, by kind: routes, public functions, env names, webhooks and public pages, reviewed as one checkpoint for 0.2.0, with every public function probed the way an attacker would call it. - [Secure your supply chain](https://nuxt-backend.dev/raw/docs/ship/security/supply-chain.md): Keep the dependencies your app installs trustworthy: lockfiles, install cooldowns, install scripts by name, trust checks, reviewed agent and editor config, and a CI that cannot be turned against you. - [Compliance](https://nuxt-backend.dev/raw/docs/ship/compliance.md): Which laws reach a client app, and who answers for what: you, the processors you use, and the billing provider as the merchant of record. Not legal advice. - [Privacy, GDPR and cookies](https://nuxt-backend.dev/raw/docs/ship/compliance/privacy.md): For a compliance review: the personal data each table and each provider holds and for how long, the subprocessors and where they keep data, export and erasure, consents and cookies, and the legal pages the package fills in. Not legal advice. - [Make your app accessible under EU law](https://nuxt-backend.dev/raw/docs/ship/compliance/accessibility.md): What the European Accessibility Act asks of an app sold to consumers in the EU, what the packaged pages already meet, what your own pages still owe, and the accessibility statement. Not legal advice. - [Disclose AI-generated content](https://nuxt-backend.dev/raw/docs/ship/compliance/ai-transparency.md): What Article 50 of the AI Act asks of an app that generates content or chats with people, who answers for each duty, and how to label output for people and machines. Not legal advice. - [Moderate user content](https://nuxt-backend.dev/raw/docs/ship/compliance/moderation.md): What the DSA and the TAKE IT DOWN Act ask of an app that hosts what people upload: a notice form anyone can use, statements of reasons, an appeal, reports of crimes and the 48-hour removal. Not legal advice. - [Follow the CSAM playbook](https://nuxt-backend.dev/raw/docs/ship/compliance/moderation/csam-playbook.md): What to do when an upload matches a list of known child sexual abuse material: keep the image from everyone, keep the evidence, report it to the authorities, and never tell the uploader. Not legal advice. - [Follow email law](https://nuxt-backend.dev/raw/docs/ship/compliance/email-law.md): Consent, one-click unsubscribe, sender identity and a postal address under the mailbox providers' sender rules, CAN-SPAM, GDPR and ePrivacy, and which parts the package handles. Not legal advice. - [Follow subscription law](https://nuxt-backend.dev/raw/docs/ship/compliance/subscriptions.md): The EU withdrawal right and button, the consent that ends it for digital content, renewal consent and reminders, online cancellation and refunds, and which of them the merchant of record handles for you. Not legal advice. - [Set a minimum age](https://nuxt-backend.dev/raw/docs/ship/compliance/age.md): Choose the minimum age your app accepts, ask for it at sign-up and refuse anyone younger, and what COPPA and GDPR Art. 8 ask when children could sign up. Not legal advice. - [Monitor production](https://nuxt-backend.dev/raw/docs/ship/operate.md): Where to look once the app is live: each capability's state, error reports and uptime, cron check-ins, the deployment's logs and their codes, the webhook delivery log, the activity trail and the providers' own dashboards, with what each tells you. - [Monitor errors and uptime](https://nuxt-backend.dev/raw/docs/ship/operate/monitoring.md): Report errors from the browser, the Nuxt server and the backend's actions with personal data scrubbed, send log lines, replay sessions after consent, take feedback, check crons in, raise alerts on the email quota, AI spend and Convex usage, and see what AI costs per person. Sentry once a DSN is set; a local error log in dev. - [Roll out features and pause services](https://nuxt-backend.dev/raw/docs/ship/operate/flags.md): Declare feature flags in code and read them inside queries and mutations, target them by account, workspace, plan or a stable percentage, and pull the kill switches: pause sign-ups, checkout or AI, or put up a maintenance notice. - [Respond to incidents](https://nuxt-backend.dev/raw/docs/ship/operate/runbooks.md): Runbooks for what breaks in production: webhooks that fail, arrive late or arrive twice, an erasure that stopped, a maintenance cron that fails, a rate-limit spike, credits held by a reservation, a leaked secret and a provider outage, each with what degrades and what to do. - [Replay a webhook delivery](https://nuxt-backend.dev/raw/docs/ship/operate/replay.md): Pick a delivery from the webhook log and have Polar or Resend send it again, signed, through their own redelivery, from the admin console, DevTools or your own admin code, with each replay recorded. - [Troubleshooting](https://nuxt-backend.dev/raw/docs/ship/operate/troubleshooting.md): Fixes indexed by symptom: pnpm can't resolve components, the sign-in code never arrives, builds that never exit, start_push 500, sessions after changing AUTH_SECRET, and every log code the package writes. - [Back up, restore and roll back](https://nuxt-backend.dev/raw/docs/ship/operate/backup.md): Take snapshots of the production deployment, the components' tables with yours, restore one and bring the billing and email providers back in step, and roll back a deploy across a schema change without breaking the data. - [Get help](https://nuxt-backend.dev/raw/docs/ship/operate/help.md): Where to ask a question, report a bug or report a vulnerability, and what to include so it can be answered at once: doctor's JSON, the versions, and the kind of deployment. - [What's new in 0.6](https://nuxt-backend.dev/raw/docs/ship/releases.md): 0.6.0 sells through Stripe Managed Payments, Dodo Payments and Creem besides Polar, adds an authenticator app after the sign-in code, a sign-in-only Convex auth mode and live presence, and lets an app set the waitlist's friend credit, keep its rank private and plan the next wave. The module now requires Nuxt 4.7.0. - [Changelog](https://nuxt-backend.dev/raw/docs/ship/releases/changelog.md): Every release of nuxt-backend, newest first: what changed, what broke, and what to do about it. - [Stability](https://nuxt-backend.dev/raw/docs/ship/releases/stability.md): What a version number promises: the public surfaces, the experimental tier, and how upstream releases map to releases here. - [Verify a release](https://nuxt-backend.dev/raw/docs/ship/releases/verify.md): Before you upgrade, check that the nuxt-backend tarball npm serves was built by this repository's release workflow from a tagged commit: npm's provenance, the GitHub attestation of the tarball and its SBOM, and the immutable GitHub Release. - [Upgrade to a new version](https://nuxt-backend.dev/raw/docs/ship/releases/upgrade.md): Move your app to a new release: install it, let `nuxt-backend upgrade` repair the scaffold and run the package's data migrations, then read the changelog. 0.2.0 is the first release, so no codemod rewrites your code. ## Reference The generated API reference, one page per import path, is a lookup rather than a page to read through: start at its [index](https://nuxt-backend.dev/raw/docs/reference/api.md), or follow a page's API link. - [Reference](https://nuxt-backend.dev/raw/docs/reference.md): How the reference is organized: configuration, the Nuxt app surface, components, the backend, the CLI and the generated API, with what each page says about 0.2.0 and what is generated from the code. - [Capabilities](https://nuxt-backend.dev/raw/docs/reference/capabilities.md): Every capability: what it gives the app, what powers it, how it runs in development, and the env names, findings, docs, DevTools tab and playground pages it owns. - [Cheat sheet](https://nuxt-backend.dev/raw/docs/reference/cheat-sheet.md): One page to scan: every composable, component, setup helper, CLI command, environment variable, error code and module option. - [Glossary](https://nuxt-backend.dev/raw/docs/reference/glossary.md): The package's words, one anchor each, with the name a provider or library uses for the same thing, so a search in either vocabulary lands here. - [Ecosystem](https://nuxt-backend.dev/raw/docs/reference/ecosystem.md): Which Nuxt modules, Convex components and agent tools nuxt-backend ships, supports, plans or leaves out, and why. - [Package entrypoints](https://nuxt-backend.dev/raw/docs/reference/entrypoints.md): The package exports map and the full import tree: every subpath, where it runs, its stability tier and what it exports. - [Configuration](https://nuxt-backend.dev/raw/docs/reference/configuration.md): Where each setting lives, as to change X, edit Y: the module options, the environment, the app config, the labels, the backend files and the catalog. - [Module options](https://nuxt-backend.dev/raw/docs/reference/configuration/module-options.md): Every option of the Nuxt module's backend key with its default, including css and turning a packaged page off, the paths file the backend reads them from, the options 0.2.0 removes, the runtime config the module publishes, and its ModuleOptions interface. - [Environment variables](https://nuxt-backend.dev/raw/docs/reference/configuration/environment-variables.md): Every variable the package reads in 0.2.0, by group: where it is read, what it takes and what degrades without it, the BACKEND_ENVIRONMENT table, the variables 0.2.0 removes, and how to set each one. - [App config](https://nuxt-backend.dev/raw/docs/reference/configuration/app-config.md): Every appConfig.backend key with its type, its default and what it changes: the plan catalog, the brand, the label overrides, the legal pages and the feedback widget. - [Labels](https://nuxt-backend.dev/raw/docs/reference/configuration/labels.md): Every label group and key the package renders, generated from the labels source: its message name, the English default, its params and its plural forms. - [Project files](https://nuxt-backend.dev/raw/docs/reference/configuration/project-files.md): Every file the scaffold writes or the tooling regenerates: who owns it, what it exports, which exports doctor holds it to, and the files you add for the features you use. - [Catalog files](https://nuxt-backend.dev/raw/docs/reference/configuration/catalogs.md): Every field of defineBillingCatalog, nested as a catalog file writes it, and the id map billing sync writes to billing.generated.ts. - [Nuxt](https://nuxt-backend.dev/raw/docs/reference/nuxt.md): What the module adds to the Nuxt app: composables, conventions, server utilities, the typed client and the import aliases, each with its reference page. - [Composables](https://nuxt-backend.dev/raw/docs/reference/nuxt/composables.md): Signatures for every composable nuxt-backend registers, by area. The core data composables (useQuery, useMutation, …) are nuxt-convex-module's. - [Composable conventions](https://nuxt-backend.dev/raw/docs/reference/nuxt/conventions.md): The shape every nuxt-backend composable follows: an options object, refs you can destructure, isLoading, isPending and a typed error, reads that never throw and actions that reject. - [Server utilities](https://nuxt-backend.dev/raw/docs/reference/nuxt/server-utilities.md): Full signatures for the auto-imported server helpers: the base module's fetch and preload helpers, and backendAuth for a signed-in caller's calls. - [Backend client](https://nuxt-backend.dev/raw/docs/reference/nuxt/client.md): The imperative client returned by useBackendClient() and injected as $convex. - [Import aliases](https://nuxt-backend.dev/raw/docs/reference/nuxt/import-aliases.md): The #backend aliases that point at your Convex functions directory and its generated files. - [Components](https://nuxt-backend.dev/raw/docs/reference/components.md): Every component by area, with its status and its section: one gate, one notice region, the account, workspace, billing, admin and shell components, the parts each is built from, the contract each keeps, and the base module's components it passes through. - [Account components](https://nuxt-backend.dev/raw/docs/reference/components/account.md): The sign-in form, the waitlist form, the consent prompt, the profile and security settings and the account's data: one section per component, with its props, slots, events, states and accessibility. - [Workspace and admin components](https://nuxt-backend.dev/raw/docs/reference/components/workspaces.md): The workspace settings, the invitation page, the activity trail and the admin console's components, and the console's tabs: one section per component, with its props, slots, events, states and accessibility. - [Billing components](https://nuxt-backend.dev/raw/docs/reference/components/billing.md): The pricing table, the checkout and portal links, billing and usage history, the upgrade prompt, the cancel flow, the withdrawal button, the gift form and list, and the referral card: one section per component, and where the credit and gift banners went. - [Shell, gates and notices](https://nuxt-backend.dev/raw/docs/reference/components/shell.md): The components that frame an app: for what a person may see, for every app-wide notice, the app shell, the notification inbox, the page guard's 403 and the connection status, one section each. - [Tokens and data hooks](https://nuxt-backend.dev/raw/docs/reference/components/theme-tokens.md): Every --bk-* token with its light and dark default and the families that read it, every data-* family, and the cascade layer the stylesheet sits in. - [Upload and contact forms](https://nuxt-backend.dev/raw/docs/reference/components/forms.md): The form components for what people send the app: , a checked upload with progress, and , a contact or feedback form delivered to your team. One section each, with its props, slots, events, states and accessibility. - [Parts](https://nuxt-backend.dev/raw/docs/reference/components/parts.md): Every part the packaged pages and components are built from: its registered name, the component that renders it, what it receives, and the data-* hook it keeps when you swap it. - [Setup helpers](https://nuxt-backend.dev/raw/docs/reference/backend.md): Every setup and define helper the package exports: its import path, the file of yours that calls it, and what it gives you, the options that extend them, then the helpers generated from the code. - [Component API](https://nuxt-backend.dev/raw/docs/reference/backend/component.md): The functions the all-in-one backend component exposes as components.backend, module by module, and the helper that wraps each one. - [HTTP routes](https://nuxt-backend.dev/raw/docs/reference/backend/http-routes.md): Every route the package mounts on the deployment and in the Nuxt app: its methods, who calls it, what guards it, and the option that moves it. - [Events](https://nuxt-backend.dev/raw/docs/reference/backend/events.md): The backend's own events on the audit trail, who reads each and what it derives, then the billing and email provider events the webhooks accept. - [Errors](https://nuxt-backend.dev/raw/docs/reference/backend/errors.md): Every code the package refuses with: the fields it carries, the English label, the status an auth route answers with, and what to do about it. - [Hooks and guarantees](https://nuxt-backend.dev/raw/docs/reference/backend/hooks.md): Every function an app hands a setup helper for the package to call: where it runs, how often, in which order, what a throw does, and the idempotency it needs. - [Limits and retention](https://nuxt-backend.dev/raw/docs/reference/backend/limits.md): Every default rate limit, and every window and lifetime the package enforces, with its value read from the constant that sets it. - [CLI](https://nuxt-backend.dev/raw/docs/reference/cli.md): npx nuxt-backend: init, dev, doctor, status, env push, env rotate, billing sync, billing reset, billing resync, access admit, email sync, inbox, upgrade, deploy, analyze, eject and mcp, with every flag and each command's contract. - [Diagnostics](https://nuxt-backend.dev/raw/docs/reference/cli/diagnostics.md): Every doctor finding by id: what it checks, its severity in dev and under --prod, why it matters, and its fix. /d/ links here. ## Live playground Panels, the app the tutorial builds, running on the package for people: sign in with a one-time code or a passkey, then turn an idea into a comic strip against a real Convex deployment in sandbox mode. It is an app, not documentation, so it has no Markdown twin. - [Playground](https://nuxt-backend.dev/playground): The tutorial's app, live, behind a sign-in. ## Agent skills The nuxt-backend skills for coding agents: the core skill holds the rules, commands and env of an app built on the package and routes each task to a task skill. Install them all with `npx skills add https://nuxt-backend.dev --skill '*'`; in an app, `npx nuxt-backend init --agents` copies the ones its version ships, and `node_modules/nuxt-backend/skills/` holds them too. - [nuxt-backend](https://nuxt-backend.dev/.well-known/skills/nuxt-backend/SKILL.md): Read it first: the ground rules, install, the CLI and env, and where each task lives. - [nuxt-backend-auth](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-auth/SKILL.md): The task skill for sign-in, sessions, passkeys, roles, user-scoped functions, workspaces and invitations, invite codes and the waitlist, the admin console with impersonation, the activity trail, consents, and account export and deletion. - [nuxt-backend-billing](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-billing/SKILL.md): The task skill for the catalog, plans, checkout, the portal, feature gates, plan quotas and credits. - [nuxt-backend-growth](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-growth/SKILL.md): The task skill for launch phases, offers, referrals, gifts, lifecycle email and the funnel. - [nuxt-backend-email](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-email/SKILL.md): The task skill for transactional email, templates, delivery tracking, the dev inbox and notifications. - [nuxt-backend-ai](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-ai/SKILL.md): The task skill for metered AI actions, streams and the job queue. - [nuxt-backend-data](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-data/SKILL.md): The task skill for the function tiers, queries and mutations, errors, search, workflows, uploads, share links, presence, retention, tokens and the Convex components for counts, queues, cached actions, crons and migrations. - [nuxt-backend-ui](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-ui/SKILL.md): The task skill for the packaged pages and components, their parts, theming, labels, translation, slots, the headless composables and eject. - [nuxt-backend-ship](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-ship/SKILL.md): The task skill for provider setup, tests, deploying, production checks, monitoring, flags and kill switches, webhooks and rate limits. - [nuxt-backend-upgrade](https://nuxt-backend.dev/.well-known/skills/nuxt-backend-upgrade/SKILL.md): The task skill for moving an app to a new version, and every name a release renamed or removed. - [Skills index](https://nuxt-backend.dev/.well-known/skills/index.json): Every skill the site publishes, with its files. ## Notes - The docs describe `nuxt-backend`: one npm package that installs a Nuxt module and an all-in-one Convex backend component. - The docs answer as an MCP server too, read-only and with no sign-in: https://mcp.nuxt-backend.dev/mcp (https://nuxt-backend.dev/docs/develop/agents/docs-mcp).