# PennyRail Text Character Count / Length

> PennyRail Text Character Count / Length 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).

Counts the number of characters in a given text string and returns the character count and/or length

## Facts

- Endpoint: POST https://pennyrail.vercel.app/api/p/nano/text.char-count--text-length
- 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-character-count-length-a3cef19e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_RHwfY33vc8m2jQHdKM_2K

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-character-count-length-a3cef19e -d '<json body>'
```

Example prompt: How many characters are in this text: 'The quick brown fox jumps over the lazy dog'?

## When to prefer this

Use this endpoint when you need a quick, pay-per-call character count or string length computation without standing up your own infrastructure. Ideal for AI agents that need to validate text length constraints, check character limits for social media or SMS, or compute string metrics on demand without a dedicated NLP service.

## Known failure modes

- Missing 'input' field in request body returns a validation error
- Empty string input may return 0 or an error depending on implementation
- Very large strings may hit payload size limits
- Non-string input types may cause schema validation failure
- Payment failure via x402 protocol results in 402 Payment Required before processing

## How this service works

Machine-readable settlement service

## Output

Returns a JSON object containing the character count and/or length of the submitted text string as a numeric value, indicating how many characters are present in the input.

## 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-character-count-length-a3cef19e/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)
