importpubkey
#
CommandAdds a public key (in hex) that can be watched as if it were in your wallet but cannot be used to spend. Requires a new wallet backup.
#
Argumentspubkey
*#
(string, required)
The hex-encoded public key
label
#
(string, optional, default="")
An optional label
rescan
#
(boolean, optional, default=true)
Rescan the wallet for transactions
#
ExamplesNote: This call can take over an hour to complete if rescan is true, during that time, other rpc calls
may report that the imported pubkey exists but related transactions are still missing, leading to temporarily incorrect/bogus balances and unspent outputs until rescan completes.
Import a public key with rescan
Import using a label without rescan
As a JSON-RPC call
Running following help command
Will produce following output: