1. Create a key
Create an organization API key in Settings > API Keys. The Standard preset covers buyers, setup and purchases. Setting allowed return origins needsorg:write, which the Admin preset includes. Keep the key on your server.
Purchases with one organization key need an @conto_finance/sdk release that includes admin.purchasing.purchases.
2. Set up a test buyer
Map one of your users to a buyer and send them to Conto’s setup page.link.url in a browser. It works once and expires in 10 minutes. On the page, confirm the spending limits, add the test card and let the agent shop with it.
The same externalId returns the same buyer, so reuse it while you test. Each buyer uses one agent in your plan.
3. Buy from a test store
4. Read the result
succeeded means the store confirmed the order. paymentEvidence reports authorization, the store’s confirmation and settlement separately.
Go live
Live purchases need Conto to enable them for your organization, a Builder or Enterprise plan, and the buyer’s own card. Until then, live setup links and live purchases are refused withLIVE_NOT_ENABLED. admin.purchasing.capabilities() reports environments.live.available for your organization.
Your code does not change for live: create the setup link without environment: 'test' and buy from a real store URL. For events in production, use webhooks instead of holding a stream open.
Build it with a coding agent
Paste this into your coding agent from your app’s repository:Next
- Conto Commerce API reference: statuses, actions, events, webhooks, errors and test stores.
- MCP tools: the purchase tools for agents that call Conto themselves.