walletlock
walletlock
Removes the wallet encryption key from memory, locking the wallet. After calling this method, you will need to call walletpassphrase again before being able to call any methods which require the wallet to be unlocked.
# Set the passphrase for 2 minutes to perform a transaction
yerbas-cli walletpassphrase "my pass phrase" 120
# Perform a send (requires passphrase set)
yerbas-cli sendtoaddress "XwnLY9Tf7Zsef8gMGL2fhWA9ZmMjt4KPwG" 1.0
# Clear the passphrase since we are done before 2 minutes is up
yerbas-cli walletlock
Output
Result | Type | Description |
---|---|---|
"signature" | (string) | The signature of the message encoded in base 64 |
Result:
"signature" (string) The signature of the message encoded in base 64
Examples
curl --user myusername --data-binary '{"jsonrpc": "1.0", "id":"curltest", "method": "walletlock", "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:9998/