hash_generate
Generate a SHA-256 or SHA-512 digest of UTF-8 text in hexadecimal or Base64 form. Use it for checksums, cache keys or comparing content; it is a plain digest, not a keyed HMAC or a password hash. Runs without network access and does not store your input. Input up to 100,000 bytes; larger input is an error. Returns algorithm, encoding, digest and bytes (input length). Defaults: sha256, hex; any other algorithm or encoding is an error.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"text": "<text>"
},
"name": "hash_generate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes | Input text, up to 100 KB. | |
| encoding | No | Output encoding. Default hex. | |
| algorithm | No | Hash algorithm. Default sha256. | |
| l402_proof | No | L402 payment proof "<macaroon>:<preimage>". Omit on the first call; an unpaid call returns a 0 sat Lightning invoice and the macaroon. Pay the invoice, then repeat the call with this argument set. |