bitcoin-cli help lockunspent RPC example shows:
0As a JSON-RPC call
1> curl --user myusername --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "lockunspent", "params": [false, "[{\"txid\":\"a08e6907dbbd3d809776dbfc5d82e371b764ed838b5655e72f463568df1aadf0\",\"vout\":1}]"]}' -H 'content-type: text/plain;' http://127.0.0.1:8332/
Including quotes around the transactions argument. Using the RPC in this way fails:
0curl --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "lockunspent", "params": [false, "[{\"txid\":\"6f244af8e2162138369fc736a673f85ead59ad88fb5a1edd6e03f81b33c537b0\",\"vout\":1}]"]}' -H 'content-type: text/plain;' http://127.0.0.1:18443/wallet/locktest
1
2{"result":null,"error":{"code":-3,"message":"Expected type array, got string"},"id":"curltest"}
This change corrects the documentation to remove the additional quotes so the example works as intended:
0curl --data-binary '{"jsonrpc": "1.0", "id": "curltest", "method": "lockunspent", "params": [false, [{"txid":"6f244af8e2162138369fc736a673f85ead59ad88fb5a1edd6e03f81b33c537b0","vout":0}]]}' -H 'content-type: text/plain;' http://127.0.0.1:18443/wallet/locktest
1
2{"result":true,"error":null,"id":"curltest"}