searchfinds an item or resolves a direct URLbuystarts the purchaseactionslet you confirm, check progress, or submit a 3DS code
What you usually need
In most cases, nothing beyond the item itself:- a product URL or shopping query
- an authenticated Machines session
The shared flow
Every purchase returns anactionId. That makes the flow portable across surfaces.
You can start a purchase in one place and continue it in another:
- start in API, check status in CLI
- start in MCP, submit 3DS over API
- start in CLI, confirm from MCP
Quickstart
1. Search for a product
The simplest read-only path is a query string:POST /agent/v1/browser:
2. Start a purchase
UsePOST /agent/v1/buy to start checkout.
If the user already has a Machines card and billing profile, this is usually enough:
For Amazon orders, Machines uses the provider checkout path for you. You do not need to manage provider-specific payment steps yourself.
3. Check status
4. Confirm if needed
If the action is waiting for confirmation:If 3DS is requested
If 3DS is requested
3DS is an extra bank verification step for some purchases. It does not happen on every order, so you only need this step when the action status is
awaiting_3ds.CLI
The CLI uses the same flow and the same/agent/v1 routes.
machines search is the preferred command. machines browser still works as a compatibility alias.- if
--cardis omitted, Machines uses the user’s default active card and stored billing profile --waitand--watchkeep polling until the action pauses or finishes- raw card input is file or stdin only through
--payment-card-file
MCP and AI apps
Machines MCP uses the same flow. The user does not need to paste billing details or card numbers when their Machines account is already set up. Useful prompts:buy these apple airpods pro on amazon using my default cardsearch apple airpods pro on amazonsearch kindle paperwhite on amazonsearch ninja air fryer on amazonsearch anker usb c charger on amazoncheck the status for action 543720cb-edb5-4651-90bc-7068ce133668confirm my pending purchasesubmit this 3ds code for my purchase: 123456
machines.agent.browsermachines.agent.buymachines.agent.action_statusmachines.agent.action_confirmmachines.agent.action_submit_3ds
Request fields
Search request
Buy request
cardis a saved-card selector, such as a card label or a last 4 selector- if
cardis omitted, Machines uses the default active card - direct API and CLI flows may also accept a one-time
paymentCard, but MCP does not
More example searches
Next steps
- Machines CLI for terminal usage
- MCP Setup for AI app connections
- Consumer API Reference for the broader user API