Skip to main content
When the agent needs to find the product too, Prava Pay adds a discovery flow on top of payments: search → product → quote → checkout. Each step hands you exactly what you need to run the next.
For the richest guided experience (pacing, confirmations, masked previews), install the prava-shopping skill alongside the CLI. The shop commands work without it, but the skill adds the guardrails that keep the agent honest with the user.
npx --yes skills add https://github.com/Prava-Payments/prava-skills \
  --skill prava-shopping --global --yes --full-depth
The agent must be linked before any shop command works.

Delivery addresses

Physical goods need a delivery address and a contact phone. These are stored on the owner’s account and hydrated server-side at purchase time — the agent only ever sees masked summaries, never full street addresses or phone numbers.
The agent never handles the buyer’s full address or phone. It selects which saved address by id; Prava fills in the real details privately. See Guardrails.

List addresses

prava shop address list
2 saved addresses (masked):

  1. Home  [default]
     San Francisco, CA 94103, US
     address-id: addr_home1
  2. Work
     Oakland, CA 94612, US
     address-id: addr_work2

Add an address

The primary place to add addresses is the Prava dashboard; this is the CLI fallback.
prava shop address add \
  --first-name John --last-name Doe \
  --line1 "123 Main St" --city "San Francisco" \
  --region CA --postal 94103 --country US \
  --phone "+1 415 555 0100" --label "Home" --default
OptionRequiredDescription
--first-name, --last-nameYesRecipient name.
--line1YesStreet address. --line2 optional.
--city, --region, --postal, --countryYesCity, state/province, ZIP, ISO country.
--phoneNoContact phone with country code. Stored on the account, not per-address.
--labelNoe.g. "Home".
--defaultNoMake this the default delivery address.

Set the default

prava shop address set-default --address-id addr_work2
prava shop search --query "dark roast coffee" --intent "gift for a coffee lover" --limit 10 --ships-to US
OptionRequiredDescription
--query <text>YesTight keyword query.
--intent <text>NoThe user’s full natural-language request (occasion, budget) — improves ranking.
--limit <n>NoMax results (default 10).
--cursor <cursor>NoNext-page cursor from a previous search.
--merchant <domain>NoRestrict to one merchant domain.
--ships-to <country>NoISO destination country, e.g. US.
--jsonNoRaw JSON output for chaining.
3 results for "dark roast coffee":

  1. Hair Bender Whole Bean
     $17.00 USD  ·  stumptowncoffee.com
     product-id: prod_abc

Next: prava shop product --product-id <id> --merchant <merchant>

Product

Show a product’s variants and offers across sellers:
prava shop product --product-id prod_abc --merchant stumptowncoffee.com
OptionRequiredDescription
--product-id <id>Yesproduct-id from search results.
--merchant <domain>NoMerchant domain from the search result.
--jsonNoRaw JSON output.
Offers are listed orderable first, then cheapest. Prices shown are item-only — shipping and tax are added at the quote step.
2 offers from 2 sellers, 2 orderable (orderable first, then cheapest) — prices are item-only; shipping is added at quote:

  1. 12 oz  —  $17.00 USD  [whole bean]  ·  stumptowncoffee.com
     variant-id: var_123

Next: prava shop quote --variant-id <id> --merchant <that offer's merchant above>

Quote

Pricing a variant opens a checkout session with the final, binding total — subtotal + shipping
  • tax. This is a spend-adjacent step, so it asks for confirmation.
prava shop quote --variant-id var_123 --merchant stumptowncoffee.com --quantity 1 --address-id addr_home1 --yes
OptionRequiredDescription
--variant-id <id>Yesvariant-id from product details.
--merchant <domain>YesMerchant domain.
--quantity <n>NoQuantity (default 1).
--email <email>NoBuyer email (optional if on file).
--address-id <id>NoWhich saved address to ship to (default: the owner’s default address).
--retries <n>NoRetry on timeout / server error (default 1; 0 to disable).
-y, --yesNoConfirm. Pass only after the user has approved the seller, variant, and price.
--jsonNoRaw JSON output.
Quote for stumptowncoffee.com
  Total: $22.45 USD
  (subtotal $17.00 + shipping $4.50 + tax $0.95)
  Shipping: Standard (5–7 days)
  Expires: in ~15m
  checkout-session-id: ches_xxx

Next: mint a card session for $22.45 USD (prava sessions create … → approve → prava sessions poll), then:
  prava shop checkout --checkout-session-id ches_xxx --token <t> --cryptogram <c> --expiry-month <mm> --expiry-year <yyyy>
A quote expires (about 15 minutes) and locks the price. Get the card credentials and check out promptly. If it lapses, quote again.
Between the quote and the checkout, mint the card credentials with a payment session: prava sessions create for the quoted total → owner enters the card → prava sessions poll to get the token and cryptogram.

Checkout

Pay the quoted total with the card credentials. This is the actual charge, so it also confirms.
prava shop checkout \
  --checkout-session-id ches_xxx \
  --token 4323126882557932 --cryptogram 957 \
  --expiry-month 12 --expiry-year 2028 \
  --cardholder-name "John Doe" --yes
OptionRequiredDescription
--checkout-session-id <id>YesFrom shop quote.
--token <token>YesNetwork token from prava sessions poll.
--cryptogram <crypt>YesDynamic CVV from prava sessions poll.
--expiry-month <mm>, --expiry-year <yyyy>NoCard expiry (defaults from the session if omitted).
--cardholder-name <name>NoCardholder name.
-y, --yesNoConfirm the charge. Pass only after the user approves the final total.
--jsonNoRaw JSON output.
On success:
✓ Paid.
  Amount: $22.45 USD
  Order:  ord_abc123
The total charged is bound to the quote — it can’t drift between quote and payment. Prava pays exactly the amount you saw, at exactly the merchant you quoted.

Confirmation & safety

Both quote and checkout are gated by a confirmation:
  • At an interactive terminal, they prompt [y/N].
  • For an agent (non-interactive), they refuse unless --yes is passed — making a skipped confirmation a deliberate, visible act.
Pass --yes only after the user has actually approved the seller, item, and total. It exists to record the user’s approval, not to bypass it.

Exit codes

CodeMeaning
0Success.
1Error, declined, or not confirmed.
2Not linked / confirmation refused without --yes.
For the full list of failure messages and how to recover, see Troubleshooting.