Skip to Content
Reference

Reference

URLs

ThingProductionDev
Bridge MCPhttps://agent.artos.sh/mcphttps://agent.dev.artos.sh/mcp
API / OAuth AS issuerhttps://api.artos.shhttps://api.dev.artos.sh
Global catalog MCP (Direct)https://api.artos.sh/mcphttps://api.dev.artos.sh/mcp
Per-store MCP (Direct)https://api.artos.sh/s/:slug/mcpsame shape
OAuth tokenhttps://api.artos.sh/ucp/oauth2/tokenhttps://api.dev.artos.sh/ucp/oauth2/token
AS metadatahttps://api.artos.sh/.well-known/oauth-authorization-serversame shape
Discoveryhttps://api.artos.sh/s/:slug/.well-known/ucpsame shape
Consenthttps://my.artos.sh/oauth/consenthttps://my.dev.artos.sh/oauth/consent
Agent profile / CIMDprofile-artos.vercel.appsame

SDK (Path B)

@artos-commerce/ucp-clientnpm install @artos-commerce/ucp-client (Node 20+; optional @mysten/sui peer for crypto).

ExportPurpose
UcpClientTyped transport: globalSearch, callGlobalTool, callStoreTool, listAccountTools, callAccountTool, fetchStoreProfile, fetchImage, hasBuyerToken, ucpAgentHeader
Ap2SignermintCheckoutMandate, mintPaymentMandate (compact ES256 JWS)
createCheckoutHandlersRead tools + confirmPurchase (one-call card / crypto / $0)
resolveCryptoDeps, SuiSignerCrypto rail — sign + submit the Sui PTB (need @mysten/sui)
canonicalJson, verifyDetachedJws, verifyMerchantAuthorizationByte-parity canonical JSON + AP2 verification
toMinorUnits, normalizeSearchFilters, resolveRail, grandTotal, currencyOf, asAllowanceId, isUcpError, messageOfHelpers

Subpath entries: @artos-commerce/ucp-client/{ucp,ap2,checkout,sui,crypto}.

Bridge tool catalog (Path A)

Flat inputs; the bridge adds the UCP envelope. Price filters use major units (dollars).

ToolInputAuth
search_productsquery?, filters?, sort?, pagination?Platform key
lookup_productsids: string[]Platform key
view_productstore_slug, idPlatform key
get_product_globalid, selected?Platform key
create_cartstore_slug, items: [{ id, quantity }]Platform key
update_cartstore_slug, id, itemsPlatform key
view_cartstore_slug, idPlatform key
create_checkoutstore_slug, cart_id? | items?, buyer?, shipping_address?Platform key
update_checkoutstore_slug, id, buyer?, shipping_address?, shipping_method_id?, discounts?Platform key
confirm_purchasestore_slug, checkout_id, payment_method?, payment_mandate_id?Platform key (+ buyer bearer for crypto)
get_orderstore_slug, idPlatform key + orders:read
get_agent_identityNone (local)
Buyer account toolssee Buyer accountBuyer bearer (proxied)

fetch_image exists but is widget-only (hidden).

Bridge → raw UCP mapping (Path B)

Bridge toolRaw UCP toolEndpoint
search_productssearch_catalog/mcp (global)
lookup_productslookup_catalog/mcp (global)
get_product_globalget_product/mcp (global)
view_productget_product/s/:slug/mcp
create_cart / update_cart / view_cartcreate_cart / update_cart / get_cart/s/:slug/mcp
create_checkout / update_checkoutcreate_checkout / update_checkout/s/:slug/mcp
confirm_purchasecomplete_checkout (+ prepare_checkout_payment for crypto)/s/:slug/mcp
get_orderget_order/s/:slug/mcp

Raw UCP differences (see Direct UCP): args wrapped under catalog/cart/checkout; line items { item: { id }, quantity }; price filters in minor units; rails selected by inner id artos.card / artos.crypto (not the sh.artos.* registry key).

Transport headers (Direct UCP)

Required on the UCP shopping surfaces (/mcp, /s/:slug/mcp, REST /s/:slug/...). The buyer-account surface (/account/mcp) needs none of these — it is bearer-scoped.

HeaderWhenMCPREST
Request-IdEvery callrequiredrequired
UCP-Agent: profile="…"Every shopping callrequired (+ body meta["ucp-agent"].profile)required
Idempotency-KeyState-changing callsuse body meta["idempotency-key"] insteadrequired (header)

REST paths (Direct UCP)

OperationMethod + path
Global catalog searchPOST /catalog/search
Per-store catalog… /s/:slug/catalog
Cart… /s/:slug/carts
CheckoutPOST /s/:slug/checkout-sessions, …/:id (GET/PUT), …/:id/complete, …/:id/payment-intent, …/:id/cancel
Orders… /s/:slug/orders

OAuth grants

POST /ucp/oauth2/token (form-urlencoded):

GrantRequired params
authorization_codecode, code_verifier, client_id, redirect_uri
refresh_tokenrefresh_token (rotated, single-use)
client_credentialsclient_id, client_secret (post or Basic)

Scopes: purchase:complete, orders:read, offline_access.

Error signals

Code / signalMeaningFix
invalid_api_keyUnknown/revoked platform keySeed/rotate the platform credential
invalid_tokenExpired/invalid bearerRefresh via OAuth (refresh_token)
missing_request_idNo Request-Id headerSend a unique Request-Id per call
missing_ucp_agent / invalid_ucp_agentNo/malformed UCP-Agent headerSend UCP-Agent: profile="…"
missing_idempotency_keyState-changing REST call without the headerSend an Idempotency-Key header
invalid_profile_urlMalformed agent profile URLSend a valid profile URL
insufficient_trustTier too low for the operationAuthenticate (token tier)
insufficient_scopeMissing required scopeRequest purchase:complete / orders:read
payment_selection_requiredMultiple rails, none chosenRead ucp.payment_handlers, retry with payment_method
mandate_expiredAP2 exp missing/pastMint a fresh mandate
mandate_scope_mismatchMandate merchant ≠ storeBind the mandate to the store slug
UCP error envelopeBusiness outcome (often HTTP 200, ucp.status: error)Read messages[] and severity

Webhook events

See Orders → Lifecycle webhooks.

Spec & schemas

artos-api/ucp-spec  — UCP schemas, services, and documentation.

Last updated on