Concepts
Pricing and billing
$10 a month per published project. Need more room? Add capacity for $10 a month.
Each published project includes 1 GB database, 4 GB file storage, 50 hours a month of backend time, 5 GB a month of data transfer. Each capacity you add
includes the same again. Nothing is charged without a confirmation, and
spaceboy billing show --json always has the current prices as data
(usageBilling.projectPrice, usageBilling.capacityPrice).
An organization that already pays through an earlier plan keeps it
unchanged: spaceboy billing show tells you which billing the organization
is on (usageBilling.model is USAGE or LEGACY). On either, deploying to
development is free (below); only publishing to production is charged.
What is free
Development is free; publishing to production is the paid step. That holds for every kind of app (a static site, or one with sign-in and a database) and for every organization, including one on an earlier plan.
- Signing up, creating projects,
spaceboy init,spaceboy push. - One full-stack development environment per organization (database, sign-in, backend, hosting), with no card and no credits: deploying to it costs nothing.
- Every development environment of a published project.
The free development environment has these limits, and every refusal
names the one it hit (exit 4, error.code = FREE_DEVELOPMENT_LIMIT):
- One development environment of an unpublished project per organization.
A second unpublished project's first development deploy is refused;
error.actionholds the command that frees the environment, or publish a project. - A database of up to 1 GB. Over it, new deploys are refused (also while
its size cannot be read) and the organization gets a notice; the
environment keeps running and is never put to sleep for its size.
spaceboy dbworks on it, asleep or not, so you can always delete data to get back under the limit, or publish the project. - Files (site files and uploads) of up to 1 GB. Over it, new deploys are refused until files are removed or the project is published; it keeps serving and nothing is deleted.
- Up to 5 GB of data transfer (bytes served) in any 30 days. Over it, the environment sleeps until the 30-day total falls back under; publishing lifts it.
- It sleeps after 7 days with no deploy and no request to its functions or
API (sign-ins count; it stops serving, nothing is deleted). Visits to
static pages are not measured, so a static-only environment sleeps 7 days
after its last deploy. A request count that cannot be read never puts an
environment to sleep. You get an email at least 48 hours before an
environment first sleeps, and
spaceboy deploy --project <id>wakes it. Its functions scale to zero when no request is running. - Each function runs at most 1 instance, and scheduled functions run at most every 15 minutes; the deploy log names these limits, and a faster schedule is refused with them.
- No custom domain on a development environment of an unpublished
project: it is served from its Spaceboy address, which search engines
are told not to index (
X-Robots-Tag: noindex). - One person can use the free development environment in at most two
organizations. Addresses that differ only by a
+tag(or by dots, on Gmail) count as one person for this limit and for free deploy minutes. - An organization with no published project can hold up to 5 projects; publishing one lifts it. Abandoned drafts from the console's publish wizard, which no project list shows, do not count; a draft that was deployed does.
- Your own service keys, secrets and real payments wait for a published project, as below; a development environment takes test payments only.
Deploying needs a saved account, for the person deploying and for the
organization's owner: a guest account (no sign-in added yet) gets
ACCOUNT_NOT_SAVED and nothing is charged. Guests cannot invite. Free
deploy minutes are counted per person too: the free minutes a month are
one organization's (300) for the person deploying and for the owner,
across every organization they use, so a new organization adds none, and
deleting one gives none back. When the platform's free deploy
minutes for the day are used, free deploys pause until 00:00 UTC
(DEPLOY_MINUTES_USED, "Free deploys are paused for today"); publishing
a project, and every deploy of an organization that pays, is not
affected.
Testing, and deploy limits
Spaceboy builds and deploys your project. Run your tests with your own agent or CI before you publish. There are no hosted checks on this plan: GitHub Actions is off on the organization's Spaceboy repositories, so no workflow runs there, and nothing waits for CI: a production deploy does not, and a commit pushed straight to the default branch of a published project is deployed to production by itself. A failed build still stops a deploy. A repository you connected from your own GitHub keeps its own CI.
iOS and Android app builds are not available on this plan;
spaceboy build says so and charges nothing.
Deploys are free up to an included number of deploy minutes a month. Every organization gets 300; each published project and each capacity step adds 300. Each published project also has a production reserve of 100 that only production deploys use, so development deploys cannot use up the minutes a production fix needs. Each deploy counts from its start until its job has ended, at least 5 minutes and at most 60. Only deploys made since the organization moved to this plan count. Deleting a project does not give its minutes back. Nothing is ever charged for them.
usageBilling.deployMinutes (and spaceboy billing show) gives used,
included, productionUsed and productionIncluded, when they reset
(the first of the month, UTC) and one sentence. Once they are used, new
deploys exit 4 with error.code = DEPLOY_MINUTES_USED, naming the reset
date. That lasts until the reset, or until publishing a project
(spaceboy billing publish) or adding capacity
(spaceboy billing capacity add) raises the limit.
Rate limits that apply anyway: 12 deploys an hour per project and 30 per
organization (RATE_LIMITED, with the time to retry).
Publishing: the one step a person does
The first time an organization publishes, the production deploy is the one command:
spaceboy deploy --target production --json{"event":"payment_required","projectId":"prj_...","projectName":"...","organizationName":"...","amountUsd":<price>,"currency":"usd","interval":"month","renews":"monthly until cancelled","checkoutUrl":"https://checkout.stripe.com/...","expiresAt":"..."}{"event":"waiting","projectId":"prj_...","state":"AWAITING_CHECKOUT","remaining_s":1770}{"event":"paid","projectId":"prj_...","projectName":"...","organizationName":"...","monthlyUsd":<price>,"renewsOn":"YYYY-MM-DD"}{"event":"deployed","deploy":{"id":"edp_...","status":"SUCCEEDED",...}}
Give checkoutUrl to your person. The payment page names Spaceboy, the
project, the organization, the price and the renewal; after paying they land
on a page that needs no sign-in and says the terminal continues by itself.
The command waits (30 minutes by default, --payment-timeout), says it is
still waiting at least every 30 seconds, and continues the deploy within
seconds of the payment, ending with one receipt line and the live URL. It
ends "paid" only when the payment provider confirms it; while it cannot
tell yet it keeps waiting. Not paid in time: exit 6, nothing charged or
deployed, and the link stays valid until the time printed (unless a link is
made for another project of the organization, which replaces it). If the
terminal stops, spaceboy billing wait --project <id> re-attaches to the
same link. For CI, --no-wait-for-payment prints the link and exits 4 with
error.code = PAYMENT_REQUIRED instead. Nothing is charged before
checkout. Asking again before checkout returns the same link.
spaceboy billing publish --project <id> only pays (same link, same wait
with --wait); it never deploys and ends by naming the deploy command.
After that, publishing another project uses the card on file and needs the
price stated back (amountUsd from the refusal, or
usageBilling.projectPrice.amount):
spaceboy deploy --target production --confirm-charge <price>Without --confirm-charge, or with another amount, the deploy exits 4 with
error.code = CHARGE_CONFIRMATION_REQUIRED, states the price, gives the
complete command to run in error.action (with --confirm-charge <price>)
and charges nothing. A card on file is never charged silently: no link, an
explicit --confirm-charge equal to the price shown, within the per-call
and the 30-day agent limits below. With it, the rest of this month is charged now (prorated) and the
project is published; if the card is declined, nothing is published. A
published project's redeploys never ask again.
An agent may confirm a charge the same way, with the exact amount; there is no charging without it. Every charge is recorded with who approved it (a person, an API key, or a workspace agent) and receipted to the owners by email.
Agents, and anything else using an API key (the CLI included), may approve
up to $100 of new monthly charges per 30 days for an organization, and at
most 10 capacity at a time. That includes capacity added automatically
after an agent turned automatic capacity on. Beyond that, the command
exits 4 with error.code = CHARGE_APPROVAL_REQUIRED. The message gives
what is used, the exact command to run again, and where an owner changes
the limit. Nothing is charged.
An owner raises, lowers, removes or restores that limit in the console
(Billing > Agent charges). Setting it to 0 requires a person for every
charge. It cannot be changed with an API key. A person publishing from the
console is not limited by it.
spaceboy billing publish --project prj_... [--confirm-charge <price>] [--wait]
publishes without deploying.
More room
spaceboy billing show --jsonusageBilling.publishedProjects[].usage lists, per project, each included
amount with used, included and percent; usageState is OK,
WARNING (80% of something) or OVER. Usage is measured daily.
Backend time is the time your production functions run; they scale to
zero, so an idle backend uses none. A function on always-on
(spaceboy environments keep-warm production) keeps one instance running
that is paid by its own line, so that instance is not counted: only
further instances, when traffic needs them, are. A minimum instance count
set any other way counts in full. At 80% and
at 100% the organization's owners get an email, and spaceboy deploy
prints the same notice (room in --json output) with the exact command,
for example:
spaceboy billing capacity add --project prj_... --confirm-charge <price>That adds the included amounts again, charged now for the rest of the
month. --count 2 adds two (confirm the total).
A project that has used all of an included amount keeps serving, but its
new production deploys are refused (CAPACITY_REQUIRED, with the capacity
command and price in error.action) until capacity is added or the amount
is back under: backend time and data transfer reset each billing period;
storage must be trimmed. Nothing is deleted or charged by itself.
To remove capacity: spaceboy billing capacity remove --project prj_....
It stops being charged from the next billing period and stays usable until
then; adding it back in the same period is not charged again. It is refused
(CAPACITY_IN_USE) while the project uses more than would remain.
Optional: spaceboy billing capacity auto --max 2 --confirm-charge <price>
lets a project that runs out of room get up to 2 more by itself, each at
the capacity price. It is off unless you turn it on; --max 0 turns it
off.
Stopping a charge
Taking production down (spaceboy undeploy --target production) or
deleting the project stops its charge at once, and the unused part of the
month (its capacity included) comes back as a credit on the next invoice.
Nobody has to cancel anything.
If the organization's subscription is cancelled, every published project goes offline with its data kept; publishing again starts a new checkout.
When a payment fails
Published projects keep running for a week while the card is retried; an
email links to the invoice. After that they pause (nothing is deleted).
Once the invoice is paid the pause lifts and the owners are emailed; deploy
to bring production back (spaceboy deploy --target production).
Publishing or adding capacity is refused with PAYMENT_PAST_DUE meanwhile.
Receipts are emailed to the organization's owners.
Card and invoices
Owners and admins open the card and invoice portal with
spaceboy billing manage (it prints a link for a person). It updates the
card (cards only), shows invoices and cancels at the end of the period;
projects and capacity change only through Spaceboy.
usageBilling.canManageBilling says whether the caller can. Members see
usage and published projects but not invoices.
Separate: prepaid credits
Prepaid credits (spaceboy topup) are for organizations on the earlier
plans. Building, deploying and published projects on this plan never draw
on them. On every plan, API keys (the CLI's included) and workspace agents
may top up at most $100 of credits per 30 days for an organization
(CHARGE_APPROVAL_REQUIRED beyond that), whichever command or agent
action asks, and cannot turn automatic top-up on. A person topping up on
the billing page is not limited. An owner, signed in, changes the limit on
the billing page (Billing > Agent top-ups). Reusing an idempotency key
with another amount, or more than a day later, is refused.
Error codes
Exit code 4 means billing or permission. With --json, error.code is one
of PAYMENT_REQUIRED, CHARGE_CONFIRMATION_REQUIRED, PAYMENT_PAST_DUE,
PAYMENT_DECLINED, FREE_DEVELOPMENT_LIMIT, CAPACITY_IN_USE,
NOT_PUBLISHED, BILLING_UNAVAILABLE, BILLING_PENDING (a change still
being confirmed with Stripe), CHARGE_REFUNDED, CHARGE_APPROVAL_REQUIRED,
DEPLOY_MINUTES_USED, RATE_LIMITED, NOT_AVAILABLE (app builds on this
plan), ACCOUNT_NOT_SAVED (a guest account: add a sign-in), and
error.details.usageBilling
carries amountUsd, checkoutUrl, nextCommand and billingPageUrl where
they apply. Only organization owners and admins can publish, change
capacity or open the card portal. Changing who controls an organization
(inviting, promoting, demoting or removing an owner or admin, handing
over ownership, single sign-on, deleting an account or the organization)
needs a person signed in to the console; API keys and agents can invite
and remove members only.
For agents: /docs/agents/pricing-and-billing.md · llms.txt