# Arabic Language Detection

> Arabic Language Detection is a paid API for AI agents from arabic-pipeline.arabic-pipeline.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-31).

Detects whether text is Arabic and reports language confidence and script mix breakdown

## Facts

- Endpoint: POST https://arabic-pipeline.arabic-pipeline.workers.dev/text/detect?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-31
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/arabic-language-detection-bf08e807
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_eepEZdM1zgRIqc17Sd1T4

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 arabic-language-detection-bf08e807 -d '<json body>'
```

Example prompt: Can you check whether this text is written in Arabic and tell me how confident you are: 'مرحباً بالعالم'?

## When to prefer this

Choose this endpoint when you need a fast, cheap per-call Arabic language detection with script-level detail (arabic vs latin vs other character counts) and no account or API key setup. Prefer it over general-purpose language detection APIs when Arabic-specific accuracy and micropayment economics (pay-per-call in USDC) suit your workflow.

## Known failure modes

- Empty or whitespace-only text may return low confidence or ambiguous results
- Very short strings (1-2 characters) may produce unreliable confidence scores
- Text that is purely numeric or punctuation may not detect Arabic
- Payment challenge (HTTP 402) returned on first call if client has not yet paid via x402

## How this service works

Nine micro-capabilities for Arabic-language work, sold per call over x402 in USDC on Base. No API key, no account, no subscription for the buyer: the first request returns a 402 payment challenge, the client pays it and retries. Text utilities are pure computation and cost nothing to serve.

## Output

Returns a JSON object with the detected language code (e.g. 'ar'), a confidence score between 0 and 1, and a script_mix object showing character counts for arabic, latin, and other scripts, plus the endpoint name and cost in USD.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "description": "The text to measure."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "cost_usd": 0.002,
  "endpoint": "POST /text/detect",
  "language": "ar",
  "confidence": 1,
  "script_mix": {
   "latin": 0,
   "other": 0,
   "arabic": 12
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/arabic-language-detection-bf08e807/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from arabic-pipeline.arabic-pipeline.workers.dev](https://www.zero.xyz/host/arabic-pipeline.arabic-pipeline.workers.dev/llms.txt)
