{"openapi":"3.1.0","info":{"title":"Swift Bot Labs Toolbox","version":"1.0.0","description":"62 deterministic utility APIs paid per call with x402 (USDC on Base). Failed calls are not charged.","contact":{"name":"Swift Bot Labs","url":"https://t.me/SwiftBotLabsBot"},"x-guidance":"Call any path without payment to receive an x402 v2 challenge (HTTP 402, PAYMENT-REQUIRED header). Sign the exact USDC amount and retry with PAYMENT-SIGNATURE. GET tools take query parameters; POST tools take a JSON body. Responses are {ok, tool, result, payment}."},"x-agentcash-guidance":{"llmsTxtUrl":"https://x402-toolbox.swiftbotlab.workers.dev/llms.txt"},"servers":[{"url":"https://x402-toolbox.swiftbotlab.workers.dev"}],"tags":[{"name":"DNS & e-mail"},{"name":"Web"},{"name":"EVM"},{"name":"x402"},{"name":"IP & CIDR"},{"name":"Data & text"},{"name":"Encode & hash"},{"name":"Convert"},{"name":"Validate & parse"}],"paths":{"/v1/dns/lookup":{"get":{"operationId":"dns_lookup","summary":"DNS lookup for any record type over DNS-over-HTTPS","description":"Resolve A, AAAA, MX, TXT, NS, CNAME, SOA, CAA, SRV, PTR, DS, DNSKEY, HTTPS, SVCB, TLSA or NAPTR records for a name. Returns answers with TTLs, the DNS status and whether DNSSEC validated. TXT strings are joined. Price: $0.005 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"dns-lookup","result":{"name":"example.com","type":"MX","status":"NOERROR","dnssecValidated":true,"answers":[{"name":"example.com","type":"MX","ttl":3600,"data":"0 ."}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"name","in":"query","required":true,"description":"Domain name (IDN allowed), e.g. example.com","schema":{"type":"string","maxLength":300,"description":"Domain name (IDN allowed), e.g. example.com"},"example":"example.com"},{"name":"type","in":"query","required":false,"description":"Record type","schema":{"type":"string","enum":["A","NS","CNAME","SOA","PTR","MX","TXT","AAAA","SRV","NAPTR","DS","DNSKEY","HTTPS","SVCB","CAA","TLSA"],"default":"A","description":"Record type"},"example":"MX"}]}},"/v1/dns/mx":{"get":{"operationId":"dns_mx","summary":"Mail servers (MX) of a domain, sorted, with the mail provider","description":"MX records sorted by priority, null-MX detection (RFC 7505), the implicit-MX fallback (A/AAAA) when no MX exists, and the detected mail provider (Google Workspace, Microsoft 365, Zoho, Proton, ...). Price: $0.005 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"dns-mx","result":{"domain":"github.com","acceptsMail":true,"nullMx":false,"provider":"Google Workspace","mx":[{"priority":1,"host":"aspmx.l.google.com","ttl":3600}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"domain","in":"query","required":true,"description":"Domain, e.g. example.com","schema":{"type":"string","maxLength":300,"description":"Domain, e.g. example.com"},"example":"github.com"}]}},"/v1/dns/reverse":{"get":{"operationId":"dns_reverse","summary":"Reverse DNS (PTR) for an IPv4 or IPv6 address, with forward confirmation","description":"Looks up the PTR name of an IP address and checks forward-confirmed reverse DNS (FCrDNS): whether the PTR hostname resolves back to the same IP. Price: $0.005 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"dns-reverse","result":{"ip":"8.8.8.8","ptrName":"8.8.8.8.in-addr.arpa","hostnames":["dns.google"],"forwardConfirmed":true}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"ip","in":"query","required":true,"description":"IPv4 or IPv6 address","schema":{"type":"string","maxLength":64,"description":"IPv4 or IPv6 address"},"example":"8.8.8.8"}]}},"/v1/dns/spf":{"get":{"operationId":"dns_spf","summary":"SPF record check: full include tree, DNS lookup count, problems","description":"Fetches the SPF record, expands include: and redirect= recursively, counts DNS-querying mechanisms against the RFC 7208 limit of 10, lists ip4/ip6 ranges and flags problems (multiple records, +all, ?all, missing includes, ptr, loops, void lookups). Price: $0.008 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.008"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"dns-spf","result":{"domain":"github.com","found":true,"record":"v=spf1 ip4:192.30.252.0/22 include:_netblocks.google.com ~all","policy":"softfail","dnsLookups":8,"lookupLimitExceeded":false,"issues":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string","maxLength":300},"example":"github.com"}]}},"/v1/dns/dmarc":{"get":{"operationId":"dns_dmarc","summary":"DMARC record check and parsed policy","description":"Reads _dmarc.<domain> (falling back to the organizational domain), parses p, sp, pct, rua, ruf, adkim, aspf and fo, and lists weaknesses (p=none, pct<100, no reporting address, duplicates). Price: $0.005 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"dns-dmarc","result":{"domain":"paypal.com","found":true,"policy":"reject","pct":100,"alignment":{"dkim":"relaxed","spf":"relaxed"},"issues":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string","maxLength":300},"example":"paypal.com"}]}},"/v1/email/validate":{"get":{"operationId":"email_validate","summary":"E-mail address check: syntax, MX, disposable, role, free provider, typos","description":"Validates an address without sending mail: RFC syntax, normalized IDN domain, MX (or implicit A) records, null-MX, disposable-domain list, role accounts (info@, admin@), free providers and typo suggestions (gmial.com -> gmail.com). Verdict: deliverable, risky, undeliverable or invalid. Price: $0.005 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"email-validate","result":{"email":"jane.doe@gmial.com","verdict":"risky","syntaxValid":true,"domain":"gmial.com","hasMx":false,"disposable":false,"role":false,"freeProvider":false,"suggestion":"jane.doe@gmail.com","reasons":["domain has no mail servers"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"email","in":"query","required":true,"schema":{"type":"string","maxLength":320},"example":"jane.doe@gmial.com"}]}},"/v1/email/security":{"get":{"operationId":"email_security","summary":"E-mail security audit of a domain: MX, SPF, DMARC, DKIM, MTA-STS, TLS-RPT, BIMI, grade","description":"One call audits a domain's mail setup: MX + provider, SPF tree and lookup count, DMARC policy, DKIM keys at common selectors, MTA-STS record and policy file, TLS-RPT, BIMI. Returns a 0-100 score, a letter grade and a prioritized list of fixes. Price: $0.02 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.02"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"email-security","result":{"domain":"github.com","score":85,"grade":"B","mx":{"provider":"Google Workspace"},"spf":{"found":true,"policy":"softfail"},"dmarc":{"found":true,"policy":"reject"},"dkim":{"found":["google"]},"mtaSts":{"found":false},"fixes":["Publish an MTA-STS policy"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string","maxLength":300},"example":"github.com"},{"name":"dkimSelectors","in":"query","required":false,"description":"Optional comma-separated extra DKIM selectors to check (max 5)","schema":{"type":"string","maxLength":200,"description":"Optional comma-separated extra DKIM selectors to check (max 5)"}}]}},"/v1/domain/rdap":{"get":{"operationId":"domain_rdap","summary":"Domain registration data (RDAP/WHOIS): registrar, created, expires, age, status","description":"Looks up the registry RDAP server for the TLD (IANA bootstrap) and returns the registrar, registration / expiry / last-changed dates, domain age in days, days until expiry, EPP status codes, nameservers and DNSSEC delegation. Useful for fraud and phishing checks (young domains). Price: $0.01 USDC per call (x402).","tags":["DNS & e-mail"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"domain-rdap","result":{"domain":"example.com","registrar":"RESERVED-Internet Assigned Numbers Authority","created":"1995-08-14T04:00:00Z","expires":"2026-08-13T04:00:00Z","ageDays":11397,"status":["client delete prohibited"],"nameservers":["a.iana-servers.net"],"dnssec":true}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"domain","in":"query","required":true,"schema":{"type":"string","maxLength":300},"example":"example.com"}]}},"/v1/web/extract":{"get":{"operationId":"web_extract","summary":"Fetch a web page and return clean main text and Markdown plus title and metadata","description":"Fetches a public URL (redirects followed and re-checked) and converts the HTML to clean text and Markdown: main/article content first, navigation/footers/scripts removed, links made absolute. Also returns title, description, language, canonical URL, headings and word count. Plain-text and JSON responses are returned as-is. Price: $0.01 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-extract","result":{"url":"https://example.com/","status":200,"title":"Example Domain","lang":"en","words":25,"markdown":"This domain is for use in documentation examples without needing permission. This is not a service; avoid relying on it for testing and monitoring purposes."}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"https://example.com"},{"name":"format","in":"query","required":false,"schema":{"type":"string","enum":["markdown","text","both"],"default":"markdown"},"example":"markdown"},{"name":"mode","in":"query","required":false,"description":"\"main\" keeps the article/main region and drops nav/header/footer","schema":{"type":"string","enum":["main","all"],"default":"main","description":"\"main\" keeps the article/main region and drops nav/header/footer"}},{"name":"maxChars","in":"query","required":false,"schema":{"type":"integer","minimum":500,"maximum":200000,"default":40000}}]}},"/v1/web/metadata":{"get":{"operationId":"web_metadata","summary":"Page metadata for link previews and SEO: title, description, OpenGraph, Twitter card, JSON-LD, favicon","description":"Fetches a URL and returns title, meta description, canonical, language, robots, OpenGraph and Twitter-card tags, JSON-LD blocks, favicon, RSS/Atom feeds, hreflang alternates and a short SEO checklist (title/description length, canonical, h1 count). Price: $0.008 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.008"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-metadata","result":{"url":"https://github.com/","title":"GitHub · Build and ship software on a single, collaborative platform","og":{"title":"GitHub","image":"https://github.githubassets.com/assets/home24-5939032587c9.jpg"},"favicon":"https://github.githubassets.com/favicons/favicon.svg","seo":{"titleLength":71,"h1Count":1}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"https://github.com"}]}},"/v1/web/links":{"get":{"operationId":"web_links","summary":"All links on a page, absolute, de-duplicated, split into internal and external","description":"Fetches a page and returns every <a href> as an absolute URL with its anchor text and rel, de-duplicated, marked internal or external (same registrable host), plus counts of nofollow links, mailto/tel links and images. Price: $0.008 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.008"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-links","result":{"url":"https://news.ycombinator.com/","total":197,"internal":163,"external":33,"returned":5,"links":[{"href":"https://www.ycombinator.com/","text":"","rel":null,"internal":false,"scheme":"https","nofollow":false}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"https://news.ycombinator.com"},{"name":"filter","in":"query","required":false,"schema":{"type":"string","enum":["all","internal","external"],"default":"all"},"example":"external"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":2000,"default":500},"example":5}]}},"/v1/web/headers":{"get":{"operationId":"web_headers","summary":"HTTP status, response headers, redirect chain, timing and a security-header audit","description":"Requests a URL (HEAD or GET) and returns the final status, every redirect hop, response headers, latency and an audit of security headers (HSTS, CSP, X-Frame-Options, X-Content-Type-Options, Referrer-Policy, Permissions-Policy, COOP/CORP) with a grade, plus cookie flags (Secure, HttpOnly, SameSite) without cookie values. Price: $0.005 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-headers","result":{"url":"https://github.com/","status":200,"redirects":[{"status":301,"from":"http://github.com/","to":"https://github.com/"}],"ms":180,"security":{"grade":"A","present":["strict-transport-security","content-security-policy"],"missing":[]}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"http://github.com"},{"name":"method","in":"query","required":false,"schema":{"type":"string","enum":["HEAD","GET"],"default":"GET"}}]}},"/v1/web/robots":{"get":{"operationId":"web_robots","summary":"Is a URL allowed for a crawler by robots.txt? Rules, crawl-delay and sitemaps","description":"Fetches the site's /robots.txt and evaluates a URL path for a user-agent with RFC 9309 matching (longest match wins, * and $ wildcards). Returns allowed/disallowed, the deciding rule, crawl-delay, declared sitemaps and the agent groups present. Price: $0.005 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-robots","result":{"robotsUrl":"https://www.google.com/robots.txt","path":"/search?q=x","userAgent":"GPTBot","allowed":false,"matchedRule":"Disallow: /search","sitemaps":["https://www.google.com/sitemap.xml"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"description":"Page URL (its origin's robots.txt is read)","schema":{"type":"string","maxLength":2048,"description":"Page URL (its origin's robots.txt is read)"},"example":"https://www.google.com/search?q=x"},{"name":"userAgent","in":"query","required":false,"schema":{"type":"string","maxLength":200,"default":"*"},"example":"GPTBot"}]}},"/v1/web/sitemap":{"get":{"operationId":"web_sitemap","summary":"Read a sitemap.xml (or a site's default sitemap): URLs with lastmod, child sitemaps","description":"Fetches a sitemap URL, or for a bare site URL tries the sitemaps declared in robots.txt and then /sitemap.xml. Returns page URLs with lastmod/changefreq/priority, or the child sitemaps of a sitemap index. Up to 5,000 entries; gzip sitemaps are not decoded. Price: $0.008 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.008"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"web-sitemap","result":{"sitemapUrl":"https://www.cloudflare.com/sitemap.xml","type":"urlset","total":4211,"urls":[{"loc":"https://www.cloudflare.com/","lastmod":"2026-10-20"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"https://www.cloudflare.com/sitemap.xml"},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":5000,"default":1000},"example":3}]}},"/v1/html/extract":{"post":{"operationId":"html_extract","summary":"Convert HTML you already have to clean text / Markdown and extract its metadata and links","description":"Same engine as web-extract, without fetching: send up to 2 MB of HTML (and an optional base URL for resolving links) and get Markdown and/or plain text, title, description, OpenGraph, headings, links and images. Price: $0.005 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"html-extract","result":{"title":null,"words":4,"markdown":"# Hi\n\nRead [the docs](https://example.com/docs).","links":[{"href":"https://example.com/docs","text":"the docs"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"html":{"type":"string","maxLength":2097152},"baseUrl":{"type":"string","maxLength":2048},"format":{"type":"string","enum":["markdown","text","both"],"default":"markdown"},"mode":{"type":"string","enum":["main","all"],"default":"all"},"maxChars":{"type":"integer","minimum":500,"maximum":200000,"default":40000}},"required":["html"]},"example":{"html":"<h1>Hi</h1><p>Read <a href=\"/docs\">the docs</a>.</p>","baseUrl":"https://example.com"}}}}}},"/v1/url/parse":{"get":{"operationId":"url_parse","summary":"Parse, normalize and clean a URL (components, query params, punycode, tracking params removed)","description":"Splits a URL into scheme, host (Unicode and punycode), port, path, query parameters and fragment; returns a normalized form (lowercase host, default port dropped, sorted query) and a clean form with tracking parameters (utm_*, fbclid, gclid, ...) removed. No network access. Price: $0.003 USDC per call (x402).","tags":["Web"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"url-parse","result":{"valid":true,"scheme":"https","host":"example.com","path":"/b/","query":{"utm_source":"x","id":"7","fbclid":"abc"},"normalized":"https://example.com/b/?fbclid=abc&id=7&utm_source=x#top","clean":"https://example.com/b/?id=7#top","removedTracking":["utm_source","fbclid"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":8192},"example":"HTTPS://Example.COM:443/a/../b/?utm_source=x&id=7&fbclid=abc#top"}]}},"/v1/evm/address":{"get":{"operationId":"evm_address","summary":"Validate an EVM address and return its EIP-55 checksum form","description":"Checks the 0x + 40 hex format, verifies a mixed-case EIP-55 checksum (flags typos), and returns the checksummed and lowercase forms and whether it is the zero address. No network access. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-address","result":{"valid":true,"checksummed":"0x2481E29895b43e87e547a50fB0BB5aa1E70585EB","lowercase":"0x2481e29895b43e87e547a50fb0bb5aa1e70585eb","hadChecksum":false,"isZero":false}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"address","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"0x2481e29895b43e87e547a50fb0bb5aa1e70585eb"}]}},"/v1/evm/contract":{"get":{"operationId":"evm_contract","summary":"Is an address a contract or a wallet? Code size, EIP-1967 proxy implementation/admin/beacon, EIP-7702 delegation","description":"Reads the bytecode of an address on a chain: EOA vs contract, code size and hash, EIP-7702 delegated EOAs, minimal-proxy (EIP-1167) targets, EIP-1967 implementation/admin/beacon slots and legacy ZeppelinOS proxies (e.g. USDC). Also returns the native balance and nonce. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-contract","result":{"address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","chain":"base","type":"contract","codeSize":1852,"proxy":{"standard":"ZeppelinOS (legacy unstructured storage)","implementation":"0x2Ce6311ddAE708829bc0784C967b7d77D19FD779"}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"address","in":"query","required":true,"schema":{"type":"string","maxLength":42,"pattern":"^0x[0-9a-fA-F]{40}$"},"example":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"},{"name":"chain","in":"query","required":false,"description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)","schema":{"type":"string","maxLength":20,"default":"ethereum","description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)"},"example":"base"}]}},"/v1/evm/selector":{"get":{"operationId":"evm_selector","summary":"Function selector and event topic for a Solidity signature","description":"Normalizes a function/event/error signature (drops parameter names, expands uint to uint256, handles tuples and arrays) and returns the 4-byte selector and the 32-byte event topic. No network access. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-selector","result":{"canonical":"transfer(address,uint256)","selector":"0xa9059cbb","topic":"0x..."}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"signature","in":"query","required":true,"description":"e.g. transfer(address to, uint256 amount)","schema":{"type":"string","maxLength":1000,"description":"e.g. transfer(address to, uint256 amount)"},"example":"function transfer(address to, uint amount) external returns (bool)"}]}},"/v1/evm/selector-lookup":{"get":{"operationId":"evm_selector_lookup","summary":"Reverse-lookup 4-byte function selectors and 32-byte event topics to signatures","description":"Looks up up to 20 selectors (0x + 8 hex) and event topics (0x + 64 hex) in the public openchain signature database (4byte.directory fallback) and returns candidate signatures, verified-contract ones first. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-selector-lookup","result":{"functions":{"0xa9059cbb":[{"signature":"transfer(address,uint256)","verified":true}]},"events":{"0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef":[{"signature":"Transfer(address,address,uint256)","verified":true}]}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"selectors","in":"query","required":true,"description":"Selectors/topics, comma separated or array","schema":{"type":"string","maxItems":20,"maxLength":1500,"description":"Selectors/topics, comma separated or array"},"example":"0xa9059cbb,0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef"}]}},"/v1/evm/abi-encode":{"post":{"operationId":"abi_encode","summary":"ABI-encode values (or full calldata for a function signature)","description":"Encodes values per the Solidity ABI: all integer sizes (range-checked), address, bool, bytesN, bytes, string, fixed and dynamic arrays and tuples (nested). With a function signature, returns calldata with the selector. Integers may be decimal or 0x strings. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"abi-encode","result":{"selector":"0xa9059cbb","data":"0xa9059cbb0000000000000000000000002481e29895b43e87e547a50fb0bb5aa1e70585eb00000000000000000000000000000000000000000000000000000000000f4240","bytes":68}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"signature":{"type":"string","maxLength":1000,"description":"Function signature, e.g. transfer(address,uint256)"},"types":{"type":["array","string"],"items":{"type":"string","maxLength":200},"maxItems":64,"maxLength":2000,"description":"Alternatively a list of types"},"values":{"type":"array","maxItems":64,"description":"Values in order; tuples as arrays"}},"required":["values"]},"example":{"signature":"transfer(address,uint256)","values":["0x2481E29895b43e87e547a50fB0BB5aa1E70585EB","1000000"]}}}}}},"/v1/evm/abi-decode":{"post":{"operationId":"abi_decode","summary":"ABI-decode calldata, return data or log data with known types or a signature","description":"Decodes hex data with a list of ABI types or a function signature (the 4-byte selector is stripped and checked when present). Strict: every offset and length is bounds-checked and dirty padding is rejected. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"abi-decode","result":{"signature":"transfer(address,uint256)","selectorMatched":true,"values":[{"type":"address","value":"0x2481E29895b43e87e547a50fB0BB5aa1E70585EB"},{"type":"uint256","value":"1000000"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","maxLength":262144},"signature":{"type":"string","maxLength":1000},"types":{"type":["array","string"],"items":{"type":"string","maxLength":200},"maxItems":64,"maxLength":2000}},"required":["data"]},"example":{"data":"0xa9059cbb0000000000000000000000002481e29895b43e87e547a50fb0bb5aa1e70585eb00000000000000000000000000000000000000000000000000000000000f4240","signature":"transfer(address,uint256)"}}}}}},"/v1/evm/calldata-decode":{"post":{"operationId":"calldata_decode","summary":"Decode unknown transaction calldata: find the function signature and decode the arguments","description":"Looks up the selector (built-in list, then openchain / 4byte), tries each candidate signature and keeps the first one that decodes and re-encodes to exactly the same bytes, so collisions are filtered out. Returns the function, arguments and the other candidates. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"calldata-decode","result":{"selector":"0x095ea7b3","decoded":{"signature":"approve(address,uint256)","args":[{"type":"address","value":"0x2481E29895b43e87e547a50fB0BB5aa1E70585EB"},{"type":"uint256","value":"115792089237316195423570985008687907853269984665640564039457584007913129639935"}]},"candidates":1}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","maxLength":262144}},"required":["data"]},"example":{"data":"0x095ea7b30000000000000000000000002481e29895b43e87e547a50fb0bb5aa1e70585ebffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"}}}}}},"/v1/evm/tx":{"get":{"operationId":"evm_tx","summary":"Explain an EVM transaction: status, fee, decoded method, ERC-20/721 transfers","description":"Fetches a transaction and its receipt from a public RPC: from/to, value, status, block and time, gas used, effective gas price and fee in native currency, the decoded method call, and every Transfer event (ERC-20 amounts formatted with token decimals and symbols, ERC-721 token ids). Price: $0.01 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-tx","result":{"hash":"0x5e07...","chain":"base-sepolia","status":"success","from":"0xD48e...","to":"0x036C...","method":{"signature":"transferWithAuthorization(...)"},"fee":"0.0000012","transfers":[{"token":"0x036C...","symbol":"USDC","from":"0xD48e...","to":"0x2481...","amount":"0.02"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"hash","in":"query","required":true,"schema":{"type":"string","pattern":"^0x[0-9a-fA-F]{64}$","maxLength":66},"example":"0x5e074b70af40164915a9e379c4b02e77267d56adc34cc8d924d39c4632b45710"},{"name":"chain","in":"query","required":false,"description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)","schema":{"type":"string","maxLength":20,"default":"ethereum","description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)"},"example":"base-sepolia"}]}},"/v1/evm/token":{"get":{"operationId":"evm_token","summary":"ERC-20 token metadata: name, symbol, decimals, total supply (on-chain)","description":"Reads name(), symbol(), decimals() and totalSupply() directly from the token contract on the chosen chain (handles bytes32 names), and formats the supply with the token's decimals. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-token","result":{"address":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","chain":"base","name":"USD Coin","symbol":"USDC","decimals":6,"totalSupply":"4123456789.123456","isErc20":true}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"address","in":"query","required":true,"schema":{"type":"string","maxLength":42,"pattern":"^0x[0-9a-fA-F]{40}$"},"example":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"},{"name":"chain","in":"query","required":false,"description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)","schema":{"type":"string","maxLength":20,"default":"ethereum","description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)"},"example":"base"}]}},"/v1/evm/balance":{"get":{"operationId":"evm_balance","summary":"Native and ERC-20 balances of an address","description":"Native coin balance plus the balance of up to 10 ERC-20 tokens (raw and formatted with decimals and symbol) for an address on the chosen chain, read at the latest block. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-balance","result":{"address":"0x2481E29895b43e87e547a50fB0BB5aa1E70585EB","chain":"base","native":{"symbol":"ETH","balance":"0.0012"},"tokens":[{"token":"0x8335...","symbol":"USDC","balance":"1.25"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"address","in":"query","required":true,"schema":{"type":"string","maxLength":42,"pattern":"^0x[0-9a-fA-F]{40}$"},"example":"0x2481E29895b43e87e547a50fB0BB5aa1E70585EB"},{"name":"chain","in":"query","required":false,"description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)","schema":{"type":"string","maxLength":20,"default":"ethereum","description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)"},"example":"base"},{"name":"tokens","in":"query","required":false,"description":"Token contract addresses (optional)","schema":{"type":"string","maxItems":10,"maxLength":500,"description":"Token contract addresses (optional)"},"example":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913"}]}},"/v1/evm/gas":{"get":{"operationId":"evm_gas","summary":"Current gas price, base fee and priority fee on an EVM chain","description":"Latest block number, base fee, suggested priority fee and gas price in gwei, plus the cost in native currency of a 21,000-gas transfer and a 65,000-gas ERC-20 transfer at the current price. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-gas","result":{"chain":"base","block":37512345,"baseFeeGwei":"0.0052","priorityFeeGwei":"0.001","gasPriceGwei":"0.0062","costs":{"nativeTransfer":"0.000000130","erc20Transfer":"0.000000403"}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"chain","in":"query","required":false,"description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)","schema":{"type":"string","maxLength":20,"default":"ethereum","description":"One of ethereum, base, arbitrum, optimism, polygon, bsc, avalanche, gnosis, base-sepolia, sepolia (or a chain id)"},"example":"base"}]}},"/v1/evm/ens":{"get":{"operationId":"ens_resolve","summary":"ENS: resolve a name to an address, or an address to its primary name (verified)","description":"Give \"name\" (vitalik.eth) to get its Ethereum address, resolver and namehash; give \"address\" to get its primary ENS name via reverse resolution, verified by resolving the name forward again. Reads the ENS registry on Ethereum mainnet. Price: $0.005 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"ens-resolve","result":{"name":"vitalik.eth","address":"0xd8dA6BF26964aF9D7eEd9e03E53415D37aA96045","resolver":"0x231b0Ee14048e9dCcD1d247744d114a4EB5E8E63","namehash":"0xee6c4522aab0003e8d14cd40a6af439055fd2577951148c14b6cea9a53475835"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"name","in":"query","required":false,"schema":{"type":"string","maxLength":255},"example":"vitalik.eth"},{"name":"address","in":"query","required":false,"schema":{"type":"string","maxLength":42}}]}},"/v1/evm/units":{"get":{"operationId":"evm_units","summary":"Exact conversion between wei, gwei, ether or any token decimals","description":"Converts an amount between wei / gwei / ether (or any decimals 0-36, e.g. 6 for USDC) with exact integer arithmetic (no floating-point rounding), and refuses conversions that would drop digits. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-units","result":{"value":"1.5","from":"ether","to":"gwei","result":"1500000000","wei":"1500000000000000000"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"value","in":"query","required":true,"schema":{"type":"string","maxLength":100},"example":"1.5"},{"name":"from","in":"query","required":false,"description":"wei, gwei, ether, or a number of decimals","schema":{"type":"string","maxLength":10,"default":"ether","description":"wei, gwei, ether, or a number of decimals"},"example":"ether"},{"name":"to","in":"query","required":false,"schema":{"type":"string","maxLength":10,"default":"wei"},"example":"gwei"}]}},"/v1/evm/verify-message":{"post":{"operationId":"evm_verify_message","summary":"Recover the signer of an EIP-191 personal_sign message and check it against an address","description":"Computes the EIP-191 message hash and recovers the signing address from a 65-byte signature (v = 27/28 or 0/1), optionally comparing it with an expected address. Works for Sign-In-With-Ethereum messages and wallet login challenges. Contract (EIP-1271) wallets are not checked. Price: $0.003 USDC per call (x402).","tags":["EVM"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"evm-verify-message","result":{"recovered":"0x...","matches":true,"messageHash":"0x50b2c43fd39106bafbba0da34fc430e1f91e3c96ea2acee2bc34119f92b37750"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","maxLength":65536},"signature":{"type":"string","pattern":"^0x[0-9a-fA-F]{130}$","maxLength":132},"address":{"type":"string","maxLength":42},"messageEncoding":{"type":"string","enum":["utf8","hex"],"default":"utf8"}},"required":["message","signature"]},"example":{"message":"hello","signature":"0xababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababababab"}}}}}},"/v1/x402/check":{"get":{"operationId":"x402_check","summary":"Probe an x402 endpoint: alive? what does it charge, on which chain, to whom? Is its 402 valid?","description":"Calls a paid URL without paying and inspects the 402 challenge: x402 version, every accepted payment option (scheme, network, asset, USDC price in dollars, payTo, timeout), resource description, Bazaar discovery metadata, latency, and a list of spec problems that break clients. Nothing is paid. Price: $0.01 USDC per call (x402).","tags":["x402"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"x402-check","result":{"url":"https://api.bitrefill.com/x402/gift-cards/search","alive":true,"status":402,"isX402":true,"x402Version":2,"latencyMs":210,"accepts":[{"scheme":"exact","network":"eip155:8453","chain":"Base","assetSymbol":"USDC","priceUsd":0.002,"payTo":"0x..."}],"bazaar":true,"issues":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"url","in":"query","required":true,"schema":{"type":"string","maxLength":2048},"example":"https://api.bitrefill.com/x402/gift-cards/search"},{"name":"method","in":"query","required":false,"schema":{"type":"string","enum":["GET","POST","HEAD"],"default":"GET"}}]}},"/v1/x402/search":{"get":{"operationId":"x402_search","summary":"Search the x402 Bazaar catalogs for paid APIs by keyword, with prices","description":"Searches the public discovery catalogs of the Coinbase CDP facilitator and the PayAI facilitator, merges and de-duplicates the results and returns each resource URL with its description, method, network and USD price. Filter by network or maximum price. Price: $0.01 USDC per call (x402).","tags":["x402"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.01"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"x402-search","result":{"query":"weather forecast","count":2,"results":[{"url":"https://api.example.com/weather","description":"Weather forecast by city","priceUsd":0.01,"network":"eip155:8453","sources":["cdp"]}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"query","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":200},"example":"weather forecast"},{"name":"network","in":"query","required":false,"description":"e.g. eip155:8453 or base","schema":{"type":"string","maxLength":60,"description":"e.g. eip155:8453 or base"},"example":"base"},{"name":"maxPriceUsd","in":"query","required":false,"schema":{"type":"number","minimum":0},"example":0.05},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":20}}]}},"/v1/ip/info":{"get":{"operationId":"ip_info","summary":"Parse and classify an IPv4/IPv6 address (private, loopback, CGNAT, documentation, ...)","description":"Canonical and expanded forms, integer and hex values, version, scope per the IANA special-purpose registries (private, loopback, link-local, CGNAT, multicast, documentation, 6to4, NAT64, IPv4-mapped with the embedded address), whether it is globally routable, and the reverse-DNS name. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"ip-info","result":{"input":"::ffff:192.168.1.10","version":6,"canonical":"::ffff:c0a8:10a","scope":"ipv4-mapped","global":false,"embeddedIPv4":"192.168.1.10","embeddedScope":"private"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"ip","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"::ffff:192.168.1.10"}]}},"/v1/ip/cidr":{"get":{"operationId":"cidr_info","summary":"Subnet calculator for an IPv4/IPv6 CIDR block","description":"Network and broadcast addresses, first/last usable host, netmask and wildcard, number of addresses and usable hosts, address class and scope. Notes when the input had host bits set. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"cidr-info","result":{"cidr":"192.168.10.64/26","network":"192.168.10.64","broadcast":"192.168.10.127","firstUsable":"192.168.10.65","lastUsable":"192.168.10.126","netmask":"255.255.255.192","addresses":"64","usableHosts":"62","hostBitsWereSet":true}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"cidr","in":"query","required":true,"description":"e.g. 10.0.0.0/22 or 2001:db8::/48","schema":{"type":"string","maxLength":64,"description":"e.g. 10.0.0.0/22 or 2001:db8::/48"},"example":"192.168.10.77/26"}]}},"/v1/ip/contains":{"post":{"operationId":"cidr_contains","summary":"Which of these IPs fall inside which CIDR ranges (allowlist / blocklist check)","description":"Checks up to 1,000 IPs against up to 1,000 CIDR blocks (IPv4 and IPv6) and returns, per IP, every matching range. Invalid entries are reported, not fatal. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"cidr-contains","result":{"results":[{"ip":"10.1.2.3","matches":["10.0.0.0/8"],"contained":true},{"ip":"8.8.8.8","matches":[],"contained":false}],"invalidCidrs":[],"invalidIps":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cidrs":{"type":["array","string"],"items":{"type":"string","maxLength":64},"maxItems":1000,"maxLength":40000,"description":"CIDR blocks (JSON array, or a comma/space separated string)"},"ips":{"type":["array","string"],"items":{"type":"string","maxLength":64},"maxItems":1000,"maxLength":40000,"description":"IP addresses (JSON array, or a comma/space separated string)"}},"required":["cidrs","ips"]},"example":{"cidrs":["10.0.0.0/8","192.168.0.0/16"],"ips":["10.1.2.3","8.8.8.8"]}}}}}},"/v1/ip/split":{"get":{"operationId":"cidr_split","summary":"Split a CIDR block into smaller subnets","description":"Lists the subnets of a given prefix length inside a parent block (e.g. a /16 into /24s), up to 4,096 per call, with the total count. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"cidr-split","result":{"parent":"10.0.0.0/22","newPrefix":24,"total":"4","returned":4,"truncated":false,"subnets":["10.0.0.0/24","10.0.1.0/24","10.0.2.0/24","10.0.3.0/24"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"cidr","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"10.0.0.0/22"},{"name":"newPrefix","in":"query","required":true,"schema":{"type":"integer","minimum":0,"maximum":128},"example":24},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":4096,"default":256}}]}},"/v1/ip/aggregate":{"post":{"operationId":"cidr_aggregate","summary":"Merge / summarize a list of CIDRs into the smallest equivalent set","description":"Collapses overlapping and adjacent IPv4/IPv6 ranges (route summarization), returning the minimal CIDR list that covers exactly the same addresses. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"cidr-aggregate","result":{"input":4,"output":2,"cidrs":["10.0.0.0/22","192.168.1.5/32"],"invalid":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"cidrs":{"type":["array","string"],"items":{"type":"string","maxLength":64},"maxItems":1000,"maxLength":40000,"description":"CIDR blocks or single IPs (JSON array, or a comma/space separated string)"}},"required":["cidrs"]},"example":{"cidrs":["10.0.0.0/24","10.0.1.0/24","10.0.2.0/23","192.168.1.5"]}}}}}},"/v1/ip/range":{"get":{"operationId":"ip_range_to_cidr","summary":"Convert an IP range (start - end) to the minimal list of CIDR blocks","description":"Exact conversion of an inclusive address range to CIDR blocks, IPv4 or IPv6, up to 1,000 blocks. Price: $0.003 USDC per call (x402).","tags":["IP & CIDR"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"ip-range-to-cidr","result":{"start":"10.0.0.5","end":"10.0.0.20","cidrs":["10.0.0.5/32","10.0.0.6/31","10.0.0.8/29","10.0.0.16/30","10.0.0.20/32"],"truncated":false}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"10.0.0.5"},{"name":"end","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"10.0.0.20"}]}},"/v1/json/validate":{"post":{"operationId":"json_validate","summary":"Validate JSON data against a JSON Schema (draft 2020-12 / draft-07)","description":"Checks data against a schema: types, enum/const, numeric and string limits, patterns, formats (email, date-time, uri, uuid, ipv4/6, hostname), arrays, objects, $ref (same document), allOf/anyOf/oneOf/not, if/then/else. Returns every error with its JSON Pointer path. Remote $ref is not fetched. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"json-validate","result":{"valid":false,"errorCount":2,"errors":[{"path":"/id","keyword":"minimum","message":"must be >= 1"},{"path":"/email","keyword":"format","message":"must be a valid email"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"schema":{"description":"JSON Schema (a JSON value, or a string containing JSON)"},"data":{"description":"Data to validate (any JSON value; a string is parsed as JSON when it is valid JSON, otherwise validated as a plain string)"},"formats":{"type":"boolean","default":true,"description":"Assert \"format\" keywords"}},"required":["schema","data"]},"example":{"schema":{"type":"object","required":["id"],"properties":{"id":{"type":"integer","minimum":1},"email":{"type":"string","format":"email"}}},"data":{"id":0,"email":"nope"}}}}}}},"/v1/json/format":{"post":{"operationId":"json_format","summary":"Parse, pretty-print, minify or canonicalize JSON (sorted keys); locate syntax errors","description":"Parses JSON and returns it pretty-printed (2/4 spaces or tabs), minified, or canonical with sorted keys, plus size, node count and depth. On invalid JSON, reports the error position with line and column. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"json-format","result":{"valid":true,"result":"{\"a\":[1,2,{\"c\":null}],\"b\":1}","bytes":27,"nodes":6,"depth":3}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"json":{"type":"string","maxLength":524288,"description":"JSON text"},"mode":{"type":"string","enum":["pretty","minify","canonical"],"default":"pretty"},"indent":{"type":"integer","enum":[0,2,4,8],"default":2},"sortKeys":{"type":"boolean","default":false}},"required":["json"]},"example":{"json":"{\"b\":1,\"a\":[1,2,{\"c\":null}]}","mode":"canonical"}}}}}},"/v1/json/query":{"post":{"operationId":"json_query","summary":"Extract values from JSON with a JSON Pointer or a dotted path (a.b[0].c, items[*].id)","description":"Reads one value by RFC 6901 JSON Pointer (/a/b/0) or a dotted path with [index] and [*] wildcards. Up to 20 paths per call. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"json-query","result":{"results":[{"path":"items[*].id","found":true,"value":[1,2],"multiple":true},{"path":"/meta/next","found":true,"value":null}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"json":{"description":"Document (a JSON value, or a string containing JSON)"},"path":{"type":"string","maxLength":1000},"paths":{"type":"array","items":{"type":"string","maxLength":1000},"maxItems":20}},"required":["json"]},"example":{"json":{"items":[{"id":1},{"id":2}],"meta":{"next":null}},"paths":["items[*].id","/meta/next"]}}}}}},"/v1/json/diff":{"post":{"operationId":"json_diff","summary":"Structural diff of two JSON documents as JSON-Patch-style operations","description":"Compares two JSON values key by key and index by index and returns add / remove / replace operations with JSON Pointer paths and old and new values (up to 2,000 operations). Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"json-diff","result":{"equal":false,"count":2,"operations":[{"op":"add","path":"/tags/1","value":"b"},{"op":"replace","path":"/v","old":1,"value":2}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"a":{"description":"Original (a JSON value, or a string containing JSON)"},"b":{"description":"Changed (a JSON value, or a string containing JSON)"}},"required":["a","b"]},"example":{"a":{"name":"x","tags":["a"],"v":1},"b":{"name":"x","tags":["a","b"],"v":2}}}}}}},"/v1/csv/to-json":{"post":{"operationId":"csv_to_json","summary":"CSV / TSV to JSON (RFC 4180 quoting, delimiter auto-detect, type inference)","description":"Parses CSV with quoted fields, embedded newlines and doubled quotes; auto-detects comma, semicolon, tab or pipe. Returns an array of objects (using the header row) or of arrays, optionally inferring numbers, booleans and nulls. Up to 50,000 rows. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"csv-to-json","result":{"rows":2,"columns":["name","age","active"],"delimiter":",","data":[{"name":"Doe, Jane","age":34,"active":true},{"name":"Bob","age":null,"active":false}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"csv":{"type":"string","maxLength":1048576},"delimiter":{"type":"string","enum":["auto",",",";","\t","|"],"default":"auto"},"header":{"type":"boolean","default":true},"inferTypes":{"type":"boolean","default":true}},"required":["csv"]},"example":{"csv":"name,age,active\n\"Doe, Jane\",34,true\nBob,,false"}}}}}},"/v1/json/to-csv":{"post":{"operationId":"json_to_csv","summary":"JSON array of objects to CSV (nested objects flattened to dot.keys)","description":"Converts an array of objects (or arrays) to CSV with a header row built from the union of keys. Nested objects become dot.separated columns, arrays are JSON-encoded, and cells starting with = + - @ are escaped against spreadsheet formula injection. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"json-to-csv","result":{"rows":2,"columns":["id","user.name","tags"],"csv":"id,user.name,tags\r\n1,Ann,\r\n2,Bo,\"[\"\"x\"\"]\"\r\n"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"json":{"description":"Array of objects (a JSON value, or a string containing JSON)"},"delimiter":{"type":"string","enum":[",",";","\t","|"],"default":","},"flatten":{"type":"boolean","default":true}},"required":["json"]},"example":{"json":[{"id":1,"user":{"name":"Ann"}},{"id":2,"user":{"name":"Bo"},"tags":["x"]}]}}}}}},"/v1/text/stats":{"post":{"operationId":"text_stats","summary":"Text statistics: words, sentences, reading time, readability, top keywords","description":"Counts characters, graphemes, words, sentences, paragraphs and lines; estimates reading and speaking time; computes Flesch reading ease and Flesch-Kincaid grade (English) and the most frequent keywords without stop words. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"text-stats","result":{"characters":55,"words":11,"sentences":2,"readingTimeSeconds":3,"fleschReadingEase":94.3,"topKeywords":[{"word":"quick","count":1}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","maxLength":1048576},"top":{"type":"integer","minimum":0,"maximum":100,"default":10}},"required":["text"]},"example":{"text":"The quick brown fox jumps over the lazy dog. It barked."}}}}}},"/v1/text/diff":{"post":{"operationId":"text_diff","summary":"Line diff of two texts as a unified diff with added/removed counts","description":"Computes a minimal line-based diff (LCS) between two texts and returns unified-diff hunks with configurable context, plus counts of added and removed lines. Up to 5,000 lines per side. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"text-diff","result":{"identical":false,"added":2,"removed":1,"hunks":1,"unified":"@@ -1,3 +1,4 @@\n one\n-two\n+2\n three\n+four"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"a":{"type":"string","maxLength":524288},"b":{"type":"string","maxLength":524288},"context":{"type":"integer","minimum":0,"maximum":20,"default":3}},"required":["a","b"]},"example":{"a":"one\ntwo\nthree","b":"one\n2\nthree\nfour"}}}}}},"/v1/text/transform":{"post":{"operationId":"text_transform","summary":"Slugify and case conversion (camel, snake, kebab, title, constant ...), trim, dedupe lines","description":"Transforms text: slug, camelCase, PascalCase, snake_case, kebab-case, CONSTANT_CASE, Title Case, Sentence case, upper, lower, strip accents, collapse whitespace, sort or dedupe lines, remove HTML tags. Price: $0.003 USDC per call (x402).","tags":["Data & text"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"text-transform","result":{"op":"slug","result":"hello-world-api-v2-and-more"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string","maxLength":524288},"op":{"type":"string","enum":["slug","camel","pascal","snake","kebab","constant","title","sentence","upper","lower","strip-accents","collapse-whitespace","sort-lines","dedupe-lines","strip-html"]}},"required":["text","op"]},"example":{"text":"Héllo Wörld: API v2 & More!","op":"slug"}}}}}},"/v1/hash":{"post":{"operationId":"hash","summary":"Hash text or bytes: SHA-1/2/3, Keccak-256, MD5, RIPEMD-160, BLAKE2/3","description":"Computes one or all of md5, sha1, sha224, sha256, sha384, sha512, sha3-256, sha3-512, keccak256, ripemd160, blake2b-256/512, blake2s-256, blake3. Input as UTF-8 text, hex, base64 or base58; output hex or base64. Up to 1 MB. Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"hash","result":{"bytes":5,"hashes":{"sha256":"2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824","keccak256":"1c8aff950685c2ed4bc3174f3472287b56d9517b9c948127319a09a7a36deac8"}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","maxLength":1048576},"inputEncoding":{"type":"string","enum":["utf8","hex","base64","base58"],"default":"utf8"},"algorithm":{"type":"string","enum":["all","md5","sha1","sha224","sha256","sha384","sha512","sha3-256","sha3-512","keccak256","ripemd160","blake2b-512","blake2b-256","blake2s-256","blake3"],"default":"sha256"},"outputEncoding":{"type":"string","enum":["hex","base64"],"default":"hex"}},"required":["data"]},"example":{"data":"hello","algorithm":"all"}}}}}},"/v1/hmac":{"post":{"operationId":"hmac","summary":"HMAC (SHA-256/384/512/1, MD5), e.g. to check a webhook signature","description":"Computes HMAC of a message with a key (text, hex or base64). Optionally compares against an expected signature in constant time and reports whether it matches. Keys are not stored or logged. Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"hmac","result":{"algorithm":"sha256","hex":"6f0c0b5b...","base64":"bwwLW...","matches":null}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","maxLength":1048576},"key":{"type":"string","maxLength":4096},"keyEncoding":{"type":"string","enum":["utf8","hex","base64"],"default":"utf8"},"algorithm":{"type":"string","enum":["sha1","sha256","sha384","sha512","md5"],"default":"sha256"},"expected":{"type":"string","maxLength":512,"description":"Optional signature to compare (hex or base64, optional \"sha256=\" prefix)"}},"required":["message","key"]},"example":{"message":"{\"event\":\"ping\"}","key":"whsec_test","algorithm":"sha256"}}}}}},"/v1/encode":{"post":{"operationId":"encode","summary":"Convert between UTF-8, hex, base64, base64url, base32, base58; URL and HTML escaping","description":"Re-encodes data from one encoding to another (utf8, hex, base64, base64url, base32, base58), or applies url-encode / url-decode / html-escape / html-unescape. Reports invalid UTF-8 instead of guessing. Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"encode","result":{"from":"utf8","to":"base58","result":"StV1DL6CwTryKyV","bytes":11}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"string","maxLength":1048576},"from":{"type":"string","enum":["utf8","hex","base64","base64url","base32","base58","url","html"],"default":"utf8"},"to":{"type":"string","enum":["utf8","hex","base64","base64url","base32","base58","url","html"],"default":"base64"}},"required":["data"]},"example":{"data":"hello world","from":"utf8","to":"base58"}}}}}},"/v1/uuid":{"get":{"operationId":"uuid","summary":"Generate UUIDs (v4 random, v7 time-ordered) or parse/validate one","description":"With no \"uuid\" parameter: generates up to 100 UUIDs of version 4 or 7 using a CSPRNG. With \"uuid\": validates it and returns the canonical form, version, variant and embedded timestamp (v1, v6, v7). Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"uuid","result":{"version":7,"uuids":["019a2a5e-7c1b-7f3e-9d2a-4b8c1e0f5a6d","019a2a5e-7c1b-7a10-8e55-0c9d2b7f1e33"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"uuid","in":"query","required":false,"description":"UUID to parse (optional)","schema":{"type":"string","maxLength":64,"description":"UUID to parse (optional)"}},{"name":"version","in":"query","required":false,"schema":{"type":"integer","enum":[4,7],"default":4},"example":7},{"name":"count","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":1},"example":2}]}},"/v1/jwt/decode":{"post":{"operationId":"jwt_decode","summary":"Decode a JWT and check its times; optionally verify an HS256/384/512 signature","description":"Decodes header and payload, converts exp/iat/nbf to ISO dates, reports whether the token is expired or not yet valid, and flags alg=none. If a shared secret is given, verifies HMAC signatures (HS256/384/512) in constant time. Secrets are not stored or logged. Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"jwt-decode","result":{"header":{"alg":"HS256","typ":"JWT"},"payload":{"sub":"1234567890","name":"John Doe","iat":1516239022},"times":{"iat":"2018-01-18T01:30:22.000Z"},"expired":false,"signatureVerified":true}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"token":{"type":"string","maxLength":16384},"secret":{"type":"string","maxLength":4096,"description":"Optional HMAC secret to verify the signature"},"secretEncoding":{"type":"string","enum":["utf8","base64","hex"],"default":"utf8"}},"required":["token"]},"example":{"token":"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c","secret":"your-256-bit-secret"}}}}}},"/v1/random":{"get":{"operationId":"random","summary":"Cryptographically secure random bytes, tokens and passwords","description":"Generates random bytes (hex/base64/base64url/base58), passwords with chosen character classes, or numeric PINs, from a CSPRNG. Reports the entropy in bits. Nothing is stored. Price: $0.003 USDC per call (x402).","tags":["Encode & hash"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"random","result":{"kind":"password","entropyBits":130.1,"values":["q7#Vt!pZ2m@Lx9$wR4kE"]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"kind","in":"query","required":false,"schema":{"type":"string","enum":["bytes","password","pin"],"default":"bytes"},"example":"password"},{"name":"length","in":"query","required":false,"description":"bytes for kind=bytes, characters otherwise","schema":{"type":"integer","minimum":1,"maximum":256,"default":32,"description":"bytes for kind=bytes, characters otherwise"},"example":20},{"name":"encoding","in":"query","required":false,"schema":{"type":"string","enum":["hex","base64","base64url","base58"],"default":"hex"}},{"name":"symbols","in":"query","required":false,"schema":{"type":"boolean","default":true}},{"name":"count","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":1}}]}},"/v1/convert/units":{"get":{"operationId":"unit_convert","summary":"Convert between units: length, mass, volume, area, speed, time, data, pressure, energy, power, temperature, angle","description":"Exact-factor conversion across 12 dimensions and 140+ units (SI, imperial, US customary, IEC binary data sizes). Temperature handles offsets (C, F, K, R). Pass to=all to get every unit of the same dimension. Price: $0.003 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"unit-convert","result":{"value":72,"from":"F","to":"C","result":22.2222222222,"dimension":"temperature"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"value","in":"query","required":true,"schema":{"type":"number"},"example":72},{"name":"from","in":"query","required":true,"schema":{"type":"string","maxLength":20},"example":"F"},{"name":"to","in":"query","required":true,"description":"Target unit, or \"all\"","schema":{"type":"string","maxLength":20,"description":"Target unit, or \"all\""},"example":"C"}]}},"/v1/time/convert":{"get":{"operationId":"time_convert","summary":"Convert a time between time zones and formats (ISO, unix, RFC 2822), with DST-aware offsets","description":"Parses ISO 8601, unix seconds/ms or \"now\" (a bare local time is read in the \"from\" zone) and returns it in UTC and in each target IANA zone with offsets, weekday, ISO week, day of year, unix seconds/ms and RFC 2822. Up to 20 target zones. Price: $0.003 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"time-convert","result":{"utc":"2026-03-29T07:30:00.000Z","unix":1774769400,"zones":[{"zone":"America/New_York","local":"2026-03-29T03:30:00-04:00","offset":"-04:00","weekday":"Sun"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"time","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"now"},"example":"2026-03-29 09:30"},{"name":"from","in":"query","required":false,"description":"IANA zone used to read a time without an offset","schema":{"type":"string","maxLength":64,"default":"UTC","description":"IANA zone used to read a time without an offset"},"example":"Europe/Berlin"},{"name":"to","in":"query","required":false,"description":"IANA zone(s), comma separated","schema":{"type":"string","maxItems":20,"maxLength":1500,"description":"IANA zone(s), comma separated"},"example":"America/New_York,Asia/Kolkata"}]}},"/v1/time/diff":{"get":{"operationId":"time_diff","summary":"Duration between two dates/times, calendar difference and business days","description":"Exact duration (seconds, minutes, hours, days), calendar difference in years/months/days, and the number of weekdays (Mon-Fri) between two dates, evaluated in a chosen time zone. Optionally adds a duration to a date. Price: $0.003 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"time-diff","result":{"seconds":24019200,"days":278,"calendar":{"years":0,"months":9,"days":12},"businessDays":198,"human":"9 months, 12 days"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"2026-01-15"},{"name":"end","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"now"},"example":"2026-10-27"},{"name":"tz","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"UTC"},"example":"UTC"}]}},"/v1/cron/next":{"get":{"operationId":"cron_next","summary":"Explain a cron expression and list its next run times in any time zone","description":"Parses a 5-field cron expression (lists, ranges, steps, month/day names, @daily/@hourly/... macros, Vixie day-of-month OR day-of-week rule) and returns the next N run times (up to 50) in UTC and in the given IANA zone, DST-aware. Price: $0.003 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"cron-next","result":{"expression":"30 9 * * mon-fri","next":[{"utc":"2026-10-27T13:30:00.000Z","local":"2026-10-27T09:30:00-04:00"}]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"expression","in":"query","required":true,"schema":{"type":"string","maxLength":120},"example":"30 9 * * mon-fri"},{"name":"tz","in":"query","required":false,"schema":{"type":"string","maxLength":64,"default":"UTC"},"example":"America/New_York"},{"name":"count","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":50,"default":5},"example":3},{"name":"from","in":"query","required":false,"description":"Start time (default now)","schema":{"type":"string","maxLength":64,"description":"Start time (default now)"}}]}},"/v1/color":{"get":{"operationId":"color","summary":"Colour conversion (hex, RGB, HSL) and WCAG contrast ratio between two colours","description":"Parses hex, rgb(), hsl() or CSS names and returns hex, RGB, HSL and relative luminance. With a second colour, returns the WCAG 2.x contrast ratio and AA / AAA pass/fail for normal and large text. Price: $0.003 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"color","result":{"hex":"#1e90ff","rgb":{"r":30,"g":144,"b":255},"hsl":{"h":209.6,"s":100,"l":55.9},"contrast":{"ratio":3.24,"AA":false,"AALarge":true,"AAA":false}}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"color","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"#1e90ff"},{"name":"against","in":"query","required":false,"description":"Optional second colour for a contrast check","schema":{"type":"string","maxLength":64,"description":"Optional second colour for a contrast check"},"example":"white"}]}},"/v1/convert/currency":{"get":{"operationId":"currency_convert","summary":"Currency conversion with official ECB euro reference rates (30 fiat currencies)","description":"Converts an amount between USD, EUR, GBP, JPY, CHF, CNY, INR, BRL, CAD, AUD and the other currencies the European Central Bank publishes daily (cross rates via EUR). Returns the rate, its date and source. Reference rates, not trading quotes. Price: $0.005 USDC per call (x402).","tags":["Convert"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.005"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"currency-convert","result":{"amount":100,"from":"USD","date":"2026-10-26","results":{"EUR":89.381,"INR":8418.31},"source":"European Central Bank euro reference rates"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"amount","in":"query","required":false,"schema":{"type":"number","default":1},"example":100},{"name":"from","in":"query","required":true,"schema":{"type":"string","pattern":"^[A-Za-z]{3}$"},"example":"USD"},{"name":"to","in":"query","required":true,"description":"Currency code(s), comma separated, or \"all\"","schema":{"type":"string","maxLength":200,"description":"Currency code(s), comma separated, or \"all\""},"example":"EUR,INR"}]}},"/v1/semver":{"get":{"operationId":"semver","summary":"Semantic versions: parse, compare, sort, and check against npm-style ranges","description":"Parses SemVer 2.0 versions; compares two (a vs b); sorts a list (invalid ones reported); checks versions against npm range syntax (^, ~, x-ranges, hyphen ranges, comparators, ||) with correct prerelease rules; returns the highest version satisfying the range. Price: $0.003 USDC per call (x402).","tags":["Validate & parse"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"semver","result":{"sorted":["1.2.3","1.2.10","1.10.0","2.0.0-rc.1"],"range":"^1.2.0","satisfying":["1.2.3","1.2.10","1.10.0"],"maxSatisfying":"1.10.0","invalid":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"versions","in":"query","required":true,"description":"One or more versions, comma separated","schema":{"type":"string","maxItems":1000,"maxLength":50000,"description":"One or more versions, comma separated"},"example":"1.2.3,1.10.0,2.0.0-rc.1,1.2.10"},{"name":"range","in":"query","required":false,"description":"Optional npm-style range, e.g. ^1.2.0 || >=2.1 <3","schema":{"type":"string","maxLength":500,"description":"Optional npm-style range, e.g. ^1.2.0 || >=2.1 <3"},"example":"^1.2.0"},{"name":"compareTo","in":"query","required":false,"schema":{"type":"string","maxLength":128}}]}},"/v1/iban/validate":{"get":{"operationId":"iban_validate","summary":"Validate an IBAN: country length, mod-97 check digits, formatted output","description":"Validates International Bank Account Numbers for 80+ countries: structure, country-specific length and the ISO 13616 mod-97 checksum. Returns the normalized and print-formatted IBAN, BBAN and (for DE/GB) the bank code / sort code. Offline; nothing is stored. Price: $0.003 USDC per call (x402).","tags":["Validate & parse"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"iban-validate","result":{"valid":true,"normalized":"GB82WEST12345698765432","country":"GB","formatted":"GB82 WEST 1234 5698 7654 32","sortCode":"12-34-56","issues":[]}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"iban","in":"query","required":true,"schema":{"type":"string","maxLength":64},"example":"GB82 WEST 1234 5698 7654 32"}]}},"/v1/user-agent":{"get":{"operationId":"user_agent","summary":"Parse a User-Agent: browser, engine, OS, device type, and known bots / AI crawlers","description":"Identifies browser and version, rendering engine, OS and version, device class (desktop, mobile, tablet, tv) and 35+ known bots: search engines, AI crawlers (GPTBot, ClaudeBot, PerplexityBot, CCBot, ...), social preview fetchers, SEO tools, monitors and HTTP libraries. Price: $0.003 USDC per call (x402).","tags":["Validate & parse"],"security":[],"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.003"},"protocols":[{"x402":{}}]},"responses":{"200":{"description":"Result. Envelope {ok, tool, result, payment}.","content":{"application/json":{"schema":{"type":"object","properties":{"ok":{"type":"boolean"},"tool":{"type":"string"},"result":{"type":"object"},"payment":{"type":"object"}}},"example":{"ok":true,"tool":"user-agent","result":{"isBot":true,"bot":"GPTBot","botCategory":"ai-crawler","browser":null,"os":null,"device":"bot"}}}}},"400":{"description":"Invalid input (not charged)."},"402":{"description":"Payment Required: x402 v2 challenge in the PAYMENT-REQUIRED header and the JSON body."}},"parameters":[{"name":"ua","in":"query","required":true,"schema":{"type":"string","maxLength":2000},"example":"Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; GPTBot/1.2; +https://openai.com/gptbot)"}]}},"/mcp":{"post":{"operationId":"mcp","summary":"MCP server (streamable HTTP, stateless). tools/list is free; tools/call is paid per call via x402 in _meta.","security":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object"}}}},"responses":{"200":{"description":"JSON-RPC response"}}}},"/health":{"get":{"operationId":"health","summary":"Liveness and configuration (free)","security":[],"responses":{"200":{"description":"ok"}}}}}}