VersionByte
in package
Version byte constants for Stellar StrKey encoding
Each Stellar address type has a unique version byte that determines the first character of the encoded string representation. These version bytes are used when encoding and decoding between binary data and human-readable strings.
Address prefixes:
- G: Account ID (Ed25519 public key)
- M: Muxed account ID (multiplexed account)
- S: Secret seed (Ed25519 private key)
- T: Pre-authorized transaction hash
- X: SHA-256 hash (for hash-locked transactions)
- P: Signed payload (Ed25519 with additional signature data)
- C: Contract ID (Soroban smart contract)
- L: Liquidity pool ID
- B: Claimable balance ID
Tags
Table of Contents
Constants
- ACCOUNT_ID = 6 << 3
- CLAIMABLE_BALANCE_ID = 1 << 3
- CONTRACT_ID = 2 << 3
- LIQUIDITY_POOL_ID = 11 << 3
- MUXED_ACCOUNT_ID = 12 << 3
- PRE_AUTH_TX = 19 << 3
- SEED = 18 << 3
- SHA256_HASH = 23 << 3
- SIGNED_PAYLOAD = 15 << 3
Constants
ACCOUNT_ID
public
mixed
ACCOUNT_ID
= 6 << 3
CLAIMABLE_BALANCE_ID
public
mixed
CLAIMABLE_BALANCE_ID
= 1 << 3
CONTRACT_ID
public
mixed
CONTRACT_ID
= 2 << 3
LIQUIDITY_POOL_ID
public
mixed
LIQUIDITY_POOL_ID
= 11 << 3
MUXED_ACCOUNT_ID
public
mixed
MUXED_ACCOUNT_ID
= 12 << 3
PRE_AUTH_TX
public
mixed
PRE_AUTH_TX
= 19 << 3
SEED
public
mixed
SEED
= 18 << 3
SHA256_HASH
public
mixed
SHA256_HASH
= 23 << 3
SIGNED_PAYLOAD
public
mixed
SIGNED_PAYLOAD
= 15 << 3