Thursday, December 26, 2024

Bitcoin Core RPC cURL – importdescriptors failing on loaded pockets

I’m working the next request to load a pockets.

curl --location 'person:[email protected]:8332/pockets/test_multisig"' 
--header 'Content material-Kind: textual content/plain' 
--data '{
    "jsonrpc": "2.0",
    "technique":"loadwallet",
    "params": ["test_multisig"],
    "id": "test_multisig_wallet_load"
}'

It returns…

{"consequence":null,"error":{"code":-35,"message":"Pockets "test_multisig" is already loaded."},"id":"test_multisig_wallet_load"}

Nevertheless I then run this actual request, and obtain an error as if the pockets is just not loaded.

curl --location 'person:[email protected]:8332/pockets/test_multisig"' 
--header 'Content material-Kind: textual content/plain' 
--data '{
    "jsonrpc": "2.0",
    "technique":"importdescriptors",
    "params":{
        "requests":[{
        "desc":"pkh(cSQPHDBwXGjVzWRqAHm6zfvQhaTuj1f2bFH58h55ghbjtFwvmeXR)",
        "active": false,
        "range": 20,
        "next_index": 0,
        "timestamp": "now", 
        "internal": false,
        "label": "test_multisig_wallet"
        }]
    }
}'

Error…
{"consequence":null,"error":{"code":-18,"message":"Requested pockets doesn't exist or is just not loaded"},"id":null}

How can I import descriptors right into a pockets so the pockets has a sequence of addresses?

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles