I would like to use the Wallet RPC API to determine if the wallet I am connecting to is view-only.
I'm thinking about using the
query_key command with
key_type=mnemonic. Is it safe to assume that if the command fails to return a mnemonic, the wallet is view-only? Or is there a better way?
I'm guessing this is not the best way, because the documentation mentions that older wallets do not have a mnemonic.