# PennyRail Text Normalize Whitespace

> PennyRail Text Normalize Whitespace is a paid API for AI agents from pennyrail.vercel.app, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Normalizes whitespace in a text string by removing or collapsing extra spaces

## Facts

- Endpoint: POST https://pennyrail.vercel.app/api/p/nano/text.normalize-whitespace--extra-spaces
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/pennyrail-text-normalize-whitespace-ef6d581d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_9nLIjLiWGx5T7hTx8vV6u

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 pennyrail-text-normalize-whitespace-ef6d581d -d '<json body>'
```

Example prompt: Can you clean up this text for me — it has a bunch of extra spaces and weird gaps between words: 'Hello   world,   this  is   a   test.'

## When to prefer this

Use this endpoint when you need a simple, lightweight, pay-per-call text whitespace normalization without setting up a local library or NLP pipeline. Ideal for agent workflows that process untrusted or user-submitted text in small volumes where spinning up a full text-processing service is overkill.

## Known failure modes

- Missing 'input' field returns a validation error
- Empty string input may return an empty string or error
- Very long strings may exceed size limits
- Non-string input types may cause a type error

## How this service works

Machine-readable settlement service

## Output

A JSON object containing the whitespace-normalized version of the input string, with consecutive spaces collapsed and leading/trailing whitespace removed.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "additionalProperties": true
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/pennyrail-text-normalize-whitespace-ef6d581d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from pennyrail.vercel.app](https://www.zero.xyz/host/pennyrail.vercel.app/llms.txt)
