# CodeSpar > Commerce infrastructure for AI agents in Latin America: charge, pay, invoice, notify and ship through one SDK, with mandates, signed receipts and an audit chain governing every money movement. Node SDK with csk_test_/csk_live_ keys; webhooks are called Triggers. ## Start here - [Quickstart](https://docs.codespar.dev/docs/quickstart): first charge in test mode with a csk_test_ key - [Authentication](https://docs.codespar.dev/docs/concepts/authentication): keys, projects, scopes - [Test mode](https://docs.codespar.dev/docs/concepts/test-mode): declarative mocks; live rails require csk_live_ plus a provider credential - [FAQ](https://docs.codespar.dev/docs/faq) ## Money movement - [Charge (inbound)](https://docs.codespar.dev/docs/concepts/meta-tools/charge): Pix, boleto, card charges - [Pay (outbound)](https://docs.codespar.dev/docs/concepts/meta-tools/pay): payouts, transfers, refunds - [Refunds](https://docs.codespar.dev/docs/concepts/refunds): provider refund tools, Pix devolution, the refunded event - [Wallets](https://docs.codespar.dev/docs/concepts/wallets) - [Billing](https://docs.codespar.dev/docs/concepts/billing): $0.10 per settled transaction ## Webhooks and events - [Webhooks](https://docs.codespar.dev/docs/concepts/webhooks): the name-to-primitive map, signature verification - [Triggers](https://docs.codespar.dev/docs/concepts/triggers): full reference — events, X-CodeSpar-Signature (HMAC-SHA256), retries, DLQ - [Webhook Listener cookbook](https://docs.codespar.dev/docs/cookbooks/webhook-listener) ## Governance - [Guardrails](https://docs.codespar.dev/docs/concepts/guardrails) - [Audit chain](https://docs.codespar.dev/docs/concepts/audit-chain) - [Agent trust](https://docs.codespar.dev/docs/concepts/agent-trust) - [Gate](https://docs.codespar.dev/docs/concepts/gate) and [Meter](https://docs.codespar.dev/docs/concepts/meter): agent-facing paywalls ## Cookbooks - [Pix payment agent](https://docs.codespar.dev/docs/cookbooks/pix-payment-agent) - [Marketplace payout](https://docs.codespar.dev/docs/cookbooks/marketplace-payout) - [Ecommerce checkout](https://docs.codespar.dev/docs/cookbooks/ecommerce-checkout) - [Agent with wallet](https://docs.codespar.dev/docs/cookbooks/agent-with-wallet) - [Multi-tenant](https://docs.codespar.dev/docs/cookbooks/multi-tenant) ## Reference - [Sessions](https://docs.codespar.dev/docs/concepts/sessions) - [Tool router](https://docs.codespar.dev/docs/concepts/tool-router) - [Meta-tools: Charge](https://docs.codespar.dev/docs/concepts/meta-tools/charge) - [Server catalog](https://docs.codespar.dev/docs/servers) - [CLI](https://docs.codespar.dev/docs/cli) - [Changelog](https://docs.codespar.dev/docs/changelog) ## Documentation map Every docs page, grouped. Raw markdown for any page: prefix its path with /api/docs-md on codespar.dev — both /api/docs-md/quickstart and /api/docs-md/docs/quickstart resolve. ### Getting started - [Build Your Own Server](https://docs.codespar.dev/docs/build-your-own) — Create a custom MCP server that integrates with CodeSpar's session model, billing, and tool routing. - [Changelog](https://docs.codespar.dev/docs/changelog) — Release history for the CodeSpar SDK, adapters, and MCP servers. - [Check](https://docs.codespar.dev/docs/check) — Free Agent-Ready scan. 12 public checks that tell you whether AI agents can find, read, and buy from your site, with an evidence URL for every finding and a shareable report. - [Debugging](https://docs.codespar.dev/docs/debugging) — Debug tool calls, inspect execution logs, and monitor agent performance with CodeSpar's built-in observability. - [Developer resources](https://docs.codespar.dev/docs/development) — Set up your environment, pick a client, and learn the platform pieces you build against. - [Error Reference](https://docs.codespar.dev/docs/errors) — Every error code the CodeSpar API can return, with HTTP status, the response shape, when it fires, and the fix. Aggregated across sessions, projects, connections, triggers, wallets, and auth surfaces. - [FAQ](https://docs.codespar.dev/docs/faq) — Frequently asked questions about CodeSpar -- pricing, capabilities, supported countries, security, technical details, and open source. - [Your first call](https://docs.codespar.dev/docs/first-call) — From an API key to a successful authenticated request in three curls, before you install anything. - [Glossary](https://docs.codespar.dev/docs/glossary) — Definitions for key terms and concepts used throughout the CodeSpar documentation. - [How CodeSpar Works](https://docs.codespar.dev/docs/how-it-works) — Understand how CodeSpar connects your AI agent to every major LatAm commerce API through sessions, meta-tools, and MCP servers. - [MCP Generator](https://docs.codespar.dev/docs/mcp-generator) — Automatically generate MCP server code from your existing API endpoints using CodeSpar's scanner and generator. - [Quickstart](https://docs.codespar.dev/docs/quickstart) — Get your first AI agent commerce interaction running in under 5 minutes. - [Quickstart (Buyer agent)](https://docs.codespar.dev/docs/quickstart-buyer) — Give your coding agent the power to shop and pay in Brazil — MCP-first, no code. Search a real store, hold a governed wallet, pay under a signed mandate. - [Quickstart (Python)](https://docs.codespar.dev/docs/quickstart-python) — Get a CodeSpar commerce agent running in Python — sync for scripts and Django, async for FastAPI and LangChain. Under 5 minutes. - [Quickstart: get paid](https://docs.codespar.dev/docs/quickstart-seller) — Put an x402 paywall in front of your API and take the first paid call in five minutes. - [Server catalogue](https://docs.codespar.dev/docs/servers) — Browse CodeSpar's catalog of MCP servers across payments, fiscal, logistics, messaging, banking, ERP, crypto, and agentic commerce in Latin America. - [Get help](https://docs.codespar.dev/docs/support) — What to try first, what to include when you ask, and where to ask. ### Concepts - [Agent identity and trust (KYA)](https://docs.codespar.dev/docs/concepts/agent-trust) — Verifiable agent identity (did:web + Ed25519), signed reputation, and the register / rotate / revoke key lifecycle. Know Your Agent for the money side. - [Audit chain](https://docs.codespar.dev/docs/concepts/audit-chain) — An append-only, hash-chained record of every tool call and money movement. Exactly-once, tamper-evident, and exportable for compliance. - [Authentication](https://docs.codespar.dev/docs/concepts/authentication) — API key management, service authentication, key rotation, and security best practices for the CodeSpar API. - [Billing](https://docs.codespar.dev/docs/concepts/billing) — The CodeSpar rate card — free to build, 10 bps to move money under mandate, 1% to get paid, never more than R$2.00 per transaction, R$4.90 per governed account — and how the dashboard shows what you owe. - [Connect Links](https://docs.codespar.dev/docs/concepts/connect-links) — Hosted OAuth flow that lets your end users connect their own Stripe, Mercado Pago, Shopify, and other provider accounts, without you building or maintaining a connection UI. - [Directed-pay](https://docs.codespar.dev/docs/concepts/directed-pay) — Consumer-mandate flow — accounts charge an end-consumer's rail (Pix consent, card token, TED debit-auth) under a signed, capped, revocable consent. The non-wallet half of the governed commerce primitives. - [Facilitator](https://docs.codespar.dev/docs/concepts/facilitator) — Ingest an externally-signed x402 (EIP-3009) authorization, verify it, translate it onto an internal mandate, execute it under the cap gate, and seal a receipt. - [Gate](https://docs.codespar.dev/docs/concepts/gate) — Gate is the x402 gateway. Put an x402 paywall in front of any API or MCP server and get paid in USDC on Base. Share a gateway URL, charge agents per call, no signup, no card, no session. - [Guardrails](https://docs.codespar.dev/docs/concepts/guardrails) — The policy layer that gates every agent tool call before it dispatches, spend budgets, rate limits, and human approval, enforced server-side. - [Meter](https://docs.codespar.dev/docs/concepts/meter) — Post-paid metered pricing on a Gate paywall. The buyer signs a spending ceiling once, your upstream reports the actual work in a response header, and the difference is refunded on-chain automatically. - [Pay to Agent](https://docs.codespar.dev/docs/concepts/pay-to-agent) — Pay another agent by Agent ID instead of a raw address. The recipient must be a registered, non-revoked identity — never an anonymous wallet. Payouts, splits, and tips over USDC on Base mainnet. - [Projects](https://docs.codespar.dev/docs/concepts/projects) — Projects are the second level of CodeSpar's 2-level tenancy model -- an isolation boundary inside an account for API keys, connections, triggers, sessions, and events. - [Refunds](https://docs.codespar.dev/docs/concepts/refunds) — How money goes back: outbound refunds through codespar_pay, provider-level refund tools such as Pix devolution, and the commerce.payment.refunded trigger event that tells your backend it happened. - [Sessions](https://docs.codespar.dev/docs/concepts/sessions) — Sessions are scoped connections to MCP servers that manage tool access, authentication, and usage tracking for AI agent commerce operations. - [Shopper Identity](https://docs.codespar.dev/docs/concepts/shopper-identity) — Connect-once + vaulted shopper identity — let a shopper connect a login-walled store once, or vault a guest-checkout profile, so an agent can buy on their behalf without re-asking. Per-consumer, inbound, credentials never exposed. - [Test Mode](https://docs.codespar.dev/docs/concepts/test-mode) — Hosted test mode lets you run an agent against the CodeSpar runtime with inline mock declarations — deterministic responses, no provider OAuth, full Guardrails governance. Declare mocks at session create; assert on the round-trip in your tests. - [Tool Router](https://docs.codespar.dev/docs/concepts/tool-router) — Route tool calls and raw HTTP requests through a managed session. Auth is injected server-side, so your agent never touches provider credentials. - [Why meta-tools](https://docs.codespar.dev/docs/concepts/tools) — CodeSpar provides 15 meta-tools that abstract every connected MCP server into a unified commerce interface, reducing context window cost and simplifying agent development. - [Triggers](https://docs.codespar.dev/docs/concepts/triggers) — Triggers are CodeSpar's outbound webhook subscriptions. Your app receives signed HTTP callbacks when asynchronous events settle (payment succeeded, invoice issued, notification delivered) or when the platform itself changes state. - [Wallets](https://docs.codespar.dev/docs/concepts/wallets) — Programmable wallets — per-agent fund pools with mandate-gated debits, multi-rail funding (Pix, card, USDC, BRLA), and automatic reconciliation. Governed by Guardrails in the managed tier. - [Webhooks](https://docs.codespar.dev/docs/concepts/webhooks) — CodeSpar's webhooks are called Triggers: signed HTTP callbacks (X-CodeSpar-Signature, HMAC-SHA256) delivered when payments settle, fail, or refund. This page maps the name you searched for to the primitive. ### Meta-tools (by side: see the tool list above) - [codespar_charge](https://docs.codespar.dev/docs/concepts/meta-tools/charge) — Inbound charges, the buyer pays the merchant. An immediate Pix, a cobrança com vencimento (boleto or Pix, with a due date), hosted card checkout or a wallet redirect; then read or cancel what you issued. - [codespar_checkout](https://docs.codespar.dev/docs/concepts/meta-tools/checkout) — Sell-side merchant checkout. Assemble a cart and create a charge for a shopper to pay you, returned with a hosted payment page and, on Pix, the copia-e-cola. Pix in Brazil is the live rail today. - [codespar_crypto_pay](https://docs.codespar.dev/docs/concepts/meta-tools/crypto-pay) — Send or receive a crypto payment through a connected provider rail. Stablecoin checkout on Coinbase Commerce, BR rails on Bitso and Foxbit, and cross-border ramps via the on/offramp partner. - [codespar_discover](https://docs.codespar.dev/docs/concepts/meta-tools/discover) — Find the right tool for a free-form use case. Returns the recommended catalog tool with its connection status, pitfalls, plan and related tools, plus any native meta-tool that covers the same job. - [codespar_get_started](https://docs.codespar.dev/docs/concepts/meta-tools/get-started) — Read-only setup planner. Returns the ordered happy path for the authenticated workspace, covering which rails are already connected, what to connect next, and the first calls to try. Moves no money. - [Hosted MCP server](https://docs.codespar.dev/docs/concepts/meta-tools) — One hosted MCP URL gives any agent 15 meta-tools for money in Brazil and Latin America. Connect Claude Code, Claude Desktop, Cursor, Windsurf or your own MCP client in a minute, under a signed mandate. - [codespar_invoice](https://docs.codespar.dev/docs/concepts/meta-tools/invoice) — Fiscal documents. Issue, read, or amend an NF-e, NFS-e, or an international invoice; the Brazilian fiscal rail for nfe and nfse, Stripe Invoicing internationally. - [codespar_issue](https://docs.codespar.dev/docs/concepts/meta-tools/issue) — Issue and control payment cards for AI agents or end-users. Virtual and physical cards, freeze, unfreeze and cancel, through the card-issuing partner (pan-LATAM issuing). Creates spend instruments; it does not move money. - [codespar_kyc](https://docs.codespar.dev/docs/concepts/meta-tools/kyc) — Identity verification, or open a payments account. Persona, Sift, Konduto and Truora for checks; the licensed BaaS partner for onboarding, which verifies the consumer AND provisions the account that funds codespar_wallet. - [codespar_ledger](https://docs.codespar.dev/docs/concepts/meta-tools/ledger) — Double-entry ledger. Record money movement, read balances, create accounts, and read the signed agentic receipt of a spend. Routes to the tenant's self-hosted Lerian Midaz; the books, not the money. - [codespar_manage_connections](https://docs.codespar.dev/docs/concepts/meta-tools/manage-connections) — List, inspect or connect the accounts and identity the agent needs. Dashboard connect deep-links for API-key and OAuth providers, a one-time login for login-walled stores, and the buyer's vaulted checkout identity for guest-checkout stores. - [codespar_notify](https://docs.codespar.dev/docs/concepts/meta-tools/notify) — Send notifications via WhatsApp, email or SMS. Z-API for WhatsApp in Brazil, Twilio for SMS and international WhatsApp, SendGrid for email. - [codespar_pay](https://docs.codespar.dev/docs/concepts/meta-tools/pay) — Outbound spend. Money leaves the wallet or account your agent governs, under a signed mandate. Pix, card, boleto settlement, TED and wire, plus the reads around them (status, boleto quote, DDA, DICT keys and claims, Pix devolution). - [codespar_ship](https://docs.codespar.dev/docs/concepts/meta-tools/ship) — Quote, label or track a shipment. Brazilian domestic shipping on Melhor Envio (Correios and private carriers) behind a neutral origin, destination and items shape; the router picks the cheapest carrier per request. - [codespar_shop](https://docs.codespar.dev/docs/concepts/meta-tools/shop) — Buy-side shopping. Act as the shopper, search a store's live catalog and buy, minting the store's real Pix copia-e-cola to settle from the governed wallet. VTEX guest checkout and Mercado Livre. - [codespar_wallet](https://docs.codespar.dev/docs/concepts/meta-tools/wallet) — The agent's governed funds. Read the balance and Pix key, read the wallet ledger, or mint a Pix copia-e-cola to top the wallet up. Buy-side companion to codespar_pay. ### API reference - [@codespar/api-types](https://docs.codespar.dev/docs/api/api-types) — Zod schemas + TypeScript types for every /v1/* REST shape on api.codespar.dev. Used internally by the SDK and dashboard; published for callers building HTTP clients directly. - [Tool calls over HTTP](https://docs.codespar.dev/docs/api/tools) — HTTP API reference for listing, searching, and inspecting tool definitions available in a CodeSpar session. ### Cookbooks (recipes) - [Agent with a Wallet](https://docs.codespar.dev/docs/cookbooks/agent-with-wallet) — Walkthrough of Programmable Wallets: create a wallet, bind an Asaas funding source, fund via sandbox Pix, and see what the mandate-gated execute path does today. ~15 minutes. - [Crypto Pay Agent](https://docs.codespar.dev/docs/cookbooks/crypto-pay-agent) — Generate a stablecoin payment URL via codespar_crypto_pay (Coinbase Commerce default), share with the user, watch for settlement webhook or paymentStatus. - [E-Commerce Checkout](https://docs.codespar.dev/docs/cookbooks/ecommerce-checkout) — Brazilian e-commerce flow — buyer pays via Pix, NF-e gets issued, label generated, customer notified on WhatsApp. Same shape that ships in codespar-core/examples/brazilian-ecommerce. - [Cookbooks](https://docs.codespar.dev/docs/cookbooks) — End-to-end recipes you can copy into production. Each cookbook is a small working agent that solves one real commerce problem, wired through the CodeSpar SDK. - [Marketplace Payout](https://docs.codespar.dev/docs/cookbooks/marketplace-payout) — Split a marketplace transaction into platform fee + seller payout. One agent, two settled transactions, full audit trail. - [Multi-Tenant Agent](https://docs.codespar.dev/docs/cookbooks/multi-tenant) — Build a SaaS where each customer runs their own commerce agent with their own providers and credentials. Sessions are scoped per tenant — isolated by design, metered per tenant for billing. - [Pix Payment Agent](https://docs.codespar.dev/docs/cookbooks/pix-payment-agent) — The simplest agent you can build with CodeSpar. Create a Pix charge, generate a QR code, and send it to the customer via WhatsApp — in ~50 lines of code. - [Shopping Agent](https://docs.codespar.dev/docs/cookbooks/shopping-agent) — A buy-side agent that searches a real store, drives the store's checkout, and pays the resulting Pix from its governed wallet under a signed mandate. - [Webhook Listener](https://docs.codespar.dev/docs/cookbooks/webhook-listener) — React to payment webhooks with a deterministic loop. On commerce.payment.succeeded, automatically issue an NF-e, create shipping, and send WhatsApp. No agent, no LLM, no surprise. - [Webhook Providers Reference](https://docs.codespar.dev/docs/cookbooks/webhook-providers) — Per-provider inbound webhook signature schemes — HMAC-SHA256, ECDSA P-256, HTTP Basic, shared-secret. For self-hosters and operators verifying provider events. ### api/reference - [Account Applications](https://docs.codespar.dev/docs/api/reference/account-applications) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under account-applications. - [Agents](https://docs.codespar.dev/docs/api/reference/agents) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under agents. - [Approvals](https://docs.codespar.dev/docs/api/reference/approvals) — Generated HTTP reference for the 3 operations the published OpenAPI document describes under approvals. - [Audit](https://docs.codespar.dev/docs/api/reference/audit) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under audit. - [Audit Events](https://docs.codespar.dev/docs/api/reference/audit-events) — Generated HTTP reference for the 6 operations the published OpenAPI document describes under audit-events. - [Bank consents](https://docs.codespar.dev/docs/api/reference/bank-consents) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under bank-consents. - [Cards](https://docs.codespar.dev/docs/api/reference/cards) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under cards. - [Cart](https://docs.codespar.dev/docs/api/reference/cart) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under cart. - [Commerce Memory](https://docs.codespar.dev/docs/api/reference/commerce-memory) — Generated HTTP reference for the 12 operations the published OpenAPI document describes under commerce-memory. - [Connect](https://docs.codespar.dev/docs/api/reference/connect) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under connect. - [Connections](https://docs.codespar.dev/docs/api/reference/connections) — Generated HTTP reference for the 10 operations the published OpenAPI document describes under connections. - [Consent Records](https://docs.codespar.dev/docs/api/reference/consent-records) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under consent-records. - [Consumer Mandates](https://docs.codespar.dev/docs/api/reference/consumer-mandates) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under consumer-mandates. - [Consumers](https://docs.codespar.dev/docs/api/reference/consumers) — Generated HTTP reference for the 5 operations the published OpenAPI document describes under consumers. - [Contact Verifications](https://docs.codespar.dev/docs/api/reference/contact-verifications) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under contact-verifications. - [Counterparties](https://docs.codespar.dev/docs/api/reference/counterparties) — Generated HTTP reference for the 3 operations the published OpenAPI document describes under counterparties. - [Boletos you owe (DDA)](https://docs.codespar.dev/docs/api/reference/dda) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under dda. - [Discovery](https://docs.codespar.dev/docs/api/reference/discovery) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under discovery. - [Evaluations](https://docs.codespar.dev/docs/api/reference/evaluations) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under evaluations. - [Events](https://docs.codespar.dev/docs/api/reference/events) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under events. - [Facilitator](https://docs.codespar.dev/docs/api/reference/facilitator) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under facilitator. - [Funding](https://docs.codespar.dev/docs/api/reference/funding) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under funding. - [Funding Sources](https://docs.codespar.dev/docs/api/reference/funding-sources) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under funding-sources. - [Generate](https://docs.codespar.dev/docs/api/reference/generate) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under generate. - [Health](https://docs.codespar.dev/docs/api/reference/health) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under health. - [Overview](https://docs.codespar.dev/docs/api/reference) — Base URL, authentication, errors and conventions — plus what this document does not describe. - [Issuer](https://docs.codespar.dev/docs/api/reference/issuer) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under issuer. - [KYC](https://docs.codespar.dev/docs/api/reference/kyc) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under kyc. - [Mandates](https://docs.codespar.dev/docs/api/reference/mandates) — Generated HTTP reference for the 5 operations the published OpenAPI document describes under mandates. - [MCP Servers](https://docs.codespar.dev/docs/api/reference/mcp-servers) — Generated HTTP reference for the 8 operations the published OpenAPI document describes under mcp-servers. - [Meta Tools](https://docs.codespar.dev/docs/api/reference/meta-tools) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under meta-tools. - [OAuth](https://docs.codespar.dev/docs/api/reference/oauth) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under oauth. - [Bank consents (legacy /ofb path)](https://docs.codespar.dev/docs/api/reference/ofb) — Generated HTTP reference for the 5 operations the published OpenAPI document describes under ofb. - [Spec](https://docs.codespar.dev/docs/api/reference/openapi-json) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under openapi.json. - [Organizations](https://docs.codespar.dev/docs/api/reference/organizations) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under organizations. - [Orgs](https://docs.codespar.dev/docs/api/reference/orgs) — Generated HTTP reference for the 15 operations the published OpenAPI document describes under orgs. - [Payment Links](https://docs.codespar.dev/docs/api/reference/payment-links) — Generated HTTP reference for the 5 operations the published OpenAPI document describes under payment-links. - [Paywalls](https://docs.codespar.dev/docs/api/reference/paywalls) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under paywalls. - [Pix out](https://docs.codespar.dev/docs/api/reference/pix-devolutions) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under pix-devolutions. - [Pix keys (DICT)](https://docs.codespar.dev/docs/api/reference/pix-keys) — Generated HTTP reference for the 3 operations the published OpenAPI document describes under pix-keys. - [Pix in](https://docs.codespar.dev/docs/api/reference/pix-status) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under pix-status. - [Policies](https://docs.codespar.dev/docs/api/reference/policies) — Generated HTTP reference for the 6 operations the published OpenAPI document describes under policies. - [Policy Evaluations](https://docs.codespar.dev/docs/api/reference/policy-evaluations) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under policy-evaluations. - [Projects](https://docs.codespar.dev/docs/api/reference/projects) — Generated HTTP reference for the 8 operations the published OpenAPI document describes under projects. - [Providers](https://docs.codespar.dev/docs/api/reference/providers) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under providers. - [Receipts](https://docs.codespar.dev/docs/api/reference/receipts) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under receipts. - [Schemas](https://docs.codespar.dev/docs/api/reference/schemas) — The 23 object schemas the published OpenAPI document defines. - [Sellers](https://docs.codespar.dev/docs/api/reference/sellers) — Generated HTTP reference for the 6 operations the published OpenAPI document describes under sellers. - [Servers](https://docs.codespar.dev/docs/api/reference/servers) — Generated HTTP reference for the 4 operations the published OpenAPI document describes under servers. - [Sessions](https://docs.codespar.dev/docs/api/reference/sessions) — Generated HTTP reference for the 12 operations the published OpenAPI document describes under sessions. - [Tool Calls](https://docs.codespar.dev/docs/api/reference/tool-calls) — Generated HTTP reference for the 6 operations the published OpenAPI document describes under tool-calls. - [Triggers](https://docs.codespar.dev/docs/api/reference/triggers) — Generated HTTP reference for the 10 operations the published OpenAPI document describes under triggers. - [Wallets](https://docs.codespar.dev/docs/api/reference/wallets) — Generated HTTP reference for the 15 operations the published OpenAPI document describes under wallets. - [Webhook Endpoints](https://docs.codespar.dev/docs/api/reference/webhook-endpoints) — Generated HTTP reference for the 10 operations the published OpenAPI document describes under webhook-endpoints. - [Well-known documents](https://docs.codespar.dev/docs/api/reference/well-known) — Generated HTTP reference for the 2 operations the published OpenAPI document describes under .well-known. - [Whoami](https://docs.codespar.dev/docs/api/reference/whoami) — Generated HTTP reference for the 1 operation the published OpenAPI document describes under whoami. ### api/sdk - [Overview](https://docs.codespar.dev/docs/api/sdk) — The TypeScript client: install, construct, open a session. - [Session](https://docs.codespar.dev/docs/api/sdk/session) — Every method on an open session, with its arguments and result. - [Types](https://docs.codespar.dev/docs/api/sdk/types) — The shapes the methods take and return. ### api/sdk/providers - [AutoGen](https://docs.codespar.dev/docs/api/sdk/providers/autogen) — Use @codespar/autogen to give Microsoft AutoGen agents commerce capabilities in Latin America. - [CAMEL-AI](https://docs.codespar.dev/docs/api/sdk/providers/camel) — Use @codespar/camel to give CAMEL-AI role-playing agents commerce capabilities in Latin America. - [Claude](https://docs.codespar.dev/docs/api/sdk/providers/claude) — Use @codespar/claude to give Anthropic Claude agents commerce capabilities in Latin America. - [CrewAI](https://docs.codespar.dev/docs/api/sdk/providers/crewai) — Use @codespar/crewai to give CrewAI agent crews commerce capabilities in Latin America. - [Google Gemini](https://docs.codespar.dev/docs/api/sdk/providers/google-genai) — Use @codespar/google-genai to give Google Gemini agents commerce capabilities in Latin America. - [Hermes](https://docs.codespar.dev/docs/api/sdk/providers/hermes) — Use @codespar/hermes to give Hermes Agent (Nous Research) a LATAM commerce rail. - [Provider Adapters](https://docs.codespar.dev/docs/api/sdk/providers) — Drop-in adapters that wire CodeSpar sessions into your existing agent framework — Claude, OpenAI, Vercel AI SDK, LangChain, Mastra, and 6 more. - [LangChain](https://docs.codespar.dev/docs/api/sdk/providers/langchain) — Use @codespar/langchain to give LangChain.js agents commerce capabilities in Latin America. - [Letta](https://docs.codespar.dev/docs/api/sdk/providers/letta) — Use @codespar/letta to give Letta (MemGPT) agents commerce capabilities in Latin America. - [LlamaIndex](https://docs.codespar.dev/docs/api/sdk/providers/llama-index) — Use @codespar/llama-index to give LlamaIndex.TS agents commerce capabilities in Latin America. - [Mastra](https://docs.codespar.dev/docs/api/sdk/providers/mastra) — Use @codespar/mastra to give Mastra agents commerce capabilities in Latin America. - [MCP](https://docs.codespar.dev/docs/api/sdk/providers/mcp) — The @codespar/mcp package runs the CodeSpar MCP server locally over stdio, for clients that cannot reach the hosted server or that want the key in a local environment variable. Install, setup mode, config helpers, troubleshooting. - [OpenAI](https://docs.codespar.dev/docs/api/sdk/providers/openai) — Use @codespar/openai to give GPT agents commerce capabilities in Latin America. - [Vercel AI SDK](https://docs.codespar.dev/docs/api/sdk/providers/vercel) — Use @codespar/vercel to integrate CodeSpar tools with the Vercel AI SDK for streaming agent interactions. ### cli - [Commands](https://docs.codespar.dev/docs/cli/commands) — Every command, with its flags and output. - [Configuration](https://docs.codespar.dev/docs/cli/config) — Configuration, scripting and debugging. - [Overview](https://docs.codespar.dev/docs/cli) — Install the CLI and authenticate it.