{"openapi":"3.1.0","info":{"title":"Evidence402","version":"2.1.0","contact":{"url":"https://evidence402.onrender.com/start.html"},"description":"Pay-per-use public page reading, structured extraction, site profiles and scholarly research for AI agents.","x-guidance":"Start with /catalog for enabled tools, prices and JSON examples. Use web-read for public static HTTPS page text, web-extract for published JSON-LD or CSS fields, site-profile for business links, and verify for DOI checks. POST the example JSON with Content-Type: application/json to get an unsigned 402 quote. Pay with x402 v2 exact USDC on the advertised network; pin the receiver and price. Preserve the signed authorization and identical body for retries. No subscriptions or buyer API keys. Public static pages only, robots.txt respected, no login or JavaScript rendering. Integration guide: https://evidence402.onrender.com/start.html"},"servers":[{"url":"https://evidence402.onrender.com"}],"paths":{"/api/v1/search":{"post":{"operationId":"search","summary":"Find and deduplicate scholarly papers from Crossref and Europe PMC. Use for literature discovery with DOI source links.","tags":["research","citations","science"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"description":"Find and deduplicate scholarly papers from Crossref and Europe PMC. Use for literature discovery with DOI source links.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"query":{"type":"string","minLength":3,"maxLength":250,"examples":["semaglutide obesity"]},"limit":{"default":10,"type":"integer","minimum":1,"maximum":20,"examples":[5]},"fromYear":{"type":"integer","minimum":1900,"maximum":2026}},"required":["query"],"additionalProperties":false},"example":{"query":"semaglutide obesity","limit":5}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","properties":{"papers":{"type":"array","items":{"type":"object"}},"query":{"type":"string"}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.01","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/verify":{"post":{"operationId":"verify","summary":"Check up to ten DOI citations against source registries, compare optional titles, and expose publication update signals. Use to detect incorrect references.","tags":["research","citations","science"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.02"},"protocols":[{"x402":{}}]},"description":"Check up to ten DOI citations against source registries, compare optional titles, and expose publication update signals. Use to detect incorrect references.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"citations":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"object","properties":{"doi":{"type":"string","minLength":7,"maxLength":200},"title":{"type":"string","minLength":3,"maxLength":500}},"required":["doi"],"additionalProperties":false},"examples":[[{"doi":"10.1056/NEJMoa2032183","title":"Once-Weekly Semaglutide in Adults with Overweight or Obesity"}]]}},"required":["citations"],"additionalProperties":false},"example":{"citations":[{"doi":"10.1056/NEJMoa2032183","title":"Once-Weekly Semaglutide in Adults with Overweight or Obesity"}]}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","properties":{"citations":{"type":"array","items":{"type":"object"}}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.02","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/brief":{"post":{"operationId":"brief","summary":"Build a source-linked evidence pack with scholarly papers, bibliography and optional registered clinical trials. Metadata only, no invented findings.","tags":["research","citations","science"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.05"},"protocols":[{"x402":{}}]},"description":"Build a source-linked evidence pack with scholarly papers, bibliography and optional registered clinical trials. Metadata only, no invented findings.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"query":{"type":"string","minLength":3,"maxLength":250,"examples":["semaglutide obesity"]},"limit":{"default":10,"type":"integer","minimum":1,"maximum":20,"examples":[5]},"fromYear":{"type":"integer","minimum":1900,"maximum":2026},"includeTrials":{"default":true,"type":"boolean","examples":[true]}},"required":["query"],"additionalProperties":false},"example":{"query":"semaglutide obesity","limit":5,"includeTrials":true}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","properties":{"literature":{"type":"object"},"clinicalTrials":{"type":"object"},"markdown":{"type":"string"}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.05","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/web-read":{"post":{"operationId":"web-read","summary":"Read a public static HTTPS webpage as clean text with headings, links, timestamp and content hash. Use to ground an answer or ingest documentation. Respects robots.txt; no JavaScript or login.","tags":["web","extraction","agent-tools"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"description":"Read a public static HTTPS webpage as clean text with headings, links, timestamp and content hash. Use to ground an answer or ingest documentation. Respects robots.txt; no JavaScript or login.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"url":{"type":"string","maxLength":2048,"examples":["https://example.com/"]},"maxCharacters":{"default":24000,"type":"integer","minimum":500,"maximum":40000,"examples":[24000]}},"required":["url"],"additionalProperties":false},"example":{"url":"https://example.com/","maxCharacters":24000}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","required":["url","retrievedAt","text","contentHash"],"properties":{"url":{"type":"string"},"requestedUrl":{"type":"string"},"retrievedAt":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"text":{"type":"string"},"truncated":{"type":"boolean"},"headings":{"type":"array","items":{"type":"object"}},"links":{"type":"array","items":{"type":"object"}},"jsonLd":{"type":"array"},"fields":{"type":"object"},"contentHash":{"type":"string"},"untrustedSource":{"const":true},"limitations":{"type":"array","items":{"type":"string"}}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.005","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/web-batch":{"post":{"operationId":"web-batch","summary":"Read up to three public static HTTPS webpages in one paid call for comparisons or multi-source context. All pages must succeed or the request is not settled.","tags":["web","extraction","agent-tools"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.012"},"protocols":[{"x402":{}}]},"description":"Read up to three public static HTTPS webpages in one paid call for comparisons or multi-source context. All pages must succeed or the request is not settled.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"urls":{"minItems":1,"maxItems":3,"type":"array","items":{"type":"string","maxLength":2048},"examples":[["https://example.com/"]]},"maxCharacters":{"default":12000,"type":"integer","minimum":500,"maximum":40000,"examples":[12000]}},"required":["urls"],"additionalProperties":false},"example":{"urls":["https://example.com/"],"maxCharacters":12000}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","required":["pages","count"],"properties":{"pages":{"type":"array","items":{"type":"object"}},"count":{"type":"integer"}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.012","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/web-extract":{"post":{"operationId":"web-extract","summary":"Extract published JSON-LD and optional CSS-selector fields from a public static HTTPS page. Use for product data, organization metadata or repeatable structured extraction. No inferred values.","tags":["web","extraction","agent-tools"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"description":"Extract published JSON-LD and optional CSS-selector fields from a public static HTTPS page. Use for product data, organization metadata or repeatable structured extraction. No inferred values.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"url":{"type":"string","maxLength":2048,"examples":["https://example.com/"]},"fields":{"default":[],"maxItems":10,"type":"array","items":{"type":"object","properties":{"name":{"type":"string","pattern":"^[a-zA-Z][a-zA-Z0-9_]{0,39}$"},"selector":{"type":"string","minLength":1,"maxLength":200},"attribute":{"type":"string","enum":["href","src","content","datetime"]}},"required":["name","selector"],"additionalProperties":false},"examples":[[{"name":"headings","selector":"h1"}]]}},"required":["url"],"additionalProperties":false},"example":{"url":"https://example.com/","fields":[{"name":"headings","selector":"h1"}]}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","required":["url","jsonLd","fields"],"properties":{"url":{"type":"string"},"retrievedAt":{"type":"string"},"title":{"type":"string"},"jsonLd":{"type":"array"},"fields":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}}},"method":{"type":"string"},"untrustedSource":{"const":true}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.01","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/api/v1/site-profile":{"post":{"operationId":"site-profile","summary":"Inspect a business or project website for its published description, structured data and pricing, contact, documentation and social links. Reports source claims, not verified company facts.","tags":["web","extraction","agent-tools"],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"description":"Inspect a business or project website for its published description, structured data and pricing, contact, documentation and social links. Reports source claims, not verified company facts.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"url":{"type":"string","maxLength":2048,"examples":["https://example.com/"]}},"required":["url"],"additionalProperties":false},"example":{"url":"https://example.com/"}}}},"responses":{"200":{"description":"Source-linked result. PAYMENT-RESPONSE contains settlement receipt.","content":{"application/json":{"schema":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","required":["url","title","usefulLinks"],"properties":{"url":{"type":"string"},"retrievedAt":{"type":"string"},"title":{"type":"string"},"description":{"type":"string"},"publishedStructuredData":{"type":"array"},"usefulLinks":{"type":"array","items":{"type":"object"}},"untrustedSource":{"const":true},"limitations":{"type":"array","items":{"type":"string"}}}},"durationMs":{"type":"integer","minimum":0},"feedback":{"type":"object","properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"url":{"type":"string","format":"uri"},"expiresInDays":{"const":30}},"required":["token","url","expiresInDays"]}}}}}},"400":{"description":"Invalid input; not charged."},"402":{"description":"x402 v2 payment required, invalid, or failed. Decode PAYMENT-REQUIRED or PAYMENT-RESPONSE."},"409":{"description":"Payment authorization already bound to another request, in flight, or pending reconciliation."},"429":{"description":"Rate limit; not charged."},"503":{"description":"Research unavailable or service not configured; not charged if settlement has not begun."}},"x-x402":{"scheme":"exact","network":"eip155:8453","currency":"USDC","priceUsd":"0.01","headers":{"request":"PAYMENT-SIGNATURE","challenge":"PAYMENT-REQUIRED","receipt":"PAYMENT-RESPONSE"}}}},"/feedback":{"post":{"operationId":"submitBuyerFeedback","security":[],"description":"Free. Submit one immutable rating using the private feedback token from a completed purchase. Never expose this token to source websites. Expires after 30 days; identical retries are idempotent.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["token","helpful"],"properties":{"token":{"type":"string","pattern":"^[a-f0-9]{64}$"},"helpful":{"type":"boolean"}}}}}},"responses":{"200":{"description":"Saved, or identical rating already saved."},"400":{"description":"Invalid input."},"404":{"description":"Unknown or expired token."},"409":{"description":"Purchase already rated differently."},"429":{"description":"Rate limited."}}}},"/catalog/search":{"get":{"operationId":"discoverTools","security":[],"description":"Free. Find enabled tools by relevance, with a bounded feedback adjustment after five distinct purchase ratings.","parameters":[{"in":"query","name":"q","schema":{"type":"string","maxLength":250}}],"responses":{"200":{"description":"Ranked tools, prices, examples and quality evidence."}}}},"/quality":{"get":{"operationId":"toolQuality","security":[],"description":"Free. Aggregate completed purchases and ratings over 30 days on the configured network. Contains no buyer addresses, inputs or feedback tokens.","responses":{"200":{"description":"Quality statistics."}}}},"/ready":{"get":{"operationId":"serviceReadiness","security":[],"description":"Free. Checks persistent storage writes and facilitator network support. Cached for 60 seconds; does not prove funded settlement.","responses":{"200":{"description":"Ready."},"503":{"description":"Not ready."}}}}},"components":{"schemas":{"ResultEnvelope":{"type":"object","required":["requestId","service","data"],"properties":{"requestId":{"type":"string"},"service":{"const":"Evidence402"},"data":{"type":"object","additionalProperties":true}}}}}}