Lisk Elements Constants

The Lisk Elements Constants object provides some handy general-purpose constants for use with the Lisk Ecosystem.

Installation

Add Lisk Client as a dependency of your project:

$ npm install @liskhq/lisk-constants

Upgrade

npm update @liskhq/lisk-constants

Usage

import * as constants from '@liskhq/lisk-constants';

constants.EPOCH_TIME; (1)
constants.EPOCH_TIME_MILLISECONDS; (2)
constants.EPOCH_TIME_SECONDS; (3)

constants.MAX_ADDRESS_NUMBER; (4)
constants.MAX_TRANSACTION_AMOUNT; (5)
constants.SIGNED_MESSAGE_PREFIX; (6)

constants.BETANET_NETHASH; (7)
constants.TESTNET_NETHASH; (8)
constants.MAINNET_NETHASH; (9)
1 Date from which timestamps are calculated.
2 EPOCH_TIME as milliseconds since Unix Epoch.
3 EPOCH_TIME as seconds since Unix Epoch.
4 Maximum valid number which can form an address when suffixed with an 'L'.
5 Maximum valid amount for a transaction. Maximum value for PostgreSQL bigint.
6 The prefix attached to all messages signed according to the Lisk message signature protocol.
7 Nethash for Betanet.
8 Nethash for Testnet.
9 Nethash for Mainnet.