{"uid":"cap_w66H9nR9IaC8uk6fNZ2B3","slug":"pdf-extract-api-text-translator-b3a3a195","name":"PDF Extract API - Text Translator","description":"Translate text into a target language, with source language auto-detection.","url":"https://translator.pdfextractapi.workers.dev/translate","method":"POST","headers":{},"bodySchema":{"type":"object","$schema":"https://json-schema.org/draft/2020-12/schema","required":["input"],"properties":{"input":{"type":"object","required":["type","method","bodyType","body"],"properties":{"body":{"required":["text","target_language"],"properties":{"text":{"type":"string","description":"The text to translate, max 20,000 characters."},"target_language":{"type":"string","description":"Target language, as a name or ISO 639-1 code, e.g. 'es' or 'Spanish'."}}},"type":{"type":"string","const":"http"},"method":{"enum":["POST"],"type":"string"},"bodyType":{"enum":["json","form-data","text"],"type":"string"}},"additionalProperties":false},"output":{"type":"object","required":["type"],"properties":{"type":{"type":"string"},"example":{"type":"object"}}}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.02","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"registry","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.02/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.02","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_RKXitp2qIsxSNP7LZ8PZT","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.02","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Translates text into a target language with automatic source language detection, supporting language names or ISO 639-1 codes.","exampleAgentPrompt":"Translate this text into Spanish: 'Welcome to our platform. We're glad you're here and hope you enjoy the experience.'","exampleUseCases":[{"title":"Localize product descriptions for e-commerce","prompt":"I need to translate this product description into Japanese for our new Tokyo storefront: 'Our lightweight titanium water bottle keeps drinks cold for 24 hours and hot for 12 hours.'"},{"title":"Translate customer support message","prompt":"Can you translate this customer message into English so I can understand what they're asking? The text is: 'J'ai un problème avec ma commande, elle n'est pas arrivée depuis deux semaines.'"},{"title":"Multilingual marketing campaign copy","prompt":"Take this tagline and translate it into German: 'Innovation meets simplicity — designed for the way you live.'"}],"resultDescription":"The agent receives a translated version of the submitted text in the specified target language. The source language is auto-detected, so no prior knowledge of the input language is required. The response includes the translated text ready for use.","failureModes":["Text exceeds 20,000 character limit — request rejected","Unsupported or unrecognized target language code — translation fails","Empty or missing 'text' field — validation error","Empty or missing 'target_language' field — validation error","Ambiguous or very short input text causing incorrect language auto-detection","Payment not processed (x402 protocol failure) — 402 error returned"],"whenToPreferThis":"Choose this endpoint when you need fast, pay-per-call text translation without setting up a recurring API subscription. It is ideal for agents that occasionally need to translate user-supplied text of up to 20,000 characters into a known target language, especially when the source language is unknown and auto-detection is needed. It suits lightweight localization tasks, one-off translations, and multilingual pipelines that need simple JSON-based input.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T18:37:16.008Z","isFirstParty":false}