CHAIN
Check Bitcoin balances and watch fees from the command line
Bitcoin support in glnc covers balances and live mempool fees. Address formats: bc1... (bech32 SegWit) and 1... or 3... (legacy). Balance data via blockstream.info, fee data via mempool.space.
Quick install
On macOS or Linux:
brew install aryarahimi1/glnc/glncBalance on Bitcoin
glnc detects Bitcoin addresses by format (bech32 or legacy) and queries blockstream.info for the UTXO set and current balance.
glnc balance bc1qxy2kgdygjrsqtzq2n0yrf2493p83kkfjhx0wlhBitcoin gas right now
Bitcoin fee tiers from the mempool.space API. Reported in sat/vB; the table also shows USD estimates.
glnc gas --chain bitcoinAliases
Every alias resolves to the same chain. Pass any of them to --chain:
glnc balance 0x... --chain btcBitcoin-specific notes
What glnc reads from Bitcoin
Two sources, no API key, no account. Balance and UTXO data come from blockstream.info/api: glnc queries the per-address summary endpoint, sums confirmed UTXO values, and renders the result in BTC with a USD estimate at the current spot price from CoinGecko. Fee data comes from mempool.space/api: the same fee tiers that drive the live mempool.space dashboard, exposed as a JSON endpoint and pulled fresh on each glnc gas invocation.
There is no token support on Bitcoin at layer 1. Bitcoin has no native fungible-token standard; ETF wrappers, Ordinals, and BRC-20 inscriptions are out of scope for glnc. If you hold sats on the base chain, glnc reports them. If you hold inscribed assets, use a dedicated Ordinals explorer.
Address formats
glnc detects all three common Bitcoin address formats from their prefix:
bc1...: bech32 SegWit (P2WPKH and P2WSH). The current default for most wallets. Lowercase, 42 to 62 characters, checksum-validated by glnc before any RPC call.1...: legacy pay-to-public-key-hash (P2PKH). Original Bitcoin format; still widely used by older wallets and cold storage.3...: pay-to-script-hash (P2SH). Common for multisig setups and wrapped-SegWit addresses.
Taproot (bc1p...) addresses share the bech32m prefix and resolve through the same Blockstream endpoint as bech32. Pass any of these formats directly; the --chain flag is never required.
Why no tx
Bitcoin transactions are inputs and outputs (UTXO), not calldata. There is no smart contract, no function selector, no nested call tree to decode. glnc's tx command is built for EVM calldata: ERC-20 transfers, Uniswap routers, Governor proposals, Safe executions. None of that has a Bitcoin analogue. For a Bitcoin transaction you want to inspect, the existing mempool.space explorer already does the job better than a CLI would; glnc points you there rather than ship a half-correct version.
Fee tiers explained
Bitcoin fees are quoted in sat/vB: satoshis per virtual byte. A transaction's total fee is its virtual size (in vBytes) multiplied by the rate you choose. mempool.space buckets pending transactions by fee rate and publishes the rate that gets included in the next block, in three blocks, and in six blocks; glnc reads those buckets directly and shows them as p10, p50, p90 columns, with the fast and average estimates priced in USD at the current BTC spot price. The base column is blank for Bitcoin because there is no base fee in the EIP-1559 sense: Bitcoin fees are pure auction, not split into base plus priority.
Related