{"uid":"cap_IzSn6WK8td8wF5GuNSoJw","slug":"sitecheck-encode-decode-82a8e04c","name":"SiteCheck Encode/Decode","description":"Encode or decode text as base64, base64url, hex, URL (percent) encoding, HTML entities, punycode (domain names) or quoted-printable. Body { input, scheme, direction }, up to 1 MB. Invalid input to decode is a 400 that names the position of the first bad character. Unknown HTML entities are reported, not guessed. Pure code, no outside request.","url":"https://api.sitecheck-api.workers.dev/api/encode?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"input":{"type":"string","description":"The text to encode or decode (JSON body field)"},"scheme":{"type":"string","description":"base64, base64url, hex, url, html, punycode or quoted-printable"},"direction":{"type":"string","description":"encode (default) or decode"}}},"responseSchema":{"type":"json","example":{"output":"xn--bcher-kva.de","scheme":"punycode","source":"Computed here (pure code)","checkedAt":"2026-10-15T14:07:52.199Z","direction":"encode"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.002","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.002/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.002","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_r6kmPtlAhy8Yp6crlgJMQ","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.002","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Encodes or decodes a string using a specified scheme such as base64, hex, URL, HTML, punycode, or quoted-printable","exampleAgentPrompt":"Can you encode the string 'Hello World & Co.' to HTML encoding using SiteCheck's encode endpoint?","exampleUseCases":[{"title":"Punycode domain name conversion","prompt":"Convert the domain name 'bücher.de' to its punycode representation so I can use it in a DNS lookup."},{"title":"Base64 encode a payload","prompt":"Encode the text 'user:password123' to base64 so I can use it in an Authorization header."},{"title":"Decode a URL-encoded query string","prompt":"Decode this URL-encoded string '%48%65%6C%6C%6F%20%57%6F%72%6C%64' back to plain text."}],"resultDescription":"Returns a JSON object containing the transformed output string, the scheme used, the direction (encode or decode), a source note indicating the computation method, and a checkedAt timestamp.","failureModes":["Unsupported scheme value returns an error","Missing 'input' field results in a validation error","Invalid direction value (not 'encode' or 'decode') may return an error","Malformed input for a given scheme (e.g. invalid base64 when decoding) may return an error or garbled output"],"whenToPreferThis":"Use this endpoint when you need a lightweight, pay-per-call encoding or decoding operation without setting up a local library, especially for schemes like punycode (internationalized domain names), quoted-printable (email), or any of the supported formats in a serverless agent workflow.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-11-04T00:46:27.600Z","isFirstParty":false,"canonicalSlug":"sitecheck-encode-decode-82a8e04c"}