{"uid":"cap_hsfLxpvev6E4F5e4IP8Fh","slug":"agenttools-base64-encode-decode-ff59c9e4","name":"AgentTools Base64 Encode/Decode","description":"Encode text to base64 or decode base64 back to text. Full UTF-8 support including emoji and non-Latin scripts. Use this when an agent needs to uTF-8 safe base64 in both directions.","url":"https://agenttools-hub.vercel.app/api/v1/dev/base64-encode?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method"],"properties":{"type":{"type":"string","const":"http"},"method":{"enum":["GET"],"type":"string"},"queryParams":{"type":"object","required":["text"],"properties":{"text":{"type":"string","description":"Text"},"direction":{"enum":["encode","decode"],"type":"string","description":"Direction"}}}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":null,"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_zXNbwk5QUbUQCZ_WXN2z4","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":"Encodes plain text to base64 or decodes base64 strings back to text, with full UTF-8 support including emoji and non-Latin scripts.","exampleAgentPrompt":"Can you base64 encode this text for me: 'Hello, 世界! 🌍' — use the encode direction.","exampleUseCases":[{"title":"Encode API credentials for auth header","prompt":"I need to base64 encode my API key and secret 'mykey:mysecret' so I can put it in a Basic Auth header — can you encode that string for me?"},{"title":"Decode a base64 payload from an API response","prompt":"I got this base64 string back from an API — 'SGVsbG8gV29ybGQh' — can you decode it so I can read what it actually says?"},{"title":"Encode Unicode content for safe transmission","prompt":"Can you base64 encode this Japanese text so I can safely embed it in a JSON field: 'こんにちは世界'?"}],"resultDescription":"Returns the transformed string — either the base64-encoded representation of the input text, or the original UTF-8 decoded text from a base64 input. The response includes the output string with full support for emoji and non-Latin characters.","failureModes":["Invalid base64 string passed when direction is 'decode' — may return error or garbled output","Missing required 'text' query parameter — returns validation error","Invalid 'direction' enum value (not 'encode' or 'decode') — returns 400 error","Non-UTF-8 compatible binary data may not decode cleanly to readable text"],"whenToPreferThis":"Choose this endpoint when you need a quick, reliable base64 encode or decode with explicit direction control and confirmed UTF-8/emoji support. Prefer it over rolling your own when operating in an agent context that needs a deterministic, hosted utility, or when encoding non-Latin scripts and emoji that may trip up naive implementations.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-02T18:31:11.394Z","isFirstParty":false,"canonicalSlug":"agenttools-base64-encode-decode-ff59c9e4"}