{"uid":"cap_eQ4cUnBwozJYouahUs7wB","slug":"x402-deployer-x402-deployer-workers-dev-ef084899","name":"Language Detector / Language Identification API","description":"Language detector / language identification. ISO 639-1 code, full name, confidence (0-1). Mixed-language detection with secondary languages list. 100+ languages.","url":"https://x402-deployer.x402-deployer.workers.dev/detect-language","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"],"properties":{"text":{"type":"string","description":"Text to detect the language of. Only the first 2000 chars are sent to the model; max 10000 chars total."}}},"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","properties":{"confidence":{"type":"number"},"language_code":{"type":"string"},"language_name":{"type":"string"}}}}}}},"responseSchema":null,"example":{"request":{"input":{"body":{"text":"Hello world, this is a test of the language detection API."},"type":"http","method":"POST","bodyType":"json"}},"response":{"model":"hermes-3-llama-3.1-405b","source":"morpheus","is_mixed":false,"confidence":0.95,"input_chars":58,"language_code":"en","language_name":"English","secondary_languages":[]}},"exampleRequest":{"text":"Hello world, this is a test of the language detection API."},"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"settled","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.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_sTsZznMJK3nsSB7gGi5Cu","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":null,"unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Detects the language of input text, returning ISO 639-1 code, full language name, confidence score, and secondary languages for mixed-language content.","exampleAgentPrompt":"What language is this text written in, and how confident are you? 'Bonjour, je m'appelle Marie et j'habite à Paris.' — I need the ISO 639-1 code, full language name, and confidence score, plus any secondary languages if it's mixed.","exampleUseCases":null,"resultDescription":"Returns the detected primary language as an ISO 639-1 code (e.g. 'fr') and full name (e.g. 'French'), a confidence score between 0 and 1, and a list of secondary languages if the text contains mixed-language content. Supports 100+ languages.","failureModes":["Empty or very short text may yield low confidence or ambiguous results","Highly transliterated or code-switched text may misidentify the primary language","Extremely rare languages may not be detected correctly or may fall back to a closest match","Non-textual input or binary content will likely return an error or near-zero confidence"],"whenToPreferThis":"Use this endpoint when you need programmatic language identification with a confidence score and ISO 639-1 codes, especially for multilingual or mixed-language text. Ideal for routing user messages by language, pre-processing text before translation, or filtering content by language in pipelines.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-14T00:40:34.928Z","isFirstParty":false}