Chain ID and Address Format

Chain ID

Planq has different Chain IDs to distinguish between the devnet, testnet and mainnet. When running Planq in your local environment, you will need to decide your own Chain ID.

For example, our mainnet Chain ID is planq_7070-2.

Address prefix

BIP-0173 defines a new format for segregated witness output addresses that contains a human-readable part which identifies the coin type. Planq has different address prefixes for its corresponding network types, these prefixes are:

Testnet

plq

Planq uses the Bech32 address format wherever users must handle binary data. Bech32 encoding provides robust integrity checks on data and the human readable part (HRP) that provides contextual hints that can assist UI developers with providing informative error messages. Specifically, we have the following HRP prefixes for different address types in the mainnet:

Address bech32 Prefix

Account

plq

Validator Operator

plqvaloper

Consensus Nodes

plqvalcons

We can use the keys show command of planqd with the flag --bech <type> (acc|val|cons) to obtain the addresses and keys as mentioned above. For example:

$ planqd keys show mykey --bech acc
- name: mykey
  type: local
  address: plq1c47uszfujup3ax0d5p4ges3pxa4ne9zqc20pgf
  pubkey: '{"@type":"/ethermint.crypto.v1alpha1.ethsecp256k1.PubKey","key":"A4KKhRCbnMr3mSqBfeeMPp3svRlPhnKlmxh6MmZ+AoR5"}'
  mnemonic: ""

$ planqd keys show test --bech val
- name: mykey
  type: local
  address: plqvaloper1c47uszfujup3ax0d5p4ges3pxa4ne9zqx5zmwc
  pubkey: '{"@type":"/ethermint.crypto.v1alpha1.ethsecp256k1.PubKey","key":"A4KKhRCbnMr3mSqBfeeMPp3svRlPhnKlmxh6MmZ+AoR5"}'
  mnemonic: ""

$ planqd keys show test --bech cons
- name: mykey
  type: local
  address: plqvalcons1c47uszfujup3ax0d5p4ges3pxa4ne9zqj838ze
  pubkey: '{"@type":"/ethermint.crypto.v1alpha1.ethsecp256k1.PubKey","key":"A4KKhRCbnMr3mSqBfeeMPp3svRlPhnKlmxh6MmZ+AoR5"}'
  mnemonic: ""

Last updated