# agent402.tools Cryptographic Hash

> agent402.tools Cryptographic Hash is a paid API for AI agents from agent402.tools, paid per call via x402, $0.001/call, status unknown (last checked 2026-09-14).

Computes a cryptographic hash (SHA-256, SHA-512, SHA-1, or MD5) of a text string, returning both hex and base64 digests.

## Facts

- Endpoint: POST https://agent402.tools/api/hash
- 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/agent402-tools-cryptographic-hash-caa4efbc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0jeHLHzsKHXW12Jm7hsgk

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 agent402-tools-cryptographic-hash-caa4efbc -d '<json body>'
```

Example prompt: Can you hash the text 'Hello, World!' using SHA-512 and give me both the hex and base64 digests?

## When to prefer this

Use this endpoint when you need a quick, paid-per-call cryptographic hash of a text string without setting up local crypto libraries. Ideal for agents needing one-off integrity checks, fingerprinting, or digest generation supporting multiple algorithms via a single API.

## Known failure modes

- Text input exceeds 100KB limit — request rejected
- Invalid algorithm name supplied — returns error
- Missing 'text' field in request body — validation error
- Payment failure via x402 protocol — 402 response with payment details

## How this service works

Cryptographic hash of a text string - sha256 (default), sha512, sha1 or md5 - returned as hex and base64. Use it for content fingerprints, integrity checks and deterministic ids; pure computation, instant.

## Output

Returns the cryptographic hash of the input text in both hexadecimal and base64 encoding, using the specified algorithm (sha256, sha512, sha1, or md5).

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "algo": {
   "type": "string",
   "description": "sha256 | sha512 | sha1 | md5"
  },
  "text": {
   "type": "string",
   "description": "Text to hash (max 100KB)"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "hex": "b94d27…",
  "algo": "sha256",
  "base64": "uU0n…"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agent402-tools-cryptographic-hash-caa4efbc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agent402.tools](https://www.zero.xyz/host/agent402.tools/llms.txt)
