{"openapi":"3.1.0","info":{"title":"ProductClank x402 API","version":"1.0.0","description":"Keyless, pay-per-call growth-marketing services for AI agents, paid in USDC on Base via the x402 protocol — growth hacking, social amplification, community activation, UGC/creator marketing, and product distribution. Boost a social post with real human engagement, launch a community content campaign, or get a product featured on the ProductClank directory — no API key or account required. New here? Test the boost flow for $2 with the boost-trial endpoint before paying $20.\n\nVersioning: every response carries `API-Version: 1`; a request may send the same header to pin the major (any other value is refused with 400 `unsupported_api_version`, never silently served). Breaking changes ship only as a new major — `API-Version: 2` at new `/api/x402/v2/*` paths. Additive changes (new endpoints, optional fields, new response fields) ship within a major — ignore unknown fields. A deprecated operation is marked `deprecated: true` here and its responses carry `Deprecation` (RFC 9745), `Sunset` (RFC 8594) and `Link: <…>; rel=\"deprecation\"` at least 90 days before it stops working. Policy: https://www.productclank.com/developers#versioning\n\nRate limits: 300 requests per 60s per bearer credential, 60 per 60s per IP for unauthenticated calls. Every response carries `RateLimit-Policy` and `RateLimit` (IETF draft-ietf-httpapi-ratelimit-headers) plus `RateLimit-Limit` / `RateLimit-Remaining` / `RateLimit-Reset`; a 429 adds `Retry-After` (seconds). Throttle on `RateLimit-Remaining` instead of waiting for a 429.","x-guidance":"All paid endpoints are POST with a JSON body and settle only on success — a failed call never costs anything. First time? Use POST /api/x402/boost-trial ($2) to test the boost flow end-to-end: same machinery, one real community reply on your post. Use POST /api/x402/boost ($20) to get real human replies/likes/reposts on any social post (send post_url). Use POST /api/x402/content-campaign ($50) to have real creators produce original content about a product (requires a ProductClank product_id — create one free at https://www.productclank.com, or via the $19 product-listing endpoint). Use POST /api/x402/product-listing ($19) to feature a product on the productclank.com/products directory (send just the product url). If you paid but lost the response, recover it free via GET /api/x402/purchases?nonce=….","x-api-lifecycle":{"current_version":"1","versioning":"header","version_header":"API-Version","breaking_changes":"Only in a new major version (API-Version: 2, served at new /api/x402/v2/* paths). The previous major keeps working until its Sunset date.","additive_changes":"New endpoints, optional request fields and response fields can ship within a major at any time; clients must ignore unknown fields.","deprecation_signals":["Deprecation response header (RFC 9745)","Sunset response header (RFC 8594)","Link response header with rel=\"deprecation\"","deprecated: true on the operation in this document"],"minimum_notice_days":90,"policy_url":"https://www.productclank.com/developers#versioning"},"contact":{"email":"contact@productclank.com"}},"servers":[{"url":"https://www.productclank.com"}],"tags":[{"name":"growth","description":"Growth marketing and growth hacking services: social amplification, community activation, engagement campaigns"},{"name":"marketing","description":"Marketing services for products and brands: social engagement, UGC content, creator marketing, brand awareness"},{"name":"community","description":"Community-powered services — real humans from ProductClank's creator community deliver the outcomes"},{"name":"social-amplification","description":"Amplify social posts with authentic replies, likes, and reposts on X/Twitter, LinkedIn, Instagram, TikTok, Reddit, Farcaster, YouTube"}],"paths":{"/api/x402/boost":{"post":{"operationId":"boost","summary":"ProductClank Post Boost","description":"Boost any social post with real human engagement from ProductClank's creator community — social amplification for growth hacking, launches, and brand awareness. $20 per boost: 10 authentic AI-drafted replies posted by real community members (or 30 likes / 10 reposts). Works on X/Twitter, LinkedIn, Instagram, TikTok, Reddit, Farcaster, YouTube. Send the post URL; get a campaign id + public tracking URL. Engagement lands within 24-48h. Test it first for $2: /api/x402/boost-trial.","tags":["social","marketing","engagement","growth","growth-hacking","community","social-amplification","community-activation","brand-awareness","promotion"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"20.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"post_url":{"type":"string","description":"URL of the social post to boost — X/Twitter, LinkedIn, Instagram, TikTok, Reddit, Farcaster, or YouTube"},"action_type":{"type":"string","enum":["replies","likes","repost","quote","bookmarks"],"description":"Engagement type: 'replies' = 10 authentic AI-drafted replies posted by real community members (default), 'likes' = 30 likes, 'bookmarks' = 10 bookmarks (X only, screenshot-proved), 'repost' = 10 reposts, 'quote' = 10 AI-drafted quote posts (a repost WITH the member's own text, landing in their followers' feeds — X only). Some platforms only support replies."},"reply_guidelines":{"type":"string","description":"Optional tone/content guidance for the generated replies"},"post_text":{"type":"string","description":"Optional — the post's text. Skips server-side fetching; recommended for LinkedIn and Instagram posts"},"post_author":{"type":"string","description":"Optional — the post author's username (used with post_text)"}},"required":["post_url"]},"example":{"post_url":"https://x.com/productclank/status/1234567890123456789","action_type":"replies","reply_guidelines":"Supportive, curious replies that highlight the product's AI features"}}}},"responses":{"200":{"description":"Success — the paid operation completed and was settled","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"campaign":{"type":"object","properties":{"id":{"type":"string"},"campaign_number":{"type":"string"},"platform":{"type":"string"},"action_type":{"type":"string"},"url":{"type":"string"}}},"items_generated":{"type":"integer"},"payment":{"type":"object","properties":{"settled":{"type":"boolean"},"transaction":{"type":"string"},"network":{"type":"string"},"amount_usd":{"type":"integer"}}}}},"example":{"success":true,"campaign":{"id":"0b0e8f7a-0000-0000-0000-000000000000","campaign_number":"CP-042","platform":"twitter","action_type":"replies","url":"https://www.productclank.com/communiply/boost/0b0e8f7a-0000-0000-0000-000000000000"},"items_generated":10,"payment":{"settled":true,"transaction":"0xabc123…","network":"eip155:8453","amount_usd":20}}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"400":{"description":"Validation error — the payment is NOT settled; retry with a valid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"402":{"description":"Payment Required — x402 v2 challenge","headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"429":{"description":"Too many requests (`rate_limited`) — retry after `Retry-After` seconds; nothing is charged","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"},"Retry-After":{"$ref":"#/components/headers/Retry-After"}}},"500":{"description":"Server error — the payment is NOT settled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}}},"parameters":[{"$ref":"#/components/parameters/ApiVersion"}]}},"/api/x402/boost-trial":{"post":{"operationId":"boostTrial","summary":"ProductClank Post Boost — $2 Trial","description":"Try ProductClank's social amplification for $2 before committing to a full boost — the cheapest way to test community-driven growth marketing. Runs the exact same flow as the $20 boost, scaled to a single reply: 1 authentic AI-drafted reply posted on your post by a real community member. Works on X/Twitter, LinkedIn, Instagram, TikTok, Reddit, Farcaster, YouTube. Send the post URL; get back a campaign id and a public tracking URL. Ready for the full 10 replies? Use /api/x402/boost.","tags":["social","marketing","engagement","growth","growth-hacking","community","social-amplification","community-activation","trial","test"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"2.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"post_url":{"type":"string","description":"URL of the social post to boost — X/Twitter, LinkedIn, Instagram, TikTok, Reddit, Farcaster, or YouTube"},"reply_guidelines":{"type":"string","description":"Optional tone/content guidance for the generated reply"},"post_text":{"type":"string","description":"Optional — the post's text. Skips server-side fetching; recommended for LinkedIn and Instagram posts"},"post_author":{"type":"string","description":"Optional — the post author's username (used with post_text)"}},"required":["post_url"]},"example":{"post_url":"https://x.com/productclank/status/1234567890123456789","reply_guidelines":"Supportive, curious replies that highlight the product's AI features"}}}},"responses":{"200":{"description":"Success — the paid operation completed and was settled","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"campaign":{"type":"object","properties":{"id":{"type":"string"},"campaign_number":{"type":"string"},"platform":{"type":"string"},"action_type":{"type":"string"},"url":{"type":"string"}}},"items_generated":{"type":"integer"},"payment":{"type":"object","properties":{"settled":{"type":"boolean"},"transaction":{"type":"string"},"network":{"type":"string"},"amount_usd":{"type":"integer"}}}}},"example":{"success":true,"campaign":{"id":"0b0e8f7a-0000-0000-0000-000000000000","campaign_number":"CP-042","platform":"twitter","action_type":"replies","url":"https://www.productclank.com/communiply/boost/0b0e8f7a-0000-0000-0000-000000000000"},"items_generated":1,"payment":{"settled":true,"transaction":"0xabc123…","network":"eip155:8453","amount_usd":2}}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"400":{"description":"Validation error — the payment is NOT settled; retry with a valid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"402":{"description":"Payment Required — x402 v2 challenge","headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"429":{"description":"Too many requests (`rate_limited`) — retry after `Retry-After` seconds; nothing is charged","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"},"Retry-After":{"$ref":"#/components/headers/Retry-After"}}},"500":{"description":"Server error — the payment is NOT settled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}}},"parameters":[{"$ref":"#/components/parameters/ApiVersion"}]}},"/api/x402/content-campaign":{"post":{"operationId":"contentCampaign","summary":"ProductClank Content Campaign","description":"Launch a community content campaign for your product on ProductClank — UGC and creator marketing for growth hacking and brand awareness. $50 per launch: real creators produce and post original content (threads, posts, videos) about your product, and you track submissions on a public campaign page. Requires a ProductClank product id — create one free at www.productclank.com. Send the product id plus a campaign message; the brief is AI-composed and auto-activates within minutes.","tags":["content","marketing","ugc","community","growth","growth-hacking","creator-marketing","influencer-marketing","community-activation","brand-awareness","content-marketing"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"50.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"product_id":{"type":"string","description":"ProductClank product id the campaign is for. Create or find your product at https://www.productclank.com"},"campaign_message":{"type":"string","description":"The core brief: what the community's content should communicate about the product"},"campaign_goals":{"type":"array","items":{"type":"string"},"description":"Optional campaign goals, e.g. awareness, signups, launches"},"target_audience":{"type":"string","description":"Optional description of the audience the content should reach"},"preferred_platform":{"type":"string","description":"Optional preferred platform for the content (e.g. twitter, youtube)"},"additional_guidelines":{"type":"string","description":"Optional extra content guidelines for creators"}},"required":["product_id","campaign_message"]},"example":{"product_id":"0f1e2d3c-0000-0000-0000-000000000000","campaign_message":"We just shipped AI-powered analytics — get creators to show how they use it in real workflows","campaign_goals":["awareness","signups"],"target_audience":"Indie hackers and data-curious founders"}}}},"responses":{"200":{"description":"Success — the paid operation completed and was settled","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"campaign":{"type":"object","properties":{"id":{"type":"string"},"campaign_number":{"type":"string"},"title":{"type":"string"},"campaign_type":{"type":"string"},"status":{"type":"string"},"public_url":{"type":"string"}}},"payment":{"type":"object","properties":{"settled":{"type":"boolean"},"transaction":{"type":"string"},"network":{"type":"string"},"amount_usd":{"type":"integer"}}}}},"example":{"success":true,"campaign":{"id":"7a1b2c3d-0000-0000-0000-000000000000","campaign_number":"GB-017","title":"Show your AI analytics workflow","campaign_type":"take_action","status":"processing","public_url":"https://www.productclank.com/communiply/content/7a1b2c3d-0000-0000-0000-000000000000"},"payment":{"settled":true,"transaction":"0xabc123…","network":"eip155:8453","amount_usd":50}}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"400":{"description":"Validation error — the payment is NOT settled; retry with a valid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"402":{"description":"Payment Required — x402 v2 challenge","headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"429":{"description":"Too many requests (`rate_limited`) — retry after `Retry-After` seconds; nothing is charged","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"},"Retry-After":{"$ref":"#/components/headers/Retry-After"}}},"500":{"description":"Server error — the payment is NOT settled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}}},"parameters":[{"$ref":"#/components/parameters/ApiVersion"}]}},"/api/x402/product-listing":{"post":{"operationId":"productListing","summary":"ProductClank Featured Product Listing","description":"Get a product featured on ProductClank's product directory (productclank.com/products) — a curated list of community-backed products. $19 one-time: send just the product's URL and the listing is auto-filled (name, tagline, description, logo, X handle) and featured on the directory within a minute. Explicit fields override the extracted ones. Idempotent per wallet: re-listing the same product features the existing listing instead of duplicating it.","tags":["directory","listing","marketing","launch","growth","growth-hacking","distribution","promotion","product-launch","visibility"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"19.00"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"url":{"type":"string","description":"Product website URL — the listing is auto-filled from the site. Provide url or name."},"name":{"type":"string","description":"Product name. Optional when url is given; required otherwise."},"tagline":{"type":"string","description":"Optional — one-line value proposition (overrides extracted)"},"description":{"type":"string","description":"Optional — short description (overrides extracted)"},"twitter":{"type":"string","description":"Optional — X/Twitter handle or profile URL"},"logo":{"type":"string","description":"Optional — logo image URL (otherwise auto-resolved)"},"category":{"type":"array","items":{"type":"string"},"description":"Optional — category tags"}},"required":["url"]},"example":{"url":"https://acme.com","tagline":"AI analytics for indie SaaS"}}}},"responses":{"200":{"description":"Success — the paid operation completed and was settled","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"product":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"website":{"type":"string"},"featured":{"type":"boolean"},"url":{"type":"string"},"directory_url":{"type":"string"}}},"already_listed":{"type":"boolean"},"payment":{"type":"object","properties":{"settled":{"type":"boolean"},"transaction":{"type":"string"},"network":{"type":"string"},"amount_usd":{"type":"integer"}}}}},"example":{"success":true,"product":{"id":"0f1e2d3c-0000-0000-0000-000000000000","name":"Acme","website":"https://acme.com","featured":true,"url":"https://www.productclank.com/products/0f1e2d3c-0000-0000-0000-000000000000","directory_url":"https://www.productclank.com/products"},"already_listed":false,"payment":{"settled":true,"transaction":"0xabc123…","network":"eip155:8453","amount_usd":19}}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"400":{"description":"Validation error — the payment is NOT settled; retry with a valid body","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"402":{"description":"Payment Required — x402 v2 challenge","headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"429":{"description":"Too many requests (`rate_limited`) — retry after `Retry-After` seconds; nothing is charged","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"},"Retry-After":{"$ref":"#/components/headers/Retry-After"}}},"500":{"description":"Server error — the payment is NOT settled","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}}},"parameters":[{"$ref":"#/components/parameters/ApiVersion"}]}},"/api/x402/purchases":{"get":{"operationId":"purchasesLookup","summary":"Recover a past x402 purchase","description":"Free, keyless recovery lookup: 'did my payment work, and what did it create?' — for when an agent paid one of the x402 endpoints but never received the HTTP response. Pass the payment authorization nonce (?nonce=0x…) or the settlement transaction hash (?tx=0x…). found:false means the payment was never settled and it is safe to re-pay.","tags":["payments"],"security":[],"parameters":[{"name":"nonce","in":"query","required":false,"schema":{"type":"string"},"description":"The nonce from your signed x402 payment authorization (generated client-side when paying)"},{"name":"tx","in":"query","required":false,"schema":{"type":"string"},"description":"The settlement transaction hash on Base"},{"$ref":"#/components/parameters/ApiVersion"}],"responses":{"200":{"description":"Lookup result — found:true includes what the purchase created (campaign/product id and public URL)","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"found":{"type":"boolean"},"message":{"type":"string"}}}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"400":{"description":"Neither nonce nor tx was provided","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}},"429":{"description":"Too many requests (`rate_limited`) — retry after `Retry-After` seconds; nothing is charged","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"},"Retry-After":{"$ref":"#/components/headers/Retry-After"}}},"500":{"description":"Lookup failed","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"headers":{"RateLimit-Policy":{"$ref":"#/components/headers/RateLimit-Policy"},"RateLimit":{"$ref":"#/components/headers/RateLimit"},"RateLimit-Limit":{"$ref":"#/components/headers/RateLimit-Limit"},"RateLimit-Remaining":{"$ref":"#/components/headers/RateLimit-Remaining"},"RateLimit-Reset":{"$ref":"#/components/headers/RateLimit-Reset"},"API-Version":{"$ref":"#/components/headers/API-Version"}}}}}}},"components":{"schemas":{"ErrorResponse":{"type":"object","required":["success","error","message"],"properties":{"success":{"type":"boolean","const":false},"error":{"type":"string","description":"Machine-readable error code","enum":["validation_error","internal_error","rate_limited","unsupported_api_version"]},"message":{"type":"string","description":"Human-readable explanation, including how to retry"}}}},"parameters":{"ApiVersion":{"name":"API-Version","in":"header","required":false,"description":"Optional. Pin the major version. Only `1` is served; any other value → 400 `unsupported_api_version`.","schema":{"type":"string","enum":["1"]}}},"headers":{"RateLimit-Policy":{"description":"Quota policy, structured field: `\"<name>\";q=<requests>;w=<window seconds>`. per-key = 300/60s per bearer credential; per-ip = 60/60s per IP.","schema":{"type":"string","example":"\"per-key\";q=300;w=60"}},"RateLimit":{"description":"Current window, structured field: `\"<name>\";r=<remaining>;t=<seconds until reset>`.","schema":{"type":"string","example":"\"per-key\";r=299;t=42"}},"RateLimit-Limit":{"description":"Requests allowed in the current window.","schema":{"type":"integer","minimum":0}},"RateLimit-Remaining":{"description":"Requests left in the current window.","schema":{"type":"integer","minimum":0}},"RateLimit-Reset":{"description":"Seconds until the current window resets.","schema":{"type":"integer","minimum":0}},"Retry-After":{"description":"Seconds to wait before retrying (on 429).","schema":{"type":"integer","minimum":0}},"API-Version":{"description":"Major version of the contract that served this response. Always `1` today.","schema":{"type":"string","enum":["1"]}}}}}