› Buy a real product from a storefront that lives
on Solana — in one sentence of English.
› Steps:
- Find where it is sold
read every storefront's own on-chain account
- Derive the nine accounts
offline, from seed recipes — nothing guessed
- Check the call before it counts
simulate the exact bytes → a receipt
- Sign and settle
the key never leaves its enclave
The same shape a workflow spec describes for HTTP APIs — except the operations
here are program instructions, and the accounts have to be
derived before any of them can be called.
let_me_buy
a storefront program — stand up a store, list products, take payment
INIT
initialize
3 accounts · creates the store
WRITE
add_product
4 accounts · lists a product + price
the purchase
where the money moves — and where a guess costs you
PAY
make_purchase
9 accounts · store_name, product_name, table_number
extracted
SETTLE
mark_as_delivered
2 accounts · receipt_id
extracted
REFUSED
unknown store
its authority lives inside the account — guessing pays the wrong person
9 accounts for one purchase. Six are derived, three are pinned program ids —
and the two that move money are an easy pair to swap.