listaddress Method
Lists all the addresses in the current wallet.
note
Before you can invoke this method you must:
Install the plugin RpcServer
Call the RPC method
openwalletto open the wallet first.
Exception#
- -302, No opened wallet.
Example#
Request body:
{ "jsonrpc": "2.0", "method": "listaddress", "params": [], "id": 1}Response body:
{ "jsonrpc": "2.0", "id": 1, "result": [ { "address": "NikhQp1aAD1YFCiwknhM5LQQebj4464bCJ", "haskey": true, "label": null, "watchonly": false }, { "address": "NgaiKFjurmNmiRzDRQGs44yzByXuSkdGPF", "haskey": true, "label": null, "watchonly": false } ]}Response description:
address: The address in the wallet.
haskey: Whether there is a private key for the address.
label: Address label.
watchonly: Indicates whether it is a watch only address.