UCP: A Layered Protocol for Agent-Driven Commerce
Shopify and Google have co-developed the Universal Commerce Protocol (UCP), an open standard designed to let AI agents discover, negotiate, and complete transactions with any merchant. The protocol is a response to a long-standing problem: commerce is universal but far from uniform. Payment rules shift with cart contents, buyer location, and market; discount stacking rivals tax law; fulfillment options multiply across shipping, pickup, and delivery. That complexity is an emergent property of diverse retailers, not a defect to be engineered away.
UCP addresses it by letting merchants declare the capabilities they support—including bespoke functionality—while agents advertise what they can handle. The protocol provides the discovery and negotiation mechanisms between the two, plus the core primitives that make commerce programmable for both agents and humans.
Capabilities and Extensions
Rather than a monolithic spec, UCP borrows a page from TCP/IP and layers responsibilities with clear APIs:
- Shopping service defines core transaction primitives: checkout session, line items, totals, messages, and status.
- Capabilities add major functional areas—Checkout, Orders, Catalog—each independently versioned.
- Extensions augment capabilities with domain-specific schemas via composition.
Extensions are where UCP handles reality. The dev.ucp.shopping.fulfillment extension covers common fulfillment cases, but it doesn't—and can't—cover every possibility: split shipments, pre-orders, delivery windows, and subscription schedules are all shapes fulfillment can take. Merchants with specialized needs can define their own extensions, or the protocol can evolve new ones as patterns mature.
Extensions compose with the core schema. The core checkout schema defines universal primitives and knows nothing about fulfillment groups or shipping options; the fulfillment extension adds them by extending the core data model. When it adds delivery windows later, it versions independently while core stays stable. Merchants implement only what they need; agents negotiate only what they can handle.
Discovery and Negotiation
Both merchants and agents publish profiles declaring their capabilities. Discovery is the process of fetching these profiles; negotiation computes their intersection.
A merchant publishes its profile at /.well-known/ucp. Agents also declare their capabilities and pass their profile URL with each request. The merchant computes the intersection—which capabilities both support, which handlers overlap, which extensions are mutually understood—and responds with the negotiated result. It's the same pattern HTTP uses with accept headers and content types.
Namespaces follow reverse-domain naming. dev.ucp.shopping.* is hosted at ucp.dev; a third-party like loyaltyprovider.com can define com.loyaltyprovider.points without anyone's permission. Each side validates advertised capabilities and their provenance: security through namespace binding, not central registry or approval committees.
An agent that doesn't support a merchant's loyalty extension simply won't see loyalty fields. One that does can negotiate reward options or redeem points. The same merchant endpoint serves both, shaped by negotiation. When the merchant requires something the agent can't provide, the agent fills what it can, and the transaction routes to a human.
Routing Around Capability Gaps
Some checkouts complete entirely via API. Others require human involvement: regulatory constraints, merchant policies, or capabilities an agent doesn't yet support. UCP models this with a simple checkout state machine:
incomplete: missing required information; the agent should attempt to resolve it via APIrequires_escalation: buyer input is required; the agent should attempt API resolution and, if unable, hand off viacontinue_urlready_for_complete: all information collected; the agent can finalize programmatically
When a transaction can't proceed autonomously, the merchant response includes structured context and a continuation URL. The buyer follows it and picks up exactly where the agent left off, so no transaction is abandoned at a capability gap.
Handoff becomes seamless with the Embedded Checkout Protocol (ECP). When escalation is required, the agent renders embedded checkout by loading the continue_url. ECP establishes a JSON-RPC 2.0 channel: state updates flow from the merchant, credentials and context from the agent. Payment collection surfaces the host's native payment sheet; address selection pulls from the agent's wallet. The protocol is distilled from Shopify's Checkout Kit, which has operated embedded checkout at scale, and pairs with sandboxing for PCIv4 compliance.
Payments as a Two-Sided Negotiation
Merchants optimize their PSP relationships over years: routing rules, fraud models, regional coverage. Buyers have their own preferences: saved cards, wallets, buy-now-pay-later. UCP treats every transaction as a dynamic negotiation between both.
The agent profile specifies what credentials it can provide; the merchant responds with available payment handlers for the specific cart. Handlers shift based on cart contents, buyer location, or transaction amount. In a typical negotiation, Shop Pay and Google Pay might both be supported by merchant and agent—it's then the buyer's choice which to use. Change any variable and the available handlers may shift.
Payment handlers invert the usual integration burden. Rather than the protocol defining every payment method, each provider publishes its own handler specification. The merchant advertises which handlers it accepts; the agent picks one and follows its spec. New payment methods enter the ecosystem without committee votes or core version bumps.
Open for Business
UCP is co-developed with Google and supported by Etsy, Target, Walmart, Wayfair, and millions of Shopify merchants. The spec is public, the repository is open for contribution, and agents can build against it today. The goal is a protocol that models commerce's complexity, evolves without breaking, and keeps pace with agentic commerce as it matures.



