Agent Integration
Claude Commerce Agents on Kifly
Anthropic's commerce-agents blueprint leaves the StorefrontBackend interface for you to fill with a catalog, cart and payments. Kifly can back it.
Method mapping
StorefrontBackend method | Kifly endpoint |
|---|---|
search_products | GET /api/agent/search |
get_cart | GET /api/agent/cart/{cart_id} |
add_to_cart | POST /api/agent/cart/{cart_id}/items |
update_cart_item / remove_from_cart | PATCH / DELETE /api/agent/cart/{cart_id}/items/{item_id} |
checkout_handoff | POST /api/agent/cart/{cart_id}/checkout, one CheckoutHandoff per seller |
get_preferences / get_orders | GET /api/agent/buyer/me, GET /api/agent/buyer/orders |
get_fulfillment_options | GET /api/agent/seller |
search_policies | Not provided. Return []. |
Three things to get right
- Price units. Search results are in major units (
offers.price). Carts are in cents (unit_price_cents). Don't mix them, or a $28 item is quoted at 28 cents. - One cart per seller. Keep a
seller_handle: cart_idmap per session. - Variants.
add_to_carttakeskifly:variantId, not @id.
On a 5xx or timeout, raise. Never return an empty list, or the agent will tell the shopper the store carries nothing.
Authentication and keys: see MCP Integration. For a reference implementation, get in touch.