Welcome to the Redgold Wallet Guide. This guide will walk you through the process of setting up a wallet, sending and receiving transactions, and other common wallet operations. If you have not yet installed Redgold, please see the installation guide in the Getting Started section.
While advanced users may wish to use the CLI (discussed below,) the most common usage of Redgold will be through the
native GUI. This is packaged into the installed binary and can be run through instructions in the getting-started
section. It can be invoked directly with
redgold gui or just by running
redgold with no arguments.
Before getting started, we strongly recommend using a cold hardware wallet for all transactions. The GUI currently
supports only Trezor
hardware wallets, and to use this you must install an additional dependency manually besides the Redgold software
trezorctl which is available as a python module. Please follow the
Trezor Setup Guide to get
started. The main command from this guide that you'll need to install trezor cli is:
pip3 install trezor
If you should get an error like this:
WARNING: The script trezorctl is installed in '/Users/user/Library/Python/3.9/bin' which is not on PATH.
Error: DataError: Forbidden key path
Please see this guide for a solution.
When starting, navigate to the
Wallet tab on the left side panel, and you should see a screen like this:
By default, the wallet screen will start on the
Cold Hardware section (as you are strongly encouraged to use a
hardware wallet.) Right now, the only supported hardware wallet is Trezor. You will need to connect your
Trezor and unlock it with your PIN. Once you have done so, the indicator icon for 'Connected' will show green
and your Trezor device name and id will be listed in the GUI.
By default, no public keys will be stored locally unless specifically requested by the user, hence the first command you must issue in order to discover a public key is to click the "Get Public Key" button. This will issue the trezorctl get-public-node command and return the public key for the 50th BIP-44 Bitcoin account of your wallet. You will be prompted to enter your passphrase on the device, and you can inspect the logs or code to verify the command being issued follows the proper get-public-node API. Due to the nature of the Trezor device, this should be considered a safe and secure operation to perform.
The main reason for this, is that the Redgold wallet is not yet an officially supported application of Trezor, as it takes many years to get an application approved by Trezor. However, Redgold transactions are unique in the sense that they support a signature done through the Bitcoin Message Signing API supported by almost all hardware wallets. This makes it extremely straightforward to add support for additional hardware wallets in the future.
By default, trezorctl only works with accounts with an index below 100, so the default key derivation path is set to
m/44'/0'/50'/0/0. If you are confused about what this syntax means:
- the 'm' is a prefix indicating that this is a path to a derived key.
- The 44' indicates that this is a BIP44 path. BIP-44 is used to indicate keys that are derived
with a non-segwit derivation path. If you are using your Trezor typically, it would use an
84'derivation path corresponding to BIP-84 Segwit addresses.
- These keys do not overlap with the standard Bitcoin keys (deliberately.)
- Redgold uses signatures in the calculation of it's transaction hash, like Ethereum, making it non-segwit it's own transaction type.
- For external integrations with Bitcoin (native swaps / AMMs, Redgold nodes use BIP-84
0'indicates that this is a Bitcoin account type, and this is required to invoke the Bitcoin Message
- Signing API for trezorctl.
50'indicates that this is account #50, as trezorctl sets the max at 100, we have chosen a high account number to avoid any potential overlap with your other accounts.
The reason for all of this is to be able to make use of the Trezor Bitcoin Message Signing API, which is the only mechanism to add immediate Trezor support without waiting years for approvals.
Right now, only a single account is supported, for which you will see the public key and address displayed in the GUI. Please use the hex address provided to receive funds.
In order to start the sending process, click the
Send button and provide a destination address and an amount.
After you have entered values in both fields, you will be able to click the
Prepare transaction button to inspect
and view the json of the transaction that was generated, as well as view the hash that you will compare against the
viewscreen on the hardware device.
Here we see a transaction that has been prepared and is ready to be signed. You can see the transaction hash at the
bottom below the json which you will need to verify on the Trezor screen. When you click the
Sign Transaction button
you should be prompted to enter a passphrase again on your hardware device, and then see a window indicating that
it is requesting to sign a Bitcoin Message with a value of
Redgold <your transaction hash here>
After you have verified the transaction hash on your device, you can click the checkmark button and the transaction will be signed by your device and the signature returned to the GUI before the transaction is actually ready to be broadcast.
You should see the JSON update to include your signature:
You can now click the
Broadcast button to broadcast the transaction to the network. The software will automatically
poll the network until the transaction has been accepted or rejected, and you should see a message indicating the
transaction has been accepted by the network or a rejection message if something went wrong.
This example will show the full flow with a newly generated mnemonic / keys in order to allow you to quickly test the network, for more secure CLI operations please use the later CLI commands that include hardware flags.
Before issuing following commands, set your current desired network environment (for testing transactions you may wish to use a lower environment tier such as dev, staging, or test)
main for mainnet
test for testnet
dev for dev branch
To generate a random mnemonic as a word string which writes to stdout:
redgold generate-words > words
spray vicious advice area best device arrange federal payment remind host light cat defy soda festival song help hurt luggage police reopen myth wear wage worry egg acquire emotion occur slender wagon steel hero endless tattoo south better outside slow spice sister abandon slim surprise guide better candy
For later commands, export the mnemonic as an environment variable
export REDGOLD_WORDS="$(cat words)"
To create a sample address from this mnemonic
redgold address --index 0 > address
To request some sample currency for testing (default 5.0 returned)
redgold faucet --to "$(cat address)" > faucet_tx_hash
To check the faucet transaction for acceptance:
redgold query --hash "$(cat faucet_tx_hash)"
To send currency to someone else (create and broadcast a transaction)
redgold send --to <destination_address> --amount <float amount>
As an example, generate a second address locally and send to it:
redgold address --index 1 > address2
redgold send --to "$(cat address2)" --amount 2.0 > send_tx_hash
To check the transaction for acceptance:
redgold query --hash "$(cat send_tx_hash)"
To check the balance of an address:
Either query for all information on the address:
redgold query --hash "$(cat address2)"
Or look at the balance only:
redgold balance --address "$(cat address2)"
WARNING: Not fully implemented
As before, please see the first section for details on installing
trezorctl, as below commands require it as a
dependency to function correctly.
redgold --trezor send --address <DESTINATION_ADDRESS>