# SQL Query Explainer

> SQL Query Explainer is a paid API for AI agents from linked-aimed-reproduced-changing.trycloudflare.com, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-10).

Takes a raw SQL query and returns a plain-English explanation of what it does

## Facts

- Endpoint: POST https://linked-aimed-reproduced-changing.trycloudflare.com/v1/sql-explain?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-10
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sql-query-explainer-52174a60
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_QX3sJKNH9TJGDDuDR2qos

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 sql-query-explainer-52174a60 -d '<json body>'
```

Example prompt: Can you explain what this SQL query does in plain English? SELECT u.name, COUNT(o.id) AS order_count FROM users u LEFT JOIN orders o ON u.id = o.user_id WHERE u.created_at > '2024-01-01' GROUP BY u.name HAVING COUNT(o.id) > 5 ORDER BY order_count DESC;

## When to prefer this

Choose this endpoint when you need a fast, affordable natural-language explanation of a SQL query — especially useful for developers onboarding to a new codebase, non-technical users trying to understand reports, or code reviewers auditing database logic. At $0.01 per call it is cost-effective for high-volume developer tooling pipelines.

## Known failure modes

- Malformed or incomplete SQL may produce a confused or inaccurate explanation
- Very large or deeply nested queries may be truncated or only partially explained
- Dialect-specific SQL (e.g. T-SQL, PL/pgSQL) may not be fully understood
- Empty or missing message body returns an error
- Network timeouts may occur if the underlying Cloudflare Tunnel is unavailable

## How this service works

Explain a SQL query in plain English. Paste query in message.

## Output

A plain-English narrative explanation of the SQL query's logic, describing what tables are involved, what filters or joins are applied, what data is returned or modified, and the overall intent of the query.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "usage": {
   "type": "object"
  },
  "choices": {
   "type": "array"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sql-query-explainer-52174a60/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from linked-aimed-reproduced-changing.trycloudflare.com](https://www.zero.xyz/host/linked-aimed-reproduced-changing.trycloudflare.com/llms.txt)
