eth_submitWork
eth_submitWork RPC Method
Parameters:
nonce - string - The nonce found
hash - string - The header's pow-hash
digest - string - The mix digest
Returns:
result - It returns true if the provided solution is valid otherwise false
Code Examples:
var myHeaders = new Headers();
myHeaders.append("Content-Type", "application/json");
var raw = JSON.stringify({
"jsonrpc": "2.0",
"method": "eth_submitWork",
"params": [
"0x0000000000000001",
"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
"0xD1FE5700000000000000000000000000D1FE5700000000000000000000000000"
],
"id": 1
});
var requestOptions = {
method: 'POST',
headers: myHeaders,
body: raw,
redirect: 'follow'
};
fetch("https://api.ebs.ezat.io/core/api/v1.0/rpc/ethererum/mainnet?x-api-key-id=API-KEY-ID&x-api-key=API-KEY", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));
Last updated