createmultisig
Creates a multi-signature address with n signature of m keys required.
It returns a json object with the address and redeemScript.
Method: POST
Copy https://btc-testnet.nownodes.io
Example body (raw )
Copy {
"jsonrpc" : "1.0" ,
"id" : "curltest" ,
"method" : "createmultisig" ,
"params" : [
2 ,
"[\"03789ed0bb717d88f7d321a368d905e7430207ebbd82bd342cf11ae157a7ace5fd\",\"03dbc6764b8884a92e871274b87583e6d5c2a58819473e17e107ef3f6aa5a61626\"]"
]
}
Example response: 200
Copy {
"result" : null ,
"error" : {
"code" : -3 ,
"message" : "Wrong type passed:\n{\n \"Position 2 (keys)\": \"JSON value of type string is not of expected type array\"\n}"
} ,
"id" : "curltest"
}
getindexinfo
Returns the status of one or all available indices currently running in the node.
Method: POST
Copy https://btc-testnet.nownodes.io
Example body (raw )
Copy {
"jsonrpc" : "1.0" ,
"id" : "curltest" ,
"method" : "getindexinfo" ,
"params" : []
}
Example response: 200
Copy {
"result" : {
"txindex" : {
"synced" : true ,
"best_block_height" : 2585862
}
} ,
"error" : null ,
"id" : "curltest"
}
signmessagewithprivkey
Sign a message with the private key of an address
Method: POST
Copy https://btc-testnet.nownodes.io
Example body (raw )
Copy {
"jsonrpc" : "1.0" ,
"id" : "curltest" ,
"method" : "signmessagewithprivkey" ,
"params" : [
"privkey" ,
"my message"
]
}
Example response: 200
Copy {
"result" : null ,
"error" : {
"code" : -5 ,
"message" : "Invalid private key"
} ,
"id" : "curltest"
}
validateaddress
Return information about the given bitcoin address.
Method: POST
Copy https://btc-testnet.nownodes.io
Example body (raw )
Copy {
"jsonrpc" : "1.0" ,
"id" : "curltest" ,
"method" : "validateaddress" ,
"params" : [
"bc1q09vm5lfy0j5reeulh4x5752q25uqqvz34hufdl"
]
}
Example response: 200
Copy {
"result" : {
"isvalid" : false ,
"error_locations" : [] ,
"error" : "Invalid or unsupported Segwit (Bech32) or Base58 encoding."
} ,
"error" : null ,
"id" : "curltest"
}
verifymessage
Verify a signed message
Method: POST
Copy https://btc-testnet.nownodes.io
Example body (raw )
Copy {
"jsonrpc" : "1.0" ,
"id" : "curltest" ,
"method" : "verifymessage" ,
"params" : [
"1D1ZrZNe3JUo7ZycKEYQQiQAWd9y54F4XX" ,
"signature" ,
"my message"
]
}
Example response: 200
Copy {
"result" : null ,
"error" : {
"code" : -5 ,
"message" : "Invalid address"
} ,
"id" : "curltest"
}
Last updated 8 months ago