# Delx Commerce JSON Escape

> Delx Commerce JSON Escape is a paid API for AI agents from commerce.delx.ai, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-01).

Escapes special characters in a string to produce valid JSON-safe text

## Facts

- Endpoint: POST https://commerce.delx.ai/api/v1/x402/json-escape?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-01
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/delx-commerce-json-escape-23f38b32
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_VFawVU0n-WREaqh-6hKBI

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 delx-commerce-json-escape-23f38b32 -d '<json body>'
```

Example prompt: Can you JSON-escape this string for me so I can safely embed it in a JSON payload: 'say "hello"
line2'?

## When to prefer this

Choose this endpoint when an AI agent needs a reliable, pay-per-use utility to JSON-escape arbitrary strings without setting up a server-side library — especially useful in agent pipelines that process untrusted or dynamic text that must be embedded in JSON payloads, and where a simple hosted microservice is preferable to implementing escape logic inline.

## Known failure modes

- Empty or missing 'text' field returns an error
- Extremely large input strings may be rejected or time out
- Payment failure via x402 protocol results in 402 response before processing
- Malformed request body returns 400-level error

## How this service works

Pay-per-result APIs for agents. No signup. Exact price. Verifiable delivery. USDC on Base + Solana via x402.

## Output

Returns a JSON object containing the escaped version of the input text (with quotes, newlines, backslashes, and other special characters properly escaped) along with the schema identifier 'delx/util-json-escape/v1'.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "description": "Input field: text."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "text": "say \\\"hello\\\"\\nline2",
  "schema": "delx/util-json-escape/v1"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/delx-commerce-json-escape-23f38b32/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from commerce.delx.ai](https://www.zero.xyz/host/commerce.delx.ai/llms.txt)
