{"uid":"cap_-7r_c35MBvkKnrJlAnyYh","slug":"decode-base64-base64url-to-bytes-and-text-c111a022","name":"Decode Base64 / Base64URL to Bytes and Text","description":"Decode base64 or base64url to bytes and text — Genesis402 / UnyKorn Operator Network","url":"https://twin.unykorn.org/decode-base64?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"params":{"type":"object","properties":{"data":{"type":"string"}}}}},"responseSchema":{"type":"json","example":{"ok":true,"type":"decode-base64","receipt":{"tx_hash":"0x<64hex>","amount_usd":0.001,"receipt_id":"g402-<16hex>"},"generated_at":"<iso8601>"}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","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.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_977AKhw3OYXFNYQouhLAT","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Decodes a base64 or base64url-encoded string into its raw bytes and human-readable text representation","exampleAgentPrompt":"Can you decode this base64 string for me and tell me what it says: 'SGVsbG8sIFdvcmxkIQ=='?","exampleUseCases":[{"title":"Decode JWT payload segment","prompt":"I have the payload segment of a JWT token — it's base64url encoded: 'eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ' — can you decode it so I can read the claims inside?"},{"title":"Inspect encoded API response","prompt":"This API returned a base64 blob that I need to read: 'dGhpcyBpcyBhIHNlY3JldCBtZXNzYWdl' — decode it for me so I can see the underlying text."},{"title":"Decode embedded configuration data","prompt":"There's a base64url string in this config file I'm debugging — 'dXNlcjphZG1pbjpwYXNzd29yZA==' — what does it actually say when decoded?"}],"resultDescription":"Returns a JSON object with ok=true, the decoded bytes and text representation of the input, the transformation type identifier ('decode-base64'), and a payment receipt containing the blockchain transaction hash, USD cost, and a unique receipt ID for the x402 micropayment.","failureModes":["Invalid base64 characters in input string cause decoding failure","Malformed or incomplete base64 padding may return an error","Empty or missing 'data' parameter returns a validation error","Payment failure via x402 protocol prevents execution and returns 402 status","Network timeout on the UnyKorn relay"],"whenToPreferThis":"Choose this endpoint when you need a pay-per-call, trustless base64/base64url decoding utility within an x402 micropayment workflow — particularly useful for AI agents operating autonomously that need on-demand encoding utilities without managing API keys, and when an auditable on-chain payment receipt per operation is desirable.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-01T18:55:42.093Z","isFirstParty":false,"canonicalSlug":"decode-base64-base64url-to-bytes-and-text-c111a022"}