Skip to Content

ORBCART DOCUMENTATION

OrbCart

OrbCart runs the purchase, from Cart to Order, and asks your systems for prices and stock. What it does, what it leaves to you and where to start.

OrbCart is the transaction layer of a shop: Cart, checkout, tax, shipping, payment and Order. It has no catalog. Your products, prices and stock stay in the systems that own them, and OrbCart asks those systems whenever a buyer needs a binding answer.

A whole purchase is four calls. shipTo is the buyer's address and payment is the card field on your page:

import { createCommerce } from "@orbcart/client";

const commerce = createCommerce({ url: "http://localhost:8787", key: "pk_test_..." });

const cart = await commerce.cart();
await cart.add("BACKPACK-30-GREEN");
const quote = await cart.quote({ shipTo, contact: { email: "anna@example.com" } });
const result = await quote.pay({ payment });

When the card goes through, result.status is "ordered". The quickstart runs these lines against a complete example shop in about ten minutes.

What OrbCart does

  • Signs the price. The buyer pays exactly the Quote they agreed to, or sees the new one first. A Quote expires after at most 30 minutes.
  • Takes the payment. Stripe, Adyen, Mollie, PAYONE, PayPal and Amazon Pay sit behind one configuration, with express checkout. A provider timeout is unknown and resolved by asking again, never a double charge.
  • Prices the delivery and the tax. Shipping rules per country, EU VAT for all 27 member states, discounts and gift cards.
  • Hands over the Order. Your ERP gets every paid Order exactly once, and your systems hear what happened through signed Order events.
  • Serves AI agents through the same door. An agent buys for a shopper over UCP, under the rules of your storefront.

What OrbCart leaves to you

OrbCart does notWho does
Hold products, prices or stockYour systems, through the offers contract, or OrbCatalog.
Render the shopYour storefront, in any framework. A React checkout and an order page are included.
Send emailsYour systems. OrbCart says which email is due.
Run on someone else's serversYou do: a Worker in your own Cloudflare account. See deployment.

What makes OrbCart different compares this with shop platforms, headless suites and a build of your own, and says when something else fits better.

Change what you need

Everything in OrbCart changes in one of three ways, from shallow to deep. Extend OrbCart maps every extension point.

DepthYouExample
ConfigureSet values per market in the Channel.Shipping rules, discounts, legal texts, payment methods.
ComposeArrange and restyle the parts of the checkout.A checkout with a page per step.
ReplaceAnswer a contract with your own code.Prices and stock from your ERP.

With OrbCatalog

OrbCart needs none of its siblings. If you run OrbCatalog, the catalog answers the offers and inventory contracts for you, with no code in your Worker. Connect the products shows the configuration.

Next steps

You want toRead
See it runQuickstart
Understand the modelConcepts, then How it works
Build the storefront sideCarts
Connect your ERP or pricing serviceOffers
Copy a complete exampleRecipes
Know what works todayProject status

On this page