# PrimeAPI Text Language Detection

> PrimeAPI Text Language Detection is a paid API for AI agents from prime-api-seven.vercel.app, paid per call via x402, $0.178905/call, status unknown (last checked 2026-09-15).

Detects the language of a given text input and returns the identified language.

## Facts

- Endpoint: POST https://prime-api-seven.vercel.app/api/tools/text/language
- Price: $0.178905/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/primeapi-text-language-detection-bea375da
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_vmLPjeUTXcaJetQjlwWZl

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability primeapi-text-language-detection-bea375da -d '<json body>'
```

Example prompt: What language is this text written in: 'Bonjour, comment puis-je vous aider aujourd'hui?'

## When to prefer this

Use this endpoint when you need to programmatically detect the language of arbitrary text without maintaining your own NLP stack, especially in a pay-per-call context where you want no API key overhead and can pay in USDC on Base.

## Known failure modes

- Empty or missing query string returns an error
- Very short or ambiguous text may yield low-confidence or incorrect detection
- Non-textual input (numbers only, symbols) may fail to identify a language
- Payment failure in USDC returns 402 Payment Required
- Rate limiting or server errors return 5xx responses

## How this service works

Crypto, AI, Social Media, Finance, Weather, Tools &amp; more. Pay per call in USDC on Base. No API keys.

## Output

Returns an object indicating the detected language of the submitted text, likely including a language name or BCP-47 language code and possibly a confidence score.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "query": {
   "type": "string",
   "description": "Search query or input parameter"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "description": "API response data"
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/primeapi-text-language-detection-bea375da/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from prime-api-seven.vercel.app](https://www.zero.xyz/host/prime-api-seven.vercel.app/llms.txt)
