44 Commits

Author SHA1 Message Date
64c74c7446 fix(checkout): restore checkout build after robinhoodWif registry key
robinhoodWif (18-decimal $wif) is a chain-registry/facilitator asset, not a
PaymentNetwork, so onchain-billing now skips non-PaymentNetwork chains and the
checkout EVM helpers carry the narrowed PaymentNetwork & EvmChainKey type.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-11-10 18:18:27 +03:00
534e0e418f fix: create guest customer row before claiming payment
payments.customer_id has an FK to customers; guest checkouts used a
synthetic cus_<session> id that was never inserted, so every live
on-chain confirmation failed with 23503 and the status route 502'd.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 19:56:15 +03:00
21660a73a1 fix(ui): replace the emoji bell with an SVG icon; readable checkout alerts on the light theme
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-07 17:59:56 +03:00
dea78f6eeb test: pin checkout test clock and cover x402_nonces in schema test
Checkout fixtures are dated 2026-09-29 but expiry reads the wall clock, so
24 tests started failing once the real date passed the checkout window.
The schema test predated the x402_nonces table, which is keyed by the
claimed authorization instead of id.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 19:36:07 +03:00
29de477e0f feat: Spanish hosted checkout via packages/localization (G14, part 2)
packages/localization gains the hosted checkout catalog (English source,
complete Spanish), a q-weighted Accept-Language picker limited to en/es
and a placeholder formatter. The checkout app (now depending on
@settlekit/localization) localizes the checkout, payment link, invoice
and success pages plus the order summary, promo, tax and start
components; ?lang=en|es or an sk_lang cookie override the browser
language and <html lang> follows. English output is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 06:42:02 +03:00
1d92fa23f2 feat: branded hosted storefront per merchant (G12)
Merchants can publish a store (slug, title, tagline, https logo, accent
colour, search description, optional custom domain) through settings or
the dashboard. The checkout app serves it at /store/<slug> with SEO and
Open Graph metadata, listing active products (invoice products hidden)
that each open their payment link, and a middleware rewrites '/' on a
merchant's custom domain to its store when CHECKOUT_PRIMARY_HOSTS is set.
Slugs and domains are unique; public data at /v1/public/stores. Carts of
several products stay out of scope because hosted checkout fulfils one
product per session.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 06:32:06 +03:00
330d111510 feat: fiat pricing with live ECB rates locked per checkout (G7)
Prices can now be set in EUR, GBP and other ECB reference currencies
(displayCurrency + displayAmount, or currency on quick products). Each
checkout converts them to USDC at the live rate from a frankfurter
service (MIT, FX_RATES_URL), rounded half-up to the cent with exact
bigint math, and locks the quote on the session (fxQuote) until it
expires, so onchain verification expects exactly the quoted USDC. Promo,
tax, receipts and the hosted checkout lines use the locked rate; the
payment link page shows the fiat price and today's USDC amount. Missing
or implausible rates fail closed (503); fiat subscriptions and mixed
fiat currencies are refused. Dashboard product form gets a currency
picker.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 05:13:37 +03:00
f1647a5a81 feat: embeddable checkout overlay (embed.js) with allow-listed success callback (G6, part 1)
apps/checkout/public/embed.js opens a payment link, checkout or invoice
from the same checkout origin in an overlay iframe on any site; links
marked data-settlekit-checkout bind automatically, SettleKit.open() is
available from code, and there is an open-in-new-tab fallback for
wallets that block iframes. The success page posts settlekit:success
only to a site the seller listed under Settings > Embedding
(org embedOrigins, validated https origins), and embed.js only accepts
messages from its checkout frame. Payment requests gain sendEmail and
successUrl so store plugins can redirect buyers and bring them back.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 04:52:19 +03:00
a4d0f3f5cb feat: tax at checkout and tax-grade receipts (G4)
Sellers can turn on checkout tax in settings (label, own country and tax
ID, legal name, per-country rates, default rate, EU reverse charge).
Sessions add tax on top of the net price after any promo, so onchain
verification expects the tax-inclusive total. Buyers set billing country
and VAT ID via the API (billingCountry, vatId) or on the hosted checkout
until a payment is recorded; EU cross-border B2B with a VAT ID of the
right shape is zero-rated. Settled checkouts get a PDF receipt (pdfkit)
with the seller's tax ID, buyer country / VAT ID, tax rate and the
settlement transaction, linked from the success page, the receipt email
and the customer portal. packages/tax calculateTax is now used at
checkout.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 04:30:53 +03:00
4e97fcc409 feat: promo codes at checkout (G3)
Coupons now reach checkout. POST /v1/checkout-sessions takes an optional
couponCode, payment links accept ?promo=CODE (a refused code falls back to
full price with a notice), and the hosted checkout gets a promo field
while the session is open and unpaid. The discounted total becomes the
session amount before network bindings, so onchain verification expects
the discounted amount and a locked Zcash quote is re-priced. Codes are
tenant-scoped, product-scoped codes discount only their products, and
free-trial or 100% codes are refused. The redemption is counted once
after the payment confirms (API confirm and hosted checkout).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 04:09:54 +03:00
466c662ac3 feat: payable invoices and payment requests (G2)
Invoices can now be paid onchain. POST /v1/invoices/:id/send issues the
invoice, binds a public pay page (/i/<token> on the hosted checkout),
opens a checkout session for the invoice total on the merchant's
networks and emails the link. POST /v1/invoices/requests sends an
ad-hoc amount + memo to an email. The invoice turns paid only when a
confirmed onchain payment exists for one of its sessions (on read in the
API and in the new worker invoice-settle job) and emits invoice.paid.
Invoice and receipt PDFs render with pdfkit (MIT). Voiding cancels open
sessions. Dashboard gets a request-a-payment form, send buttons, pay
links and PDF downloads.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-30 03:35:06 +03:00
33baad09af fix(checkout): show buyers a plain message when subscription options cannot load
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:46:24 +03:00
61ce1686ff feat(web): SaaS integration guide at /docs/integrate, with email-based entitlement checks
- /docs/integrate: payment link, embeddable button, server-opened sessions
  with a return URL, Node webhook signature verification with the event list
  and a sample payload, and checking access through the entitlement API.
- api: /v1/entitlements and /v1/entitlements/verify accept the buyer's email
  and are scoped to the caller's organization.
- checkout: confirmed buyers are recorded as customers (email, GitHub,
  Discord, wallet) so sellers can check access by email; receipts and
  subscriptions offer "Continue to <seller>" when the link carried a successUrl.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:39:36 +03:00
bcccfb0bf7 feat(discord): real paid-role delivery with Connect Discord at checkout
- checkout: buyers connect Discord (OAuth2 identify + guilds.join) in the
  delivery-fields step; the callback saves their user id on the session and
  joins them to the product's server. After payment the bot adds the role via
  PUT /guilds/{guild}/members/{user}/roles/{role}; the grant is recorded for
  access-sync revocation. Without DISCORD_BOT_TOKEN the buyer sees
  "pending setup" instead of a fake success.
- worker: discord-delivery-retry grants pending Discord entitlements once the
  bot is configured (backoff per entitlement); DISCORD_BOT_TOKEN is optional.
- api: a configured bot delivers roles even before GitHub is set up;
  checkout subscriptions pass the buyer's Discord / GitHub ids so subscription
  delivery reaches the right accounts.
- dashboard: product settings explain server / role ids and link the bot invite.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:31:32 +03:00
ae448fe158 feat(checkout): subscribe to recurring products with onchain billing
Recurring checkouts (/c and /l links) offer Subscribe on the session's network:
smart-wallet spend permission, Permit2 capped allowance, Solana SPL delegate or
renewal invoices by email (HyperCore / Zcash). The page states the per-period
price, total cap and expiry before signing; the buyer's wallet (EIP-6963 /
Wallet Standard) sends prerequisite calls and signs the server-built grant,
and the API activates it, charges the first period and delivers access.
Buyers get a signed /s/<token> manage page with status, next charge, charges
with explorer links, cancel and an on-chain revoke. All billing calls go
server-side through /v1/onchain-billing with the service token.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:24:52 +03:00
9691cf7c48 feat(webhooks): signed seller webhooks for payments and subscription charges
Shared outbox in @settlekit/persistence writes one idempotent webhook_events
row per (org, type, business key) and queues a worker_webhook_jobs delivery per
subscribed endpoint; the worker signs and retries them (capped attempts).
payment.confirmed is emitted from checkout, worker confirmations, API confirms
and agent payments; subscription.charged (+ payment.confirmed) from every
collected onchain period. In-memory API mode delivers in-process.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 21:19:12 +03:00
19fa1aa9cb feat(checkout): reusable payment links and seller-hosted delivery links
/l/<slug> shows the product and opens a fresh checkout session per visit
(client-side, so link unfurlers never create sessions). File and plain
access products reveal the seller's https link after payment.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 20:37:41 +03:00
f76a3824e1 fix(hyperliquid): stop the submission fallback from claiming earlier transfers
The bySubmission time-window match allowed 2 minutes of negative skew and a
10-minute window, and trusted a client-supplied nonce on every poll, so it
could attribute an earlier transfer from the same sender to a new session.
It now requires the transfer at or after session creation with no skew,
narrows the window (30s before / 2 min after the signed nonce), and the
checkout persists the submitted action (signer + nonce, then the ledger
hash once found) so later polls match exactly that action.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 20:12:36 +03:00
948ebfd761 fix(zcash): assign amount tags atomically per payTo
Tag assignment was read-then-write, so concurrent sessions paying the same
transparent address could lock the same tag and one payment would match
both. The base quote is now locked with tag 0 and the tag is chosen and
saved under a per-payTo lock (pg_advisory_xact_lock(hashtext(key)) shared
by the API and checkout when Postgres is wired, an in-process mutex
otherwise), with a post-save uniqueness re-check that retries on the next
tag.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 20:04:13 +03:00
ae216e213b fix(checkout): require a wallet signature to bind the EVM payer
The evm/payer route bound any address without proof, so anyone holding the
session URL could lock the buyer out. The buyer's wallet now personal_signs
a short-lived message naming the session, network and payer; the server
verifies it with viem (ECDSA locally, EIP-1271/6492 through the chain RPC
for smart wallets). Unsigned requests never bind or rebind a payer; a new
valid signature may rebind so the real buyer can always recover.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 19:59:00 +03:00
5d4ff5d4b8 chore: move runtime to Node 22 (required by @nktkas/hyperliquid)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 19:20:13 +03:00
a1078a0082 perf(checkout): split per-network payment flows into client chunks; document routing and HyperCore env
next/dynamic now runs in a client module (components/LazyPay), so EvmPay,
SolanaPay, ZcashPay, HyperCorePay, AnyTokenPay and the Arc demo wallet load
on demand: /c/[sessionId] first load drops from 230 kB to 176 kB.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 19:15:47 +03:00
db279a5ab3 fix(checkout): keep polling when the worker recorded the route fill first
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 18:34:53 +03:00
11c91fd1b2 feat(checkout): pay with any token, HyperCore usdSend and Tempo memo enforcement
Any token (replaces the BridgePay/LocalAppKitSdk simulation, now deleted):
- lib/any-token.ts: Relay/LI.FI router from ROUTING_* env, per-session
  destination (the token the verifier checks), policy-checked EXACT_OUTPUT
  quotes stored as session.route, status polling that settles ONLY through
  recordAndConfirm on the destination fill (routed fills skip the payer and
  memo bindings, never payTo/amount/token/time); provider success without a
  qualifying transfer is reported as unverified and stays unpaid
- routes [sessionId]/route/{quote,status} with the same-origin guard
- AnyTokenPay: origin chain + token picker, fees and quote TTL, EIP-6963
  execution of the provider's transactions, deposit-address QR fallback,
  progress, refund notice
- network changes are locked while a route moves funds; a payment confirmed
  by the worker now completes and fulfils the session on the next confirm

HyperCore: runtime (HYPERCORE_*), usdSend params/submit/status routes,
HyperCorePay (wallet signs usdSend, manual hash fallback), verify-payment
case, network options, explorer links.

Tempo: evm params expose memoRequired; sessions with requireMemo only settle
with transferWithMemo(keccak256(sessionId)).

Per-network payment components are lazy-loaded; the Arc demo wallet is
labelled as a simulation.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 18:20:35 +03:00
68a9070a75 feat(hyperliquid): HyperCore usdSend typed data, submission and ledger verification
New @settlekit/hyperliquid on @nktkas/hyperliquid (MIT): EIP-712 usdSend
typed data pinned by golden vectors against the SDK signer, submission of
buyer-signed actions, and fail-closed verification through the payee's
userNonFundingLedgerUpdates (destination == payTo, USDC >= expected, time >=
session creation, payer binding). HYPERCORE_ENABLED / NETWORK / API_URL env.
Registers the workspace packages in the lockfile (filtered install; unrelated
peer rewrites reverted).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:56:14 +03:00
5d0294e693 fix(checkout): keep the network picker when the current network is unavailable
A session whose own network is not verifiable here but has one other
available network would otherwise leave the buyer with no way to pay.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:19:33 +03:00
ed7a2d10ae docs: chain-support matrix, checkout env example and worker retry env
Honest labels: Robinhood Chain settles USDG, Tempo settles bridged USDC.e,
Arc is testnet only, Zcash is transparent (not shielded) and mainnet only.
Adds apps/checkout/.env.example, the checkout routes and OSS licenses, and
the next-waves composition plan.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:16:40 +03:00
dd2d63e48b feat(checkout): network picker, EVM wallet pay and Zcash pay UI
- NetworkPicker: accepted + verifiable networks grouped Solana / EVM
  chains / Zcash, native radios, asset and honest badges (testnet,
  bridged, transparent)
- EvmPay: EIP-6963 discovery (window.ethereum fallback), payer binding,
  wallet_switchEthereumChain with 4902 -> wallet_addEthereumChain from
  the registry, viem writeContract transfer (TIP-20 transferWithMemo with
  the session memo on Tempo), confirmation polling, explorer link;
  EIP-681 QR + manual transaction-hash fallback
- ZcashPay: ZIP-321 QR (uqr), copy address and exact amount, quote
  countdown and re-quote, 20 s status polling, paste-txid fallback,
  transparent-payment note, late payments shown as under review
- page routes SolanaPay | EvmPay | ZcashPay; Arc demo wallet/bridge cards
  only on Arc; receipt shows the settled asset
- next.config transpiles @settlekit/chains and @settlekit/zcash
- tests for discovery, chain switching, transfer encoding, labels,
  grouping, countdown and ZIP-321 display

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:12:13 +03:00
fa072dc24f feat(checkout): network selection, EVM and Zcash payment routes
- POST [sessionId]/network switches between accepted, configured networks
  only while open and unpaid; pins payTo per network, clears the payer,
  adds a Solana reference and locks a ZEC quote (kept while live)
- GET evm/params (registry chain, public RPC for wallet_addEthereumChain,
  exact base units, Tempo memo) and POST evm/payer (payer binding)
- POST zcash/uri (ZIP-321 request) and GET zcash/status (claimed txid or
  cached address scan, confirming / review / paid)
- same-origin guard on state-changing routes; error bodies carry a code
- demo seed sessions accept every chain; the placeholder EVM address is
  only offered on testnets, Solana/Zcash only with configured addresses
- tests: evm-confirm, zcash-confirm, network-select

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:03:51 +03:00
06f3139325 feat(checkout): verify every network through the shared chain runtimes
- lib/evm.ts loads enabled EVM chains with the same loader as the API and
  worker; lib/zcash.ts adds the transparent Zcash runtime, quote locking,
  verification and a 60 s per-payTo address scan cache
- verify-payment is an exhaustive switch over every PaymentNetwork; a
  network without a runtime fails closed; bindings come from the session
  (payTo per network, notBefore = createdAt, payer, Tempo memo, ZEC quote)
- store claims a valid transfer still awaiting confirmations (or a late
  Zcash payment) as a pending payment and reports payment_pending /
  payment_under_review instead of a hard failure
- tx-hash re-exports @settlekit/chains; format gains registry-backed
  network + asset labels (USDC, USDG, USDC.e, pathUSD, ZEC) and badges

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 17:03:50 +03:00
015899f2c3 feat(chains): add multi-chain registry and fail-closed EVM verifier
@settlekit/chains carries the verified EVM registry (Ethereum, Base,
Arbitrum, Robinhood Chain, HyperEVM, Tempo, Arc; mainnet + testnet), a
generic stablecoin verifier over the arc EvmRpc seam (chain-id assertion,
receipt status, token/payTo/amount, confirmations, block time vs session,
payer binding, Tempo TIP-20 memo), CAIP-2 ids, network-aware tx-hash and
payTo rules, env loaders (SETTLEKIT_CHAIN_ENV, ENABLED_EVM_CHAINS, per-chain
overrides, Zcash) and the settlement-verifier contract. Tests replay
receipts recorded from each chain's public RPC.

PaymentNetwork widens to solana|base|arc|ethereum|arbitrum|robinhood|
hyperevm|tempo|zcash and CheckoutSession gains settlementQuote,
payerAddress, acceptedNetworks and payToByNetwork. The hosted checkout
fails closed on the new networks until its wave-2 UI lands.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 15:52:34 +03:00
56e2121664 test: Solana checkout confirmation, duplicates, idempotency and delivery
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 14:59:16 +03:00
e8ec94cf9c feat: Solana Pay checkout routes and wallet UI
- POST solana/pay-url saves buyer fields, returns transfer-request QR
  payload + transaction-request link bound to the session reference
- GET/POST solana/tx: Solana Pay transaction request; server builds the
  unsigned USDC tx (ATA create-idempotent + TransferChecked + reference)
- GET solana/status: finds the payment by reference, verifies, confirms
  and delivers once (idempotent, safe to poll)
- SolanaPay component: uqr QR, Wallet Standard connect +
  solana:signAndSendTransaction, 2s polling, paid state with Solscan link
- checkout page renders SolanaPay for Solana sessions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 14:59:16 +03:00
c33eed8d4b feat: fail-closed checkout confirmation with real GitHub delivery
- recordAndConfirm verifies every network on-chain (Solana via
  @settlekit/solana, Arc via @settlekit/arc) and fails closed when a
  network has no configured verifier; Solana requires the session
  reference
- network-aware tx hash validation on the confirm route and form
- duplicate tx hash (lookup or unique violation) -> 409 conflict
- confirmFromReference finds Solana Pay payments by reference, idempotent
- fulfillment runs once per confirmed payment: entitlement row via
  @settlekit/entitlements plus a real GitHub App invite
  (grantGitHubRepoAccess); missing GitHub App env shows pending setup,
  never a fabricated invite link
- receipts carry explorer links (Solscan for Solana)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-09-29 14:59:08 +03:00
874fa3a08a feat(apps): Phase 7 — escrow lifecycle, portal P2P send, checkout crosschain bridge
- dashboard: escrow detail lifecycle actions (assign/fund/submit/approve/refund) via server actions + api.escrow.* client methods.
- portal: P2P 'send USDC on Arc' page + nav (offline App Kit send, live swap documented); +@settlekit/app-kit dep.
- checkout: 'pay from another chain' crosschain bridge option (App Kit bridge, offline) next to wallet-pay.
- Built inline (subagent limit hit). Phase 7 complete. 1308 tests / 213 suites, typecheck + builds green.
2026-06-21 17:44:20 +03:00
ab81e9c8b7 feat(checkout): wallet-pay via Circle App Kit (real @circle-fin/app-kit + offline default)
- apps/checkout: 'Pay with wallet' option — server action + WalletPay component over @settlekit/app-kit; offline LocalAppKitSdk default, real @circle-fin/app-kit@^1.7.0 on the live path (WALLET_PAY_LIVE, dynamic import so it only bundles when enabled).
- Add @circle-fin/app-kit dep; allowBuilds bufferutil/utf-8-validate=false.
- creator-dashboard: data.ts proof helpers (detectGroundingForText/proveGroundingForText) for the attribution UI.
- 1308 tests / 213 suites, typecheck + builds green; frozen-lockfile verified.
2026-06-21 11:44:49 +03:00
d364fc9c19 fix(vercel): pin Node 20 for deploys; clearer Web Crypto error
- Root cause: isomorphic ids.ts uses globalThis.crypto (a global only in Node 20+, per engines.node>=20). A Vercel project building on Node 18 has no global crypto, so any page generating an id at build time throws and the deploy fails.
- Add .node-version=20 to repo root + every app (Vercel reads it from each app's Root Directory) so deploys use Node 20.
- ids.ts: resolve Web Crypto lazily with an actionable error instead of a cryptic undefined access — still browser-safe (no node:crypto import).
- 1304 tests / 213 suites, typecheck + full build green.
2026-06-21 00:45:43 +03:00
pextacy
bcd51b5829 feat(ui): "Statement" greenbar-ledger frontend redesign
Replace the dark blue→purple gradient SaaS look across all 7 apps with a
gradient-free settlement-ledger identity grounded in what SettleKit does:
reconcile money to the cent.

- Palette: greenbar ledger paper + ink, with accounting semantics
  (credit-green / debit-red / ink-blue seal). No gradients or glows.
- Type: Archivo (display/body) + IBM Plex Mono carrying every number,
  label and section reference; loaded via next/font in each app layout.
- Signature: apps/web hero is a live settlement statement — debit/credit
  line items printing in sequentially with a rotated "SETTLED" stamp.
- apps/web fully rebuilt (globals, layout, components, pages); dashboard,
  portal, marketplace, admin, checkout, docs rethemed by flipping :root
  token values (component JSX untouched); shared packages/ui/theme.css
  moved to the same system.

All 7 apps + @settlekit/ui build clean.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-19 22:35:42 +03:00
eebc819585 fix(checkout): trace from monorepo root so Vercel bundles workspace deps
The checkout app pinned experimental.outputFileTracingRoot to its own dir, so
Next omitted the @settlekit/* workspace package files from the serverless
function — causing a runtime 500 ("Cannot find module") on Vercel while local
`next start` worked (full node_modules). Point tracing at the monorepo root.

docs: add the live Render + Vercel deployment URLs to the README.
2026-06-17 17:49:16 +03:00
99db203c70 fix(deploy): boot API from root pnpm start; add Vercel configs for all Next apps
Render's default Web Service runs `pnpm start` at the repo root, which had no
script — deploys failed with ERR_PNPM_NO_SCRIPT_OR_SERVER and "no open ports".
Add a root `start` that boots the API (@hono/node-server binds 0.0.0.0:$PORT),
so a plain root-level Render service now works (build = full workspace, start =
API). For API + worker + Postgres together, the render.yaml Blueprint still applies.

Add per-app vercel.json (web/dashboard/marketplace/checkout/docs) with the
pnpm-workspace install + filtered build and the correct package names
(marketplace-app / checkout-app / docs-app). Document the Render-API +
Vercel-frontends split in DEPLOYMENT.md.
2026-06-17 16:54:17 +03:00
3853551433 asad 2026-06-17 02:09:36 +03:00
32b89f0515 firstof 2026-06-16 02:51:34 +03:00
598cd03f05 feat: implement all 8 SettleKit apps + fix x402 nonce round-trip
apps:
- api: Hono REST server, all §26 endpoints, 14 tests
- worker: delivery runner + payment-confirm + access-sync + renewal + webhook-retry jobs wired to real package clients
- dashboard: Next.js merchant dashboard, full §16/§27 sections + §28 product builder
- checkout: Next.js hosted USDC checkout with real delivery materialization
- marketplace: Next.js public marketplace + agent metadata.json route
- admin: Next.js risk/ops console wired to @settlekit/risk + database
- docs: Next.js docs site (9 static routes)
- examples: 5 runnable end-to-end examples

fix(x402): support pinned config.nonce so a stateless verifier can confirm
the challenge nonce round-trips (default stays random; package tests intact).

Full workspace: 590 tests passing (122 files), tsc green for all packages +
api/worker/examples, all 5 Next apps typecheck clean, docs next build green.
2026-06-15 10:49:14 +03:00
4afda54455 feat: monorepo scaffold + @settlekit/common contract package
- pnpm workspace, shared tsconfig, vitest
- common: ids, money (USDC base-unit math), Result/SettleKitError, time
- domain types: product, customer, payment, entitlement, delivery, integration
- 13 passing contract tests
2026-06-15 02:55:22 +03:00