Light Dark

Functions

blake3 core

fn (data: Str | Bytes): Str

BLAKE3 cryptographic hash. Fast, modern hash function. Returns hex-encoded 64-character string.

Example

blake3("hello")
// 64-character hex string

// BLAKE3 is faster than SHA-256 for large inputs
blake3(file-contents)

sha256 core

fn (data: Str | Bytes): Str

SHA-256 cryptographic hash. Returns hex-encoded 64-character string.

Example

sha256("hello")
// "2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824"

sha256("hello world")
// "b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9"

md5

fn (data: Str | Bytes): Str

MD5 hash (legacy). Use only for checksums or compatibility. NOT secure for cryptographic purposes.

Example

md5("hello")
// "5d41402abc4b2a76b9719d911017c592"

sha1

fn (data: Str | Bytes): Str

SHA-1 hash (legacy). Use only for compatibility with existing systems like GitHub webhooks. NOT recommended for new security applications.

Example

// Verify GitHub webhook signature
sha1(payload)

sha384

fn (data: Str | Bytes): Str

SHA-384 cryptographic hash. Returns hex-encoded 96-character string.

Example

sha384("hello")
// 96-character hex string

sha512

fn (data: Str | Bytes): Str

SHA-512 cryptographic hash. Returns hex-encoded 128-character string.

Example

sha512("hello")
// 128-character hex string