# fittings Hash Digest

> fittings Hash Digest is a paid API for AI agents from fittings.sh, paid per call via x402, $0.0035/call, status unknown (last checked 2026-09-14).

Computes a SHA-1, SHA-256, SHA-384, or SHA-512 cryptographic hash of a supplied text string, returning both hex and base64 encodings.

## Facts

- Endpoint: POST https://fittings.sh/v1/crypto/hash-digest
- Price: $0.0035/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/fittings-hash-digest-576cf8b4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_8gVG1ihOQmMi4O0eb1PY6

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 fittings-hash-digest-576cf8b4 -d '<json body>'
```

Example prompt: Can you compute the SHA-256 hash of the text 'Hello, world!' and give me both the hex and base64 versions?

## When to prefer this

Choose this endpoint when you need a quick, reliable cryptographic hash of a text string without setting up local crypto libraries, or when running in an environment where you want a paid, auditable hashing call. It's ideal for agents needing both hex and base64 output in a single call, or when you want to support multiple SHA variants (1/256/384/512) with a consistent interface.

## Known failure modes

- Unsupported algorithm name returns an error — must be exactly SHA-1, SHA-256, SHA-384, or SHA-512
- Empty or missing text field returns a validation error
- Malformed JSON request body causes a 400-level error
- Payment not attached or insufficient USDC balance returns a 402 error

## How this service works

Compute a SHA-1/256/384/512 digest of supplied text, returned as hex and base64.

## Output

Returns a JSON object containing the computed hash digest of the input text in both hexadecimal and base64 formats, along with the algorithm used. Both encodings are provided in a single response.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "text": {
   "type": "string"
  },
  "algorithm": {
   "type": "string",
   "description": "SHA-256 | SHA-384 | SHA-512 | SHA-1"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/fittings-hash-digest-576cf8b4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from fittings.sh](https://www.zero.xyz/host/fittings.sh/llms.txt)
