mirror of
https://github.com/bitcoinresearchkit/brk.git
synced 2026-07-01 22:39:03 -07:00
website_next: move hash logic to clients
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
[**brk-client**](../README.md)
|
||||
|
||||
***
|
||||
|
||||
[brk-client](../globals.md) / addressPayloadHashPrefix
|
||||
|
||||
# Function: addressPayloadHashPrefix()
|
||||
|
||||
> **addressPayloadHashPrefix**(`payload`, `nibbles`): `string`
|
||||
|
||||
Compute the RapidHash v3 hash-prefix used by `/api/address/hash-prefix/{addr_type}/{prefix}`.
|
||||
|
||||
## Parameters
|
||||
|
||||
### payload
|
||||
|
||||
`Uint8Array` | `ArrayBuffer` | `ArrayBufferView` | `number`[]
|
||||
|
||||
Raw address payload bytes. Must be 1 to 65 bytes.
|
||||
|
||||
### nibbles
|
||||
|
||||
`number`
|
||||
|
||||
Prefix length from 1 to 16 hex nibbles.
|
||||
|
||||
## Returns
|
||||
|
||||
`string`
|
||||
|
||||
Reference in New Issue
Block a user