Build on NORTH
Test coins, a private test chain on your own computer in a few minutes, and pointers to everything you need to build wallets, payments and tools for TrueNorth.
Test coins
The testnet faucet sends 100 tNORTH on testnet4 at once: no email, no sign-up.
A private test chain (regtest)
Regtest runs a TrueNorth chain only on your computer. You make blocks whenever you like, so payments confirm instantly. It's the quickest way to develop and to run automated tests. With TrueNorth Core installed:
truenorthd -regtest -daemon -fallbackfee=0.0001
truenorth-cli -regtest createwallet dev
ADDR=$(truenorth-cli -regtest getnewaddress)
truenorth-cli -regtest generatetoaddress 101 $ADDR
truenorth-cli -regtest getbalance
truenorth-cli -regtest sendtoaddress $(truenorth-cli -regtest getnewaddress) 10
truenorth-cli -regtest generatetoaddress 1 $ADDR
truenorth-cli -regtest stop- 101 blocks: newly mined coins can be spent after 100 confirmations, so the balance shows 512 tNORTH, the first block's reward.
- One more block confirms the payment you just sent.
-fallbackfeesets a fee to use until the chain has enough history to estimate one.- Regtest addresses start with
rnorth1. To start over, stop the node and delete theregtestfolder in TrueNorth's data folder. - On Windows, the commands are
truenorthd.exeandtruenorth-cli.exe, and$ADDRbecomes a pasted address.
The public test network (testnet4)
Testnet4 is shared by everyone testing TrueNorth: real peers, real blocks every two minutes, and coins with no value. Use it to try your software against other nodes and wallets before mainnet.
truenorthd -testnet4 -daemon
truenorth-cli -testnet4 getblockchaininfoNodes from v30.5.4 find testnet4 peers by themselves, and the chain is small, so it syncs in minutes. Get coins from the testnet faucet, or mine some: testnet4's total hashrate is tiny, so one computer finds blocks quickly. Testnet4 is reset now and then (the last reset). TrueNorth's testnet guide has the details.
Networks at a glance
| Network | Option | Addresses start | P2P port | RPC port |
|---|---|---|---|---|
| Mainnet | (none) | north1 | 9555 | 9554 |
| Testnet4 | -testnet4 | tnorth41 | 49555 | 49554 |
| Signet | -signet | snorth1 | 39555 | 38332 |
| Regtest | -regtest | rnorth1 | 18444 | 18443 |
Default addresses are P2QRH, with a z after the 1 (for example north1z…). Each network keeps its data in its own folder inside TrueNorth's data folder: ~/.truenorth on Linux, ~/Library/Application Support/TrueNorth on macOS, %LOCALAPPDATA%\TrueNorth on Windows.
References
- Node API: the JSON-RPC interface, output descriptors and ZMQ notifications (new blocks and transactions pushed to your app).
- P2QRH addresses: the design document and the wallet test vectors, for checking your own address and signing code.
- Payment links: the
truenorth:payment link spec, and the Pay with NORTH button maker. - Blockchain data without a node: the tnexplore.com API (blocks, transactions, address summaries, pools and network statistics) and Northbound, an open-source wallet server with an HTTP API.
- Building from source: the Unix build guide in TrueNorth's repository.
Get paid to build
The bounty board lists tasks people will pay NORTH for, and anyone can post one.