UNPKG

nanocurrency

Version:

A toolkit for the Nano cryptocurrency, allowing you to derive keys, generate seeds, hashes, signatures, proofs of work and blocks.

31 lines (30 loc) 974 B
/** Hash block parameters. */ export interface HashBlockParams { /** The account address */ account: string; /** * The hash of the previous block on the account chain, in hexadecimal format * * `0000000000000000000000000000000000000000000000000000000000000000` if `open` block. */ previous: string; /** The representative address */ representative: string; /** The resulting balance, in raw */ balance: string; /** * The account or block hash meant as a link, in address or hexadecimal format * * Read more on the [Official Nano Wiki](https://github.com/nanocurrency/raiblocks/wiki/Universal-Blocks-Specification) */ link: string; } /** @hidden */ export declare function unsafeHashBlock(params: HashBlockParams): string; /** * Hash a state block. * * @param params - Parameters * @returns Hash, in hexadecimal format */ export declare function hashBlock(params: HashBlockParams): string;