{"openapi":"3.1.0","info":{"title":"Colorblind-Safe Contrast Checker API","version":"0.1.0","description":"Pay-per-call API (x402, USDC) that checks colour pairs against WCAG contrast levels and tests whether they still work for people with red-green or blue-yellow colour blindness. Automated guidance, not a certified accessibility audit.","x-guidance":"Use POST /v1/check-contrast with JSON bodies. Unpaid calls receive HTTP 402 with x402 payment terms. See /llms.txt.","termsOfService":"https://ordstirr.com/agents/terms","contact":{"url":"https://ordstirr.com"}},"servers":[{"url":"https://contrast.ordstirr.com"}],"paths":{"/health":{"get":{"operationId":"health","summary":"Free health check","security":[],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/v1/check-contrast":{"post":{"operationId":"checkColourContrast","summary":"Check colour pairs for WCAG contrast and colour-blind safety, and a palette for colours that are hard to tell apart","description":"Send foreground/background hex pairs and/or a palette of hex colours. Returns contrast ratios with AA/AAA results, the same checks under protanopia, deuteranopia, tritanopia and achromatopsia, and any palette colours that are hard to tell apart. Automated guidance, not a certified audit. Unpaid calls receive HTTP 402 with x402 payment terms. Invalid input is rejected with HTTP 400 and never charged.","x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"pairs":{"type":"array","maxItems":20,"description":"Colour pairs to check.","items":{"type":"object","properties":{"foreground":{"type":"string","pattern":"^#?([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"background":{"type":"string","pattern":"^#?([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"label":{"type":"string","maxLength":40}},"required":["foreground","background"],"additionalProperties":false}},"palette":{"type":"array","maxItems":12,"description":"Hex colours that must be told apart from each other (for charts, status colours, game pieces).","items":{"type":"string","pattern":"^#?([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"}},"simulate":{"type":"boolean","description":"Include the colour-blindness checks. Default true."}},"additionalProperties":false},"example":{"pairs":[{"foreground":"#777777","background":"#FFFFFF","label":"grey body text"}],"palette":["#D55E00","#009E73","#0072B2"]}}}},"responses":{"200":{"description":"Result","content":{"application/json":{"schema":{"type":"object"},"example":{"pairs":[{"label":"grey body text","foreground":"#777777","background":"#FFFFFF","ratio":4.47,"normal_text_AA":false,"normal_text_AAA":false,"large_text_AA":true,"large_text_AAA":false,"ui_and_graphics_AA":true}],"palette":{"colours":["#D55E00","#009E73","#0072B2"],"confusable_pairs":[],"colourblind_safe":true},"summary":{"pairs_checked":1,"pairs_failing_normal_text_AA":1,"palette_colourblind_safe":true},"terms_url":"https://ordstirr.com/agents/terms","notice":"Informational only, not a certified accessibility audit. Review before relying on it."}}}},"400":{"description":"Invalid input (never charged)"},"402":{"description":"Payment required (x402). See the PAYMENT-REQUIRED header."},"413":{"description":"Request body too large (never charged)"}}}}}}