# Inference402 Text Classifier

> Inference402 Text Classifier is a paid API for AI agents from inference402.worlddata402.workers.dev, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-19).

Classifies input text into one of the provided candidate labels using Llama 3.3 70B, returning the best-matching label and a confidence score, paid per-call in USDC on Base.

## Facts

- Endpoint: GET https://inference402.worlddata402.workers.dev/v1/classify?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-19
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/inference402-text-classifier-a4c66337
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_FOo6HGB2GkR2M0HflyiEl

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 inference402-text-classifier-a4c66337
```

Example prompt: Classify this support message into one of these categories — billing, technical, account, or general — and tell me how confident you are: 'My invoice shows a double charge from last month and I need a refund.'

## When to prefer this

Choose this endpoint when you need zero-setup, pay-per-call text classification without managing API keys or accounts. Ideal for agent pipelines that need to route or triage text into known categories on-demand. Best when you have 2–20 well-defined labels and short-to-medium text inputs. Prefer over full LLM chat endpoints when you only need a label and confidence score rather than free-form text output.

## Known failure modes

- Fewer than 2 labels provided — minimum of 2 labels required
- Text exceeds 8000 characters — request will be rejected
- More than 20 labels provided — exceeds maxItems limit
- Payment not provided or insufficient USDC — 402 Payment Required returned
- Model unavailable or Cloudflare Workers AI outage — 5xx error

## How this service works

Pay-per-call AI inference for agents: chat (Llama 3.3 70B / 3.1 8B), structured JSON, summarize, translate (incl. Egyptian Arabic), extract, classify, sentiment, keywords, rewrite, embeddings, moderation, vision and speech-to-text. USDC on Base mainnet over x402. No API key, no account.

## Output

Returns a JSON object with the best-matching label from the provided candidate list, a confidence score between 0 and 1 indicating certainty, and the model identifier used (e.g. @cf/meta/llama-3.3-70b-instruct-fp8-fast). No authentication required; payment is made per-call in USDC on Base via x402.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "maxLength": 8000
  },
  "labels": {
   "type": "array",
   "items": {
    "type": "string",
    "maxLength": 64
   },
   "maxItems": 20,
   "minItems": 2
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "label": "billing",
  "model": "@cf/meta/llama-3.3-70b-instruct-fp8-fast",
  "confidence": 0.94
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/inference402-text-classifier-a4c66337/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from inference402.worlddata402.workers.dev](https://www.zero.xyz/host/inference402.worlddata402.workers.dev/llms.txt)
