I am trying to send a signed transaction using web3.eth.sendSignedTransaction(). Everything seems to be working ok for my other web3 methods, but I am having trouble setting the gas for this. When calling it I get the message:
"Error: Returned error: Transaction cost exceeds current gas limit. Limit: 5000, got: 47100. Try decreasing supplied gas."
So I try setting it to 5000 then get the following error:
"Error: Returned error: Transaction gas is too low. There is not enough gas to cover minimal cost of the transaction (minimal: 53400, got: 5000). Try increasing supplied gas."
What could I doing wrong here?