# SableForge Text Analysis API

> SableForge Text Analysis API is a paid API for AI agents from sableforge.servehttp.com, paid per call via x402, $0.0005/call, status unknown (last checked 2026-10-12).

Analyzes a text string and returns byte count, character count, line count, and word count statistics.

## Facts

- Endpoint: GET https://sableforge.servehttp.com/api/text?utm_source=zero.xyz
- Price: $0.0005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/sableforge-text-analysis-api-731c886b
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_ciVsHjeN9JxeZ7WCCDjfp

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 sableforge-text-analysis-api-731c886b
```

Example prompt: Can you count the words, characters, bytes, and lines in the following text: 'Hello world, this is a test sentence for analysis'?

## When to prefer this

Choose this endpoint when you need a lightweight, pay-per-call text statistics computation with no account setup, especially in autonomous agent workflows already using x402/USDC micropayments on Base. Ideal for quick one-off word/char/byte/line counts without provisioning a full NLP service or managing API keys.

## Known failure modes

- Missing 'text' query parameter returns an error or empty/zero metrics
- Very large text strings may hit URL length limits for GET requests
- Non-UTF8 or binary text may produce unexpected byte vs char discrepancies
- Payment failure via x402 (insufficient USDC balance) results in HTTP 402 with no analysis performed
- Service unavailable if the self-hosted server at servehttp.com is offline

## How this service works

12 pay-per-call HTTP APIs settled in USDC on Base via x402 v2. No API keys, no accounts, no signup — $0.0005–$0.0020 per call. Includes a locally hosted 27B LLM endpoint.

## Output

Returns a JSON object with four numeric fields: bytes (byte size of the input text), chars (character count), lines (number of newline-delimited lines), and words (number of whitespace-separated words).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {
      "text": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "bytes": 11,
  "chars": 11,
  "lines": 1,
  "words": 2
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/sableforge-text-analysis-api-731c886b/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from sableforge.servehttp.com](https://www.zero.xyz/host/sableforge.servehttp.com/llms.txt)
