Command line wallet (CLI) / General description

Questions and answers on the command line wallet
Post Reply
User avatar
Alzeboss
Site Admin
Posts: 63
Joined: Sat Dec 16, 2017 11:54 am

Command line wallet (CLI) / General description

Post by Alzeboss » Wed Jan 03, 2018 9:56 am

First of all, be sure you read this viewtopic.php?f=16&t=16

CLIwalletfiledescription.png
filedescriptionClIwallett
CLIwalletfiledescription.png (46.83 KiB) Viewed 655 times
Here you can see what is the CLI (command line) wallet made of:
_b2bcoind.exe :
_miner.exe :
_simplewallet.exe :
_walletd.exe :
_A conf folder :


Let's start using the CLI wallet :

A) First you need to create a batch file. How to create it ?
CLIwalletbatchcreation1.png
createbatchfile11
CLIwalletbatchcreation1.png (28.75 KiB) Viewed 655 times
On windows, right click on a folder > new > text file.
Open this text file and write this inside : "b2bcoind.exe --config-file configs/b2bcoin.conf"
(when you ll double click it, it will start the program "b2bcoind.exe" with the conf file "b2bcoin.conf" located in the "configs" folder)
CLIwalletbatchcreation2.png
createbatchfile22
CLIwalletbatchcreation2.png (53.77 KiB) Viewed 654 times
Save your file, for exemple as "start synch.bat" (choose the name you want but .bat is mandatory) , and choose in the combobox "all files"


B) Double-click the .bat file you have just created
ou should see this :
CLIwalletsynch1.png
CLIsynch11
CLIwalletsynch1.png (50.91 KiB) Viewed 653 times
1-The last block synchronised
2-The total number of block in the blockchain
3-Number of block which has'nt be synchronised yet (and how many days they represent)

Once the synchronisation is finished, you should see this :
CLIwalletsynch2.png
CLIsynch22
CLIwalletsynch2.png (66.55 KiB) Viewed 650 times
Don't close the console.


C) Create a second batch file :
Open a new textfile, write in it "simplewallet.exe --config-file configs/b2bcoin.conf"
(when you ll double click it, it will start the program "simplewallet.exe" with the conf file "b2bcoin.conf" located in the "configs" folder)
Save your file, for exemple as "start wallet.bat" (choose the name you want but .bat is mandatory) , and choose in the combobox "all files"

D) Double-click the batch file you have just created:

A second console should appear :
CLIwalletsynch4m.png
CLIsync4
CLIwalletsynch4m.png (29.56 KiB) Viewed 636 times
It will ask you this :
"What do you want to do?
[O]pen existing wallet, [G]enerate new wallet file, mport wallet or [E]xit."
_Choose generate if you want to create a new wallet by typing the letter "g" (1), press ENTER, then enter/choose his name (2), press ENTER and create a password (3), press ENTER. (if you loose the password, your coins will be lost FOREVER !!!)
CLIwalletsynch3m.png
CLIsync3
CLIwalletsynch3m.png (43.85 KiB) Viewed 636 times
_Choose open by typing the letter "o" to open an existing wallet (1), press ENTER, then enter his name (2), press ENTER and then his password (3), press ENTER.
The wallet will now getting infos from the blockchain (first console) (4), it can take time, wait. When it's finished, you should see this :



E) Interact with the wallet :
CLIwalletcommandm.png
CLIcom
CLIwalletcommandm.png (56.32 KiB) Viewed 636 times
Now all is ready to work, type "help" to see what can be done, it will give you the synthax.
Be careful, synthax ix very important, if you don't respect it, it won't work.


address Show current wallet public address
balance Show current wallet balance
bc_height Show blockchain height
exit Close wallet
export_keys Show the secret keys of the openned wallet
help Show this help
incoming_transfers Show incoming transfers
list_transfers Show all known transfers
payments payments <payment_id_1> [<payment_id_2> ... <payment_id_N>] - Show payments <payment_id_1>, ... <payment_id_N>
reset Discard cache data and start synchronizing from the start
save Save wallet synchronized data
set_log set_log <level> - Change current log level, <level> is a number 0-4
transfer transfer <mixin_count> <addr_1> <amount_1> [<addr_2> <amount_2> ... <addr_N> <amount_N>] [-p payment_id] [-f fee] - Transfer <amount_1>,... <amount_N> to <address_1>,... <address_N>, respectively. <mixin_count> is the number of transactions yours is indistinguishable from (from 0 to maximum available)

For exemple, to send 10 coins to dkghjlqkdhf : "transfer 1 dkghjlqkdhf 10"
(mixin amount is the level of privacy you want, 1= low privacy; 7= high privacy)

When all is done, enter "save", press enter then "exit" press enter in the wallet console , and "exit" in the blockchain console.


B2Bcoin lover 8-)

Post Reply