Bitcoin Tutorials - Herong's Tutorial Notes - v1.07, by Herong Yang
Bitcoin Core CLI
This section describes what is Bitcoin Core CLI Programs.
Bitcoin Core CLI allows you to run commands on Bitcoin Core Daemon to interact with the Bitcoin network. Bitcoin Core CLI is included in the of Bitcoin Core package,
Here is how you can run Bitcoin Core CLI and see its command line options:
C:\>\local\bitcoin-0.15.1\bin\bitcoin-cli -?
Bitcoin Core RPC client version v0.15.1
Usage:
bitcoin-cli [options] <command> [params] Send command to Bitcoin Core
bitcoin-cli [options] -named <command> [name=value] ...
Send command to Bitcoin Core (with named arguments)
bitcoin-cli [options] help List commands
bitcoin-cli [options] help <command> Get help for a command
Options:
-?
This help message
-conf=<file>
Specify configuration file (default: bitcoin.conf)
-datadir=<dir>
Specify data directory
-testnet
Use the test chain
-regtest
Enter regression test mode, which uses a special chain in which
blocks can be solved instantly. This is intended for regression
testing tools and app development.
-rpcconnect=<ip>
Send commands to node running on <ip> (default: 127.0.0.1)
-rpcport=<port>
Connect to JSON-RPC on <port> (default: 8332 or testnet: 18332)
-rpcuser=<user>
Username for JSON-RPC connections
-rpcpassword=<pw>
Password for JSON-RPC connections
...
Table of Contents
Access Bitcoin Test Network "-testnet"
"bitcoin-cli getblock" Command
bitcoin-cli Transaction Commands
"bitcoin-cli encryptwallet" - Set Wallet Password
"bitcoin-cli walletpassphrase" - Unlock Wallet
"bitcoin-cli backupwallet" - Backup Wallet