# Forest Agent Tools – SHA-256 / SHA-512 Text Hasher

> Forest Agent Tools – SHA-256 / SHA-512 Text Hasher is a paid API for AI agents from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-20).

Deterministically hash up to 100 KiB of UTF-8 text with SHA-256 or SHA-512, returning both hexadecimal and Base64 digests with no external network calls.

## Facts

- Endpoint: POST https://http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/text/hash?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-20
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forest-agent-tools-sha-256-sha-512-text-hasher-8dd91269
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_cdvwONcgl9gg7MeRucmve

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 forest-agent-tools-sha-256-sha-512-text-hasher-8dd91269 -d '<json body>'
```

Example prompt: Hash the text 'hello world, this is my canonical key' using SHA-256 and give me both the hex and Base64 digests.

## When to prefer this

Choose this endpoint when you need a deterministic, side-effect-free hash of text data (up to 100 KiB) without trusting a third-party cryptographic service or running local code. Ideal for agents that need reproducible content fingerprints, checksums, or stable IDs from text values in a sandboxed environment. Prefer SHA-512 when collision resistance is paramount; SHA-256 for compact digests. Not suitable for password hashing (no salt/stretching) or HMAC operations.

## Known failure modes

- Text exceeds 100 KiB limit — request rejected with a 4xx error
- Invalid algorithm value (not 'sha256' or 'sha512') — validation error returned
- Missing required 'text' or 'algorithm' fields — schema validation error
- Payment not attached or insufficient USDC — 402 Payment Required
- Non-UTF-8 byte sequences in input — encoding error

## How this service works

Machine-readable contract for active Forest paid capabilities. Unsigned paid calls return HTTP 402 with a PAYMENT-REQUIRED x402 challenge.

## Output

Returns a JSON object containing the hex-encoded digest, the Base64-encoded digest, and the algorithm name used, computed locally without any external network calls.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string",
   "maxLength": 102400,
   "description": "Public text value used to scope this lookup."
  },
  "algorithm": {
   "enum": [
    "sha256",
    "sha512"
   ],
   "type": "string",
   "description": "Public algorithm value used to scope this lookup."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "scope": "caller_supplied_text_hash_only",
   "algorithm": "sha256",
   "digest_hex": "example",
   "byte_length": 0,
   "digest_base64": "example",
   "input_encoding": "utf-8"
  },
  "meta": {
   "cache": "miss",
   "provider": "node-crypto",
   "checked_at": "2026-01-01T00:00:00.000Z",
   "duration_ms": 0
  },
  "version": "1",
  "capability": "text.hash"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forest-agent-tools-sha-256-sha-512-text-hasher-8dd91269/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run](https://www.zero.xyz/host/http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/llms.txt)
