{"openapi":"3.1.0","info":{"title":"Citation Proof API","version":"0.1.0","description":"Checks whether an exact quotation appears on its cited public HTML page. Quote presence does not assess claim truth or source reliability."},"servers":[{"url":"https://citation-proof-api.onrender.com"}],"paths":{"/health":{"get":{"operationId":"health","summary":"Free service health check","responses":{"200":{"description":"Service is available"}}}},"/v1/alive/session":{"post":{"operationId":"startAliveCheck","summary":"Start a paid five-question affirmation check","description":"One x402 payment of $0.50 USDC starts a 15-minute session. Answer five questions in order; answers do not trigger additional payment. Completion confirms only that this session reached the service and submitted five affirmations, not consciousness or biological life.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"properties":{}},"example":{}}}},"responses":{"201":{"description":"Paid session started with the first question"},"402":{"description":"Payment required using x402"}}}},"/v1/alive/answer":{"post":{"operationId":"answerAliveCheck","summary":"Submit the next affirmation","description":"Submit yes or I affirm for the current question_id. Complete all five in order within 15 minutes. No further payment is requested for answers.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["session_id","question_id","answer"],"properties":{"session_id":{"type":"string"},"question_id":{"type":"string","enum":["q1","q2","q3","q4","q5"]},"answer":{"type":"string","enum":["yes","I affirm"]}}},"example":{"session_id":"returned-session-id","question_id":"q1","answer":"yes"}}}},"responses":{"200":{"description":"Question accepted or the five-question check completed"},"409":{"description":"Question submitted out of sequence"},"410":{"description":"Session expired or completed"},"422":{"description":"Affirmative answer required"}}}},"/v1/verify":{"post":{"operationId":"verifyCitation","summary":"Check quote presence on a cited page","description":"Paid x402 request. Call only when an exact quotation and source URL are available. Quote presence does not mean the claim is supported.","requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":false,"required":["claim","source_url","quote"],"properties":{"claim":{"type":"string","minLength":1,"maxLength":2000},"source_url":{"type":"string","format":"uri","description":"Public HTTPS HTML page on an enabled hostname"},"quote":{"type":"string","minLength":1,"maxLength":2000}}},"example":{"claim":"The source says the program starts in May.","source_url":"https://example.org/program","quote":"The program opens in May."}}}},"responses":{"200":{"description":"Verification result","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Result"},"examples":{"found":{"value":{"status":"quote_found","source_url":"https://example.org/program","page_title":"Program dates","matched_quote":"The program opens in May.","checked_at":"2026-11-11T15:00:00Z","content_sha256":"sha256-hex","claim_assessment":"not_evaluated"}}}}}},"400":{"description":"Invalid request; no payment requested"},"402":{"description":"Payment required using x402"}}}}},"components":{"schemas":{"Result":{"type":"object","required":["status","source_url","page_title","matched_quote","checked_at","content_sha256","claim_assessment"],"properties":{"status":{"type":"string","enum":["quote_found","quote_not_found","source_unavailable"]},"source_url":{"type":"string"},"page_title":{"type":["string","null"]},"matched_quote":{"type":["string","null"]},"checked_at":{"type":"string","format":"date-time"},"content_sha256":{"type":["string","null"]},"claim_assessment":{"const":"not_evaluated"},"error":{"type":"string"}}}}}}