WooCommerce and a feed storefront — 15 minutes · SDKs — about an hour · 4 ways · not just WordPress
A custom store or Laravel — agentic commerce plugs in with a Composer package and ~50 lines of adapter. MIT, zero dependencies, PHP ≥ 8.1.
composer require botmetria/ucp
Two lines at the very top of your front controller (index.php), before your routing:
use Botmetria\Ucp\Ucp;
use Botmetria\Ucp\ArrayProductProvider;
$ucp = new Ucp([
'store_name' => 'My Shop',
'store_url' => 'https://my-shop.com/',
'currency' => 'EUR',
'products' => new MyProducts(), // ProductProviderInterface
// 'cart' => new MyCart(), // CartProviderInterface: agent checkout
]);
$ucp->run(); // serves /.well-known/ucp and /ucp/v1/*Implement ProductProviderInterface — agents see your catalog, the manifest honestly reports checkout:false.
Add CartProviderInterface::fill() — the agent builds a cart, the shopper pays in your native checkout.
Laravel — a middleware in the global stack; Slim/Mezzio — a PSR-15 middleware; plain PHP — $ucp->run() in the front controller. Examples live in the package README.
To count AI bots, drop in the PHP collector from your dashboard (section “Connection”). Honest note: on PHP the collector counts traffic but does not block — blocking works in the WooCommerce plugin and the Node collector.
The manifest on your domain plus the live purchase demo:
curl https://your-store.com/.well-known/ucp
Package and sources: Packagist · GitHub · UCP spec & self-hosting