# Usage Guide

A list of all possible commands can be found by executing `nix-cli help` or viewing them on the Console Commands page.

{% content-ref url="../wallet-functionality/cli/console-commands" %}
[console-commands](https://nixwiki.gitbook.io/home/wallet-functionality/cli/console-commands)
{% endcontent-ref %}

The `command` method takes a list of parameters and returns the response. For example, this would be a valid way to ghost (and un-ghost) 0.1 NIX and log the response to the console:

```
//ghost 0.1 NIX and log response
client.command('ghostamountv2', '0.1').then(value => console.log(value)); 

//un-ghost 0.1 NIX and log response
client.command('unghostamountv2', '0.1').then(value => console.log(value)); 
```

Here is a list of the most popular commands. Legend: `<required_value>`, `[optional_value]`

| Command                              | Effect                                                |
| ------------------------------------ | ----------------------------------------------------- |
| ghostamountv2 \<amount> \[address]   | Ghost \<amount> NIX \[to external CKP].               |
| unghostamountv2 \<amount> \[address] | Un-ghost \<amount> NIX \[to external address or CKP]. |
| getpubcoinpackv2                     | Get a commitment key pack (CKP) for 2-Way-Ghosting.   |
| getblockchaininfo                    | Get the current blockchain statistics.                |
| getstakinginfo                       | Get the current staking statistics.                   |
| sendfrom \<from> \<to> \<amount>     | Sends \<amount> NIX \<from account> \<to address>.    |
| sendtoaddress \<address> \<amount>   | Sends \<amount> NIX to \<address>.                    |
| getbalance \[account]                | Get balance for entire wallet or only one \[account]. |

Please note that you can always execute `help <command_name>` for a more detailed explanation of the commands:

![help getaddressbalance](https://2383684954-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LShwTn5gOeQj7NnQ-31%2F-Lo1uR82v5vjnD6cjx1L%2F-Lo24FyVCMefZW8IMquS%2Fhelp-getaddressbalance.png?alt=media\&token=b52bcc7e-02e0-4134-8327-2e710e37767d)
