{"openapi":"3.0.3","info":{"title":"Port66 Agent API","description":"Machine-payable API for the Port66 luxury marketplace. Paid endpoints require a Valiron trust check before x402 returns an HTTP 402 challenge with exact USDC-on-Base payment requirements.","version":"1.0.0","contact":{"name":"Port66","email":"itsmoizmughal@gmail.com","url":"https://port66.xyz"}},"servers":[{"url":"https://port66.xyz"}],"components":{"securitySchemes":{"valironAgent":{"type":"apiKey","in":"header","name":"x-agent-id","description":"ERC-8004 agent ID evaluated by Valiron. Key-based agents may send x-agent-address instead."},"x402":{"type":"apiKey","in":"header","name":"payment-signature","description":"x402 protocol payment (scheme: exact, network: eip155:8453, USDC). Request without payment to receive the 402 challenge."}}},"paths":{"/api/agent/v1":{"get":{"summary":"Capability manifest (free)","description":"Free machine-readable description of all agent endpoints and pricing.","security":[],"responses":{"200":{"description":"Manifest JSON"}}}},"/api/agent/v1/listings":{"get":{"summary":"Search and browse active marketplace listings","description":"Paid via x402: $0.005 USDC on Base mainnet per request.","security":[{"valironAgent":[],"x402":[]}],"x-payment-info":{"protocol":"x402","scheme":"exact","network":"eip155:8453","asset":"USDC","price":"$0.005"},"parameters":[{"name":"q","in":"query","required":false,"description":"Free-text search","schema":{"type":"string"}},{"name":"brandName","in":"query","required":false,"description":"Filter by brand name","schema":{"type":"string"}},{"name":"categoryName","in":"query","required":false,"description":"Filter by category name","schema":{"type":"string"}},{"name":"condition","in":"query","required":false,"description":"Item condition","schema":{"type":"string","enum":["DEADSTOCK","MINT","EXCELLENT","VERY_GOOD","GOOD","FAIR"]}},{"name":"minPrice","in":"query","required":false,"description":"Minimum price (USD)","schema":{"type":"number"}},{"name":"maxPrice","in":"query","required":false,"description":"Maximum price (USD)","schema":{"type":"number"}},{"name":"sortBy","in":"query","required":false,"description":"Sort field (e.g. price, listedAt)","schema":{"type":"string"}},{"name":"sortOrder","in":"query","required":false,"schema":{"type":"string","enum":["asc","desc"]}},{"name":"page","in":"query","required":false,"description":"Page number (default 1)","schema":{"type":"integer","minimum":1}},{"name":"limit","in":"query","required":false,"description":"Results per page (max 50)","schema":{"type":"integer","minimum":1,"maximum":50}}],"responses":{"200":{"description":"Matching listings with pagination meta","content":{"application/json":{"schema":{"type":"object","properties":{"meta":{"type":"object","properties":{"total":{"type":"integer"},"page":{"type":"integer"},"limit":{"type":"integer"},"totalPages":{"type":"integer"}}},"listings":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"slug":{"type":"string"},"url":{"type":"string"},"price":{"type":"number","nullable":true},"currency":{"type":"string"},"listingType":{"type":"string"},"condition":{"type":"string"},"size":{"type":"string","nullable":true},"brand":{"type":"string","nullable":true},"category":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"seller":{"type":"string","nullable":true},"verificationLevel":{"type":"string"},"anchoredOnBase":{"type":"boolean"},"listedAt":{"type":"string"}}}}}}}}},"402":{"description":"x402 payment required — challenge in the payment-required header"}}}},"/api/agent/v1/listings/{slug}":{"get":{"summary":"Full detail for one listing","description":"Paid via x402: $0.005 USDC on Base mainnet per request. Includes description, images, seller, verification level, and on-chain provenance.","security":[{"valironAgent":[],"x402":[]}],"x-payment-info":{"protocol":"x402","scheme":"exact","network":"eip155:8453","asset":"USDC","price":"$0.005"},"parameters":[{"name":"slug","in":"path","required":true,"description":"Listing slug (from search results)","schema":{"type":"string"}}],"responses":{"200":{"description":"Listing detail","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string"},"title":{"type":"string"},"slug":{"type":"string"},"url":{"type":"string"},"description":{"type":"string"},"price":{"type":"number","nullable":true},"minimumOffer":{"type":"number","nullable":true},"currency":{"type":"string"},"listingType":{"type":"string"},"status":{"type":"string"},"condition":{"type":"string"},"size":{"type":"string","nullable":true},"color":{"type":"string","nullable":true},"material":{"type":"string","nullable":true},"era":{"type":"string","nullable":true},"country":{"type":"string","nullable":true},"brand":{"type":"object","nullable":true,"properties":{"name":{"type":"string"},"slug":{"type":"string"}}},"category":{"type":"object","nullable":true,"properties":{"name":{"type":"string"},"slug":{"type":"string"}}},"images":{"type":"array","items":{"type":"string"}},"seller":{"type":"object","nullable":true,"properties":{"username":{"type":"string"},"verified":{"type":"boolean"}}},"verificationLevel":{"type":"string"},"provenance":{"type":"object","properties":{"anchoredOnBase":{"type":"boolean"},"txHash":{"type":"string","nullable":true},"registryAddress":{"type":"string","nullable":true},"anchoredAt":{"type":"string","nullable":true}}},"stats":{"type":"object","properties":{"views":{"type":"integer"},"saves":{"type":"integer"},"offers":{"type":"integer"}}},"listedAt":{"type":"string"}}}}}},"402":{"description":"x402 payment required"},"404":{"description":"Listing not found"}}}},"/api/agent/v1/market/{slug}":{"get":{"summary":"Market data for a product","description":"Paid via x402: $0.01 USDC on Base mainnet per request. Price history + market statistics.","security":[{"valironAgent":[],"x402":[]}],"x-payment-info":{"protocol":"x402","scheme":"exact","network":"eip155:8453","asset":"USDC","price":"$0.01"},"parameters":[{"name":"slug","in":"path","required":true,"description":"Product slug","schema":{"type":"string"}}],"responses":{"200":{"description":"Market data","content":{"application/json":{"schema":{"type":"object","properties":{"product":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"},"brand":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"slug":{"type":"string"}}}}},"marketData":{"type":"object","nullable":true,"description":"Aggregate market statistics for the product"},"priceHistory":{"type":"array","description":"Historical price points (up to 1 year)","items":{"type":"object","properties":{"date":{"type":"string"},"price":{"type":"number"}}}}}}}}},"402":{"description":"x402 payment required"},"404":{"description":"Product not found"}}}}}}