Quickstart
From zero to a working storefront in 60 seconds. `cimplify init` scaffolds a Next.js app wired to the local mock; the same code points at your live business when you bring keys.
Three integration tiers, all in the same SDK: scaffolded template (most agents pick this), typed client for custom flows, REST for non-JS backends.
Already know which tier you want and just need the command list? The TL;DR page has the ten commands from empty shell to live custom domain.
Tier 1: Scaffold a storefront
The init command creates a Next.js project from one of six industry templates, installs deps, wires the cart drawer, mock-seeded catalogue, and the testing harness.
curl -fsSL https://cimplify.io/install | sh # install once
cimplify init my-store --template retail
cd my-store
bun devTemplates: bakery · restaurant · retail · services · grocery · fashion. Each ships its own lib/brand.ts (single source of truth for every visible string), brand-validated via BrandSchema.
Open http://localhost:3000; products, cart, checkout, account, and chat are all wired. Open http://localhost:8787 for the mock API admin surface.
Run the test harness
bun run check # typecheck + lint + brand + cart-flow + contract
bun run check:brand # schema invariants on lib/brand.ts
bun run check:cart # add → dedupe → remove against in-process mock
bun run check:contract # validates SDK ↔ mock contract end-to-endTier 2: Typed client (custom UI)
For bespoke storefronts. Every method returns Result<T, CimplifyError> and never throws.
1. Install
bun add @cimplify/sdk2. Construct a client
import { createCimplifyClient } from '@cimplify/sdk'
export const client = createCimplifyClient({
publicKey: process.env.NEXT_PUBLIC_CIMPLIFY_PUBLIC_KEY!,
})3. Browse, cart, checkout
// Catalogue
const products = await client.catalogue.getProducts({ limit: 24 })
if (!products.ok) throw products.error
// Cart: flat add-to-cart payload (variant + add-ons go on the body, not nested)
await client.cart.addItem({
item_id: 'prod_studio-tee-natural',
quantity: 1,
variant_id: 'var_studio-tee-natural_size_s',
add_on_options: ['addopt_gift_wrap'],
})
const cart = await client.cart.get()
if (!cart.ok) throw cart.error
// Checkout: flat ProcessArgs body (top-level fields, not wrapped)
const result = await client.checkout.process({
cart_id: cart.value.id,
customer: {
name: 'Jane Doe',
email: 'jane@example.com',
phone: '+233244000000',
},
order_type: 'delivery',
payment_method: 'mobile_money',
mobile_money_details: { phone_number: '+233244000000', provider: 'mtn' },
})
if (!result.ok) throw result.error
console.log('Order:', result.value.order_id, 'bill_token:', result.value.bill_token)4. React components (90+)
'use client'
import {
CimplifyProvider,
CartDrawerProvider,
CartDrawer,
} from '@cimplify/sdk/react'
import { client } from '@/lib/cimplify'
export default function Root({ children }: { children: React.ReactNode }) {
return (
<CimplifyProvider client={client}>
<CartDrawerProvider>
{children}
<CartDrawer onCheckout={() => router.push('/checkout')} />
</CartDrawerProvider>
</CimplifyProvider>
)
}Tier 3: REST
For server-to-server integrations from any language. Every endpoint lives under /api/v1 and accepts either X-API-Key: sk_… for secret keys or X-Public-Key: pk_… for client keys.
curl https://api.cimplify.io/api/v1/catalogue/products \
-H "X-Public-Key: pk_test_..." \
-H "X-Business-Id: bus_..."Where to next
-
TypeScript SDK All 13 services: catalogue, cart, checkout, scheduling, …
-
React SDK 90+ components, 30+ hooks, drawer, full pages
-
CLI init, login, deploy, env, domains, mock
-
Testing harness Pre-baked vitest suites + the in-process mock oracle
TL;DR — zero to production
Ten commands from an empty shell to a live storefront at a custom domain. The full developer journey through the Cimplify CLI in one page.
Brand schema
Every storefront template ships a `lib/brand.ts` that owns every visible string. Pages, components, JSON-LD, sitemap, `llms.txt`, and metadata all read from `brand`, so a rebrand is one file. The shape is enforced at boot by `BrandSchema`, and at test time by `assertBrand(brand)`.