{"openapi":"3.1.0","info":{"title":"Clash of Coins API","version":"1.0.0","summary":"Agentic checkout for Clash of Coins","description":"Agentic checkout for Clash of Coins","guidance":"Start with GET /api/shop/items or the protocol-specific offers endpoint. You may omit nickname and address to read the general catalog, or provide exactly one identifier to read personalized offers for that user. Then submit a quote or buy request with exactly one recipient identifier. shop x402 requires itemId plus optional quantity, while Tempo MPP also supports multi-item carts through items[]. For Tempo MPP, prefer the canonical mppx SDK instead of manual Authorization: Payment credentials. Poll purchase status if delivery remains pending.","x-guidance":"Start with GET /api/shop/items or the protocol-specific offers endpoint. You may omit nickname and address to read the general catalog, or provide exactly one identifier to read personalized offers for that user. Then submit a quote or buy request with exactly one recipient identifier. shop x402 requires itemId plus optional quantity, while Tempo MPP also supports multi-item carts through items[]. For Tempo MPP, prefer the canonical mppx SDK instead of manual Authorization: Payment credentials. Poll purchase status if delivery remains pending."},"servers":[{"url":"https://mpp.clashofcoins.app/shop","description":"Canonical Clash of Coins checkout origin"}],"tags":[{"name":"Gaming","description":"Clash of Coins gaming commerce endpoints"},{"name":"mpp","description":"Canonical shop MPP purchase flow"}],"paths":{"/api/shop/items":{"get":{"summary":"List active game shop items","parameters":[{"name":"nickname","in":"query","required":false,"schema":{"type":"string"}},{"name":"address","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Catalog response"},"400":{"description":"Invalid recipient query. Provide either nickname or address, not both."}}}},"/shop/mpp/offers":{"get":{"summary":"List active game shop items for Tempo MPP checkout","parameters":[{"name":"nickname","in":"query","required":false,"schema":{"type":"string"}},{"name":"address","in":"query","required":false,"schema":{"type":"string"}}],"responses":{"200":{"description":"Active shop items. Omitting nickname and address returns the general catalog; providing one returns personalized offers for that user."},"400":{"description":"Invalid recipient query. Provide either nickname or address, not both."}}}},"/shop/mpp/quote":{"post":{"summary":"Quote a game shop purchase through Tempo MPP","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"nickname":{"type":"string","description":"Clash of Coins player nickname that should receive delivery"},"address":{"type":"string","description":"Optional EVM address used to resolve and verify the recipient"},"itemId":{"type":"string","description":"Single-item shorthand for buying one catalog item"},"quantity":{"type":"integer","minimum":1,"default":1,"description":"Quantity used together with itemId shorthand"},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["itemId"],"properties":{"itemId":{"type":"string"},"quantity":{"type":"integer","minimum":1,"default":1}}}}},"oneOf":[{"required":["nickname","items"]},{"required":["address","items"]},{"required":["nickname","itemId"]},{"required":["address","itemId"]}]},"example":{"nickname":"PlayerOne","items":[{"itemId":"a-units-pack:1","quantity":1}]}}}},"responses":{"200":{"description":"Purchase quote"},"400":{"description":"Invalid request"}}}},"/shop/mpp/buy":{"post":{"operationId":"buyShopMppFull","tags":["Gaming","mpp"],"summary":"Buy a Clash of Coins game shop item with Tempo MPP","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"nickname":{"type":"string","description":"Clash of Coins player nickname that should receive delivery"},"address":{"type":"string","description":"Optional EVM address used to resolve and verify the recipient"},"itemId":{"type":"string","description":"Single-item shorthand for buying one catalog item"},"quantity":{"type":"integer","minimum":1,"default":1,"description":"Quantity used together with itemId shorthand"},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["itemId"],"properties":{"itemId":{"type":"string"},"quantity":{"type":"integer","minimum":1,"default":1}}}}},"oneOf":[{"required":["nickname","items"]},{"required":["address","items"]},{"required":["nickname","itemId"]},{"required":["address","itemId"]}]},"example":{"nickname":"PlayerOne","items":[{"itemId":"a-units-pack:1","quantity":1}]}}}},"responses":{"200":{"description":"Payment settled and delivery completed or already recorded","headers":{"PAYMENT-RESPONSE":{"description":"Canonical encoded MPP payment response header for the settled payment.","schema":{"type":"string"}},"X-PAYMENT-RESPONSE":{"description":"Compatibility alias for PAYMENT-RESPONSE.","schema":{"type":"string"}},"Payment-Receipt":{"description":"Convenience alias for the settled payment reference.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"mpp","purchaseId":"purchase-1","paymentReference":"tempo-ref-1","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"pathUSD","network":"tempo:42431","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"delivered","deliveryAttempts":1,"delivery":{"success":true,"retryable":false,"response":{"ok":true},"error":null},"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/mpp/purchases/tempo-ref-1","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"mpp","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"202":{"description":"Payment settled, delivery pending or retryable","headers":{"PAYMENT-RESPONSE":{"description":"Canonical encoded MPP payment response header for the settled payment.","schema":{"type":"string"}},"X-PAYMENT-RESPONSE":{"description":"Compatibility alias for PAYMENT-RESPONSE.","schema":{"type":"string"}},"Payment-Receipt":{"description":"Convenience alias for the settled payment reference.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"mpp","purchaseId":"purchase-1","paymentReference":"tempo-ref-1","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"pathUSD","network":"tempo:42431","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"pending","deliveryAttempts":0,"delivery":null,"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/mpp/purchases/tempo-ref-1","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"mpp","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"400":{"description":"Invalid request"},"402":{"description":"Tempo payment challenge. Retry the same JSON body with Authorization: Payment after settlement.","content":{"application/json":{"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","checkoutType":"shop","discountBps":1000,"discountPercent":"10","hasDiscount":true,"catalogFetchedAt":null,"catalogRevision":null,"protocol":"mpp","error":"payment_required","recipient":{"nickname":"PlayerOne","address":null},"items":[{"itemId":"a-units-pack:1","quantity":1,"totalPriceUsd":"0.09","totalPriceAtomic":"90000","offer":{"id":"a-units-pack:1","title":"200 A-UNITS"}}],"totalQuantity":1,"totalPriceUsd":"0.09","mpp":{"version":"1.0","method":"tempo/charge","params":{"realm":"mpp.clashofcoins.app","method":"tempo/charge","currency":"0x20c0000000000000000000000000000000000000","amount":"0.09","decimals":"6","recipient":"0x97b7f63Cb9f40a147775aa425589a334F7091E37","network":"tempo:42431","memo":"0x62635f6a6e7a30737a387a000000000000000000000000000000000000000000","description":"Purchase 200 A-UNITS for PlayerOne"}},"userMessage":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?","presentation":{"kind":"payment_required","flow":"shop","protocol":"mpp","title":"Payment required","subtitle":"200 A-UNITS for player PlayerOne","message":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?","bullets":["Amount: $0.09 USDC","Recipient: player PlayerOne","Protocol: mpp"],"nextAction":"confirm_payment","suggestedPrompt":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?"},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"nickname":{"type":"string","description":"Clash of Coins player nickname that should receive delivery"},"address":{"type":"string","description":"Optional EVM address used to resolve and verify the recipient"},"itemId":{"type":"string","description":"Single-item shorthand for buying one catalog item"},"quantity":{"type":"integer","minimum":1,"default":1,"description":"Quantity used together with itemId shorthand"},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["itemId","quantity"],"properties":{"itemId":{"type":"string"},"quantity":{"type":"integer","minimum":1,"default":1}}}}},"oneOf":[{"required":["nickname","items"]},{"required":["address","items"]},{"required":["nickname","itemId"]},{"required":["address","itemId"]}]},"example":{"nickname":"PlayerOne","items":[{"itemId":"a-units-pack:1","quantity":1}]}}}},"agentIntegration":{"recommendedSdk":"mppx","npmInstall":"npm install mppx","canonicalUsage":"import { Mppx, tempo } from 'mppx/client';\nimport { privateKeyToAccount } from 'viem/accounts';\n\nMppx.create({\n  methods: [tempo({ account: privateKeyToAccount(process.env.PRIVATE_KEY) })],\n});\n\nawait fetch(url, {\n  method: 'POST',\n  headers: { 'Content-Type': 'application/json' },\n  body: JSON.stringify(body),\n});","retryRule":"Settle the Tempo transfer first, then retry the exact same JSON request with Authorization: Payment.","manualImplementation":{"warning":"Manual MPP credential building is error-prone. Prefer the mppx SDK.","authHeader":"Authorization: Payment <base64-encoded JSON credential>","payloadLocation":"credential.payload","payloadFormat":{"type":"hash","hash":"<tx-hash-after-onchain-transfer>","network":"tempo:42431"}},"commonMistakes":["Using payment.transactionHash instead of credential.payload.hash","Missing credential.payload.type=\"hash\"","Retrying with a different JSON body than the unpaid challenge request","Sending the credential before the Tempo transfer exists onchain"]}}}}}},"x-payment-info":{"protocols":[{"mpp":{"method":"tempo/charge","intent":"purchase","currency":"0x20c0000000000000000000000000000000000000","network":"tempo:42431"}}],"price":{"mode":"dynamic","currency":"USD","min":"0.090000","max":"31.500000"},"intent":"charge","method":"tempo","amount":"31.500000","currency":"pathUSD","authHeader":"Authorization: Payment","retryBodyMode":"reuse_original_json","quoteOptional":true,"quotePurpose":"Use quote as a preflight to validate recipient, cart contents, discount, and exact payable amount before buy.","network":"tempo:42431","asset":"0x20c0000000000000000000000000000000000000","payTo":"0x97b7f63Cb9f40a147775aa425589a334F7091E37","purchaseStatusEndpointTemplate":"/shop/mpp/purchases/{paymentReference}","recommendedClient":"mppx","rateLimits":{"unpaidPurchaseAttemptsPerIpPerMinute":30,"paidRetriesPerPaymentPerMinute":10}},"x-codeSamples":[{"lang":"JavaScript","label":"Canonical MPP client","source":"import { Mppx, tempo } from 'mppx/client';\nimport { privateKeyToAccount } from 'viem/accounts';\n\nMppx.create({\n  methods: [tempo({ account: privateKeyToAccount(process.env.PRIVATE_KEY) })],\n});\n\nconst response = await fetch('https://mpp.clashofcoins.app/shop/mpp/buy', {\n  method: 'POST',\n  headers: { 'content-type': 'application/json' },\n  body: JSON.stringify({\n  \"nickname\": \"PlayerOne\",\n  \"items\": [\n    {\n      \"itemId\": \"a-units-pack:1\",\n      \"quantity\": 1\n    }\n  ]\n}),\n});\n\nconst result = await response.json();\nconsole.log(result);"}]},"get":{"summary":"Probe the Tempo MPP checkout endpoint","responses":{"402":{"description":"Tempo payment challenge. Retry the same JSON body with Authorization: Payment after settlement.","content":{"application/json":{"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","checkoutType":"shop","discountBps":1000,"discountPercent":"10","hasDiscount":true,"catalogFetchedAt":null,"catalogRevision":null,"protocol":"mpp","error":"payment_required","recipient":{"nickname":"PlayerOne","address":null},"items":[{"itemId":"a-units-pack:1","quantity":1,"totalPriceUsd":"0.09","totalPriceAtomic":"90000","offer":{"id":"a-units-pack:1","title":"200 A-UNITS"}}],"totalQuantity":1,"totalPriceUsd":"0.09","mpp":{"version":"1.0","method":"tempo/charge","params":{"realm":"mpp.clashofcoins.app","method":"tempo/charge","currency":"0x20c0000000000000000000000000000000000000","amount":"0.09","decimals":"6","recipient":"0x97b7f63Cb9f40a147775aa425589a334F7091E37","network":"tempo:42431","memo":"0x62635f6a6e7a30737a387a000000000000000000000000000000000000000000","description":"Purchase 200 A-UNITS for PlayerOne"}},"userMessage":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?","presentation":{"kind":"payment_required","flow":"shop","protocol":"mpp","title":"Payment required","subtitle":"200 A-UNITS for player PlayerOne","message":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?","bullets":["Amount: $0.09 USDC","Recipient: player PlayerOne","Protocol: mpp"],"nextAction":"confirm_payment","suggestedPrompt":"To complete this purchase of 200 A-UNITS, I need $0.09 USDC. Confirm to proceed?"},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"nickname":{"type":"string","description":"Clash of Coins player nickname that should receive delivery"},"address":{"type":"string","description":"Optional EVM address used to resolve and verify the recipient"},"itemId":{"type":"string","description":"Single-item shorthand for buying one catalog item"},"quantity":{"type":"integer","minimum":1,"default":1,"description":"Quantity used together with itemId shorthand"},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["itemId","quantity"],"properties":{"itemId":{"type":"string"},"quantity":{"type":"integer","minimum":1,"default":1}}}}},"oneOf":[{"required":["nickname","items"]},{"required":["address","items"]},{"required":["nickname","itemId"]},{"required":["address","itemId"]}]},"example":{"nickname":"PlayerOne","items":[{"itemId":"a-units-pack:1","quantity":1}]}}}},"agentIntegration":{"recommendedSdk":"mppx","npmInstall":"npm install mppx","canonicalUsage":"import { Mppx, tempo } from 'mppx/client';\nimport { privateKeyToAccount } from 'viem/accounts';\n\nMppx.create({\n  methods: [tempo({ account: privateKeyToAccount(process.env.PRIVATE_KEY) })],\n});\n\nawait fetch(url, {\n  method: 'POST',\n  headers: { 'Content-Type': 'application/json' },\n  body: JSON.stringify(body),\n});","retryRule":"Settle the Tempo transfer first, then retry the exact same JSON request with Authorization: Payment.","manualImplementation":{"warning":"Manual MPP credential building is error-prone. Prefer the mppx SDK.","authHeader":"Authorization: Payment <base64-encoded JSON credential>","payloadLocation":"credential.payload","payloadFormat":{"type":"hash","hash":"<tx-hash-after-onchain-transfer>","network":"tempo:42431"}},"commonMistakes":["Using payment.transactionHash instead of credential.payload.hash","Missing credential.payload.type=\"hash\"","Retrying with a different JSON body than the unpaid challenge request","Sending the credential before the Tempo transfer exists onchain"]}}}}}}}},"/purchase-status/{purchaseId}":{"get":{"summary":"Get purchase status by purchase id","parameters":[{"name":"purchaseId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Purchase status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"x402","purchaseId":"purchase-1","paymentReference":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"USDC","network":"eip155:84532","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"delivered","deliveryAttempts":1,"delivery":{"success":true,"retryable":false,"response":{"ok":true},"error":null},"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/x402/purchases/0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"x402","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"202":{"description":"Purchase still pending","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"x402","purchaseId":"purchase-1","paymentReference":"0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"USDC","network":"eip155:84532","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"pending","deliveryAttempts":0,"delivery":null,"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/x402/purchases/0xaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"x402","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"404":{"description":"Purchase not found"}}}},"/payments/history":{"get":{"summary":"List recent purchases (requires secret header)","parameters":[{"name":"X-HISTORY-SECRET","in":"header","required":true,"schema":{"type":"string"},"description":"Shared secret for history access"},{"name":"limit","in":"query","schema":{"type":"integer","default":50}}],"responses":{"200":{"description":"Purchase history list"},"401":{"description":"Unauthorized — missing or invalid secret header"}}}},"/shop/mpp/purchases/{paymentReference}":{"get":{"summary":"Get Tempo MPP purchase status by payment reference","parameters":[{"name":"paymentReference","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"200":{"description":"Purchase status","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"mpp","purchaseId":"purchase-1","paymentReference":"tempo-ref-1","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"pathUSD","network":"tempo:42431","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"delivered","deliveryAttempts":1,"delivery":{"success":true,"retryable":false,"response":{"ok":true},"error":null},"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/mpp/purchases/tempo-ref-1","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"mpp","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"202":{"description":"Purchase still pending","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopPurchaseStatusResponse"},"example":{"catalogTitle":"Clash of Coins Game Shop","catalogLocale":"en","catalogDescription":"Browse in-game goods for Clash of Coins, pay in USDC via x402 or MPP, and receive backend delivery to a verified player identified by nickname or address.","protocol":"mpp","purchaseId":"purchase-1","paymentReference":"tempo-ref-1","recipient":{"nickname":"PlayerOne","address":null},"payer":"0x1111111111111111111111111111111111111111","items":[{"itemId":"a-units-pack:1","itemTitle":"200 A-UNITS","quantity":1,"baseUnitPriceUsd":"0.09","unitPriceUsd":"0.09","discountBps":0,"discountPercent":"0","hasDiscount":false,"baseAmountUsd":"0.09","amountUsd":"0.09"}],"totalQuantity":1,"baseAmountUsd":"0.09","discountBps":0,"discountAmountUsd":"0","amountUsd":"0.09","currency":"pathUSD","network":"tempo:42431","catalogRevision":"catalog-revision-1","offerSnapshot":[],"paymentStatus":"settled","deliveryStatus":"pending","deliveryAttempts":0,"delivery":null,"createdAt":"2026-04-06T12:00:00.000Z","updatedAt":"2026-04-06T12:00:05.000Z","statusEndpoint":"/shop/mpp/purchases/tempo-ref-1","userConfirmation":"Purchased 1x 200 A-UNITS for player PlayerOne.","presentation":{"kind":"success","flow":"shop","protocol":"mpp","nextAction":"inform_user"},"genericStatusEndpoint":"/shop/purchase-status/purchase-1"}}}},"404":{"description":"Purchase not found"}}}}},"components":{"securitySchemes":{"mppAuthorization":{"type":"apiKey","in":"header","name":"Authorization","description":"MPP payment credential header using the Payment auth scheme"}},"schemas":{"X402Resource":{"type":"object","required":["url","mimeType"],"properties":{"url":{"type":"string"},"description":{"type":"string"},"mimeType":{"type":"string"}}},"X402AcceptedRequirement":{"type":"object","required":["scheme","network","asset","amount","payTo"],"properties":{"scheme":{"type":"string"},"network":{"type":"string"},"asset":{"type":"string"},"amount":{"type":"string"},"payTo":{"type":"string"},"extra":{"type":"object","additionalProperties":true}}},"X402PaymentAuthorization":{"type":"object","required":["from","to","value","validAfter","validBefore","nonce"],"properties":{"from":{"type":"string"},"to":{"type":"string"},"value":{"type":"string"},"validAfter":{"type":"string"},"validBefore":{"type":"string"},"nonce":{"type":"string"}}},"X402PaymentPayload":{"type":"object","required":["authorization","signature"],"properties":{"authorization":{"$ref":"#/components/schemas/X402PaymentAuthorization"},"signature":{"type":"string"}}},"X402PaymentSignatureDecoded":{"type":"object","required":["x402Version","resource","accepted","payload"],"properties":{"x402Version":{"type":"integer","example":2},"resource":{"$ref":"#/components/schemas/X402Resource"},"accepted":{"$ref":"#/components/schemas/X402AcceptedRequirement"},"payload":{"$ref":"#/components/schemas/X402PaymentPayload"}}},"ShopX402PaymentRequiredResponse":{"type":"object","required":["protocol","error","items","totalQuantity","totalPriceUsd","totalPriceAtomic","paymentRetry"],"properties":{"catalogTitle":{"type":"string"},"catalogLocale":{"type":"string"},"catalogDescription":{"type":"string"},"protocol":{"type":"string"},"error":{"type":"string"},"recipient":{"type":"object","properties":{"nickname":{"type":["string","null"]},"address":{"type":["string","null"]}}},"items":{"type":"array","items":{"type":"object","properties":{"itemId":{"type":"string"},"quantity":{"type":"integer"},"totalPriceUsd":{"type":"string"},"totalPriceAtomic":{"type":"string"},"offer":{"type":"object","additionalProperties":true}}}},"totalQuantity":{"type":"integer"},"totalPriceUsd":{"type":"string"},"totalPriceAtomic":{"type":"string"},"paymentFieldHints":{"type":"object","additionalProperties":true},"userMessage":{"type":"string"},"presentation":{"type":"object","additionalProperties":true},"paymentRetry":{"type":"object","additionalProperties":true}}},"ShopX402SettlementErrorResponse":{"type":"object","required":["error","reason","message","required","requiredAmountType","asset","paymentRecipient","chainInfoEndpoint","purchaseId","paymentSettled","paymentRetry"],"properties":{"error":{"type":"string"},"reason":{"type":"string"},"message":{"type":"string"},"required":{"type":"string"},"requiredAmountType":{"type":"string"},"totalPriceUsd":{"type":"string"},"asset":{"type":"string"},"available":{"type":"string"},"paymentRecipient":{"type":"string"},"chainInfoEndpoint":{"type":"string"},"statusEndpoint":{"type":["string","null"]},"statusByWalletItemEndpoint":{"type":"string"},"paymentReference":{"type":["string","null"]},"settlementTxHash":{"type":["string","null"]},"payer":{"type":["string","null"]},"purchaseId":{"type":["string","null"]},"paymentSettled":{"type":"boolean"},"hint":{"type":"string"},"paymentRetry":{"type":"object","additionalProperties":true}}},"ShopPurchaseStatusResponse":{"type":"object","required":["protocol","purchaseId","paymentReference","recipient","items","totalQuantity","amountUsd","currency","network","paymentStatus","deliveryStatus","statusEndpoint","genericStatusEndpoint"],"properties":{"catalogTitle":{"type":"string"},"catalogLocale":{"type":"string"},"catalogDescription":{"type":"string"},"protocol":{"type":"string"},"purchaseId":{"type":"string"},"paymentReference":{"type":"string"},"recipient":{"type":"object","properties":{"nickname":{"type":["string","null"]},"address":{"type":["string","null"]}}},"payer":{"type":["string","null"]},"items":{"type":"array","items":{"type":"object","properties":{"itemId":{"type":"string"},"itemTitle":{"type":"string"},"quantity":{"type":"integer"},"baseUnitPriceUsd":{"type":"string"},"unitPriceUsd":{"type":"string"},"discountBps":{"type":"integer"},"discountPercent":{"type":"string"},"hasDiscount":{"type":"boolean"},"baseAmountUsd":{"type":"string"},"amountUsd":{"type":"string"}}}},"totalQuantity":{"type":"integer"},"baseAmountUsd":{"type":"string"},"discountBps":{"type":"integer"},"discountAmountUsd":{"type":"string"},"amountUsd":{"type":"string"},"currency":{"type":"string"},"network":{"type":"string"},"catalogRevision":{"type":["string","null"]},"offerSnapshot":{"type":"array","items":{"type":"object","additionalProperties":true}},"paymentStatus":{"type":"string"},"deliveryStatus":{"type":"string"},"deliveryAttempts":{"type":"integer"},"delivery":{"type":["object","null"],"additionalProperties":true},"createdAt":{"type":"string"},"updatedAt":{"type":"string"},"statusEndpoint":{"type":"string"},"userConfirmation":{"type":"string"},"presentation":{"type":"object","additionalProperties":true},"genericStatusEndpoint":{"type":"string"}}},"ShopX402StatusByWalletItem":{"type":"object","required":["paid","purchaseId","txHash","paymentReference","itemId","wallet"],"properties":{"paid":{"type":"boolean"},"purchaseId":{"type":["string","null"]},"txHash":{"type":["string","null"]},"paymentReference":{"type":["string","null"]},"paymentStatus":{"type":"string"},"deliveryStatus":{"type":"string"},"statusEndpoint":{"type":"string"},"genericStatusEndpoint":{"type":"string"},"itemId":{"type":"string"},"wallet":{"type":"string"}}},"ShopX402ChainInfo":{"type":"object","required":["chainId","networkId","usdcAddress","paymentRecipient"],"properties":{"chainId":{"type":["integer","null"]},"networkId":{"type":"string"},"usdcAddress":{"type":"string"},"paymentRecipient":{"type":"string"},"facilitator":{"type":["string","null"]},"transferMethod":{"type":["string","null"]},"eip712Domain":{"type":["object","null"],"additionalProperties":true},"domainSeparator":{"type":["string","null"]}}},"ShopX402HealthResponse":{"type":"object","required":["protocol","x402Version","supportedSchemes","networkId","usdcAddress","paymentRecipient"],"properties":{"protocol":{"type":"string"},"x402Version":{"type":"integer"},"supportedSchemes":{"type":"array","items":{"type":"string"}},"chainId":{"type":["integer","null"]},"networkId":{"type":"string"},"usdcAddress":{"type":"string"},"paymentRecipient":{"type":"string"},"facilitator":{"type":["string","null"]},"transferMethod":{"type":["string","null"]},"eip712Domain":{"type":["object","null"],"additionalProperties":true},"domainSeparator":{"type":["string","null"]},"gasSponsorshipExtensions":{"type":"array","items":{"type":"string"}},"endpoints":{"type":"object","additionalProperties":true},"headers":{"type":"object","additionalProperties":true},"rateLimits":{"type":"object","additionalProperties":true}}}},"examples":{"SampleItem":{"value":{"itemId":"a-units-pack:1","quantity":1,"nickname":"PlayerOne"}}}},"x-bazaar":{"version":1,"integration":"minimal","notes":"Bazaar-compatible discovery metadata. Use /shop/openapi.json as protocol-aware payable discovery, then submit the matching canonical buy route.","name":"Clash of Coins","description":"Agentic checkout for Clash of Coins","category":"Gaming","tags":["Gaming"],"icon":"https://mpp.clashofcoins.app/favicon.png","logoUrl":"https://mpp.clashofcoins.app/favicon.png","service":{"name":"Clash of Coins","description":"Agentic checkout for Clash of Coins","category":"Gaming","tags":["Gaming"],"icon":"https://mpp.clashofcoins.app/favicon.png","logoUrl":"https://mpp.clashofcoins.app/favicon.png","addresses":{"treasury":"0x97b7f63cb9f40a147775aa425589a334f7091e37"}},"addresses":{"treasury":"0x97b7f63cb9f40a147775aa425589a334f7091e37"},"discovery":{"openapi":"/shop/openapi.json","openapiFull":"/shop/openapi.full.json","openapiMode":"payable","x402":null,"mpp":"/shop/.well-known/mpp","agent":"/shop/.well-known/agent.json","skill":"/shop/skill.md"},"purchase":{"mpp":{"method":"POST","path":"/shop/mpp/buy","retryHeader":"Authorization: Payment"}}},"x-x402-shop":{"serviceName":"Clash of Coins","serviceDescription":"Agentic checkout for Clash of Coins","checkoutType":"shop","canonicalX402Endpoint":null,"discovery":{"root":"/shop","openapi":"/shop/openapi.json","openapiFull":"/shop/openapi.full.json","x402":null,"mpp":"/shop/.well-known/mpp","xmtp":null,"llms":"/shop/llms.txt","agent":"/shop/.well-known/agent.json","agents":"/shop/.well-known/agents.json","skill":"/shop/skill.md"},"x402":null,"xmtp":null,"mpp":{"buy":"/shop/mpp/buy","quote":"/shop/mpp/quote","purchaseStatus":"/shop/mpp/purchases/{paymentReference}","genericStatus":"/shop/purchase-status/{purchaseId}","openapi":"/shop/mpp/openapi.json","inputSchema":{"type":"object","properties":{"nickname":{"type":"string","description":"Clash of Coins player nickname that should receive delivery"},"address":{"type":"string","description":"Optional EVM address used to resolve and verify the recipient"},"itemId":{"type":"string","description":"Single-item shorthand for buying one catalog item"},"quantity":{"type":"integer","minimum":1,"default":1,"description":"Quantity used together with itemId shorthand"},"items":{"type":"array","minItems":1,"items":{"type":"object","required":["itemId"],"properties":{"itemId":{"type":"string"},"quantity":{"type":"integer","minimum":1,"default":1}}}}},"oneOf":[{"required":["nickname","items"]},{"required":["address","items"]},{"required":["nickname","itemId"]},{"required":["address","itemId"]}]},"inputExample":{"nickname":"PlayerOne","items":[{"itemId":"a-units-pack:1","quantity":1}]}},"activeItems":[{"id":"a-units-pack:1","title":"200 A-UNITS","description":"Includes 200 hard-currency-resource (+100 bonus).","priceUsd":"0.09"},{"id":"a-units-pack:2","title":"1100 A-UNITS","description":"Includes 1100 hard-currency-resource (+100 bonus).","priceUsd":"0.45"},{"id":"a-units-pack:3","title":"2400 A-UNITS","description":"Includes 2400 hard-currency-resource (+400 bonus).","priceUsd":"0.9"},{"id":"a-units-pack:4","title":"6000 A-UNITS","description":"Includes 6000 hard-currency-resource (+1000 bonus).","priceUsd":"18"},{"id":"a-units-pack:5","title":"11000 A-UNITS","description":"Includes 11000 hard-currency-resource (+2000 bonus).","priceUsd":"31.5"},{"id":"keys:10","title":"10 keys","description":"Includes 10 keys.","priceUsd":"4.5"},{"id":"keys:5","title":"5 keys","description":"Includes 5 keys.","priceUsd":"2.25"},{"id":"keys:50","title":"50 keys","description":"Includes 50 keys.","priceUsd":"18"},{"id":"agent:a-units-pack-1","title":"agent:a-units-pack-1","description":"Includes 10 hard-currency-resource.","priceUsd":"0.09"}]}}