---
title: "sha256 · RUAL Documentation"
description: "HMAC-SHA256 of the value keyed with the secret, as lowercase hex : e.g. to verify a webhook's X-Mssgs-Signature: sha256=&lt;hex&gt; header against the r…"
canonical: https://docs.rual.nl/block-types/value/value_sha256_hmac
language: en
---

# sha256

This block is part of the [`value`](https://docs.rual.nl/block-types/value) group and was last modified in core [`v15.0.0`](https://docs.rual.nl/core-versions/150000).

HMAC-SHA256 of the value keyed with the secret, as lowercase hex : e.g. to verify a webhook's `X-Mssgs-Signature: sha256= ` header against the raw request body.

- secret required `value`

- value required `value`

- signature `value`

Outputs the HMAC-SHA256 of value keyed with secret, as lowercase hex on the signature pin. Unwired or empty pins are treated as "" -- the block still emits a signature rather than erroring.

A typical wiring for [sha256](https://docs.rual.nl/block-types/value/value_sha256_hmac): [get raw body](https://docs.rual.nl/block-types/http%20connection/httpconnection_get_body_raw) feeds the `secret` pin; the `signature` out pin feeds [convert to uppercase](https://docs.rual.nl/block-types/value/value_to_uppercase).

![Studio canvas example for the sha256 block: typical wiring for sha256.](https://docs.rual.nl/canvas-examples/value_sha256_hmac.png)

### Commonly used with

In production blueprints, this block is most often wired together with:

- [get raw body](https://docs.rual.nl/block-types/http%20connection/httpconnection_get_body_raw): feeds into this block. Returns the request body exactly as received on the wire, as a string — the bytes an HMAC signature covers. Use this (never a re-serialized object) when verifying signature headers like X-Mssgs-Signature.

- [dynamic value](https://docs.rual.nl/block-types/value/value_default_dynamic): this block feeds into it. Returns the provided value with support for dynamic inpins using {name:type} placeholders — the pin's name first, then its type, e.g. {guid:value}.

### Version history

Introduced in [`v15.0.0`](https://docs.rual.nl/core-versions/150000).
