Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [json-rpc]

json-formatted remote procedure calls to communicate with ethereum clients

184 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
9 votes
2 answers
388 views

Receive deployed contract address by transaction hash with JSON-RPC request

I want to receive deployed contract address by transaction hash. Transcation example - 0x996a683acd59a2ad17461f76ce0f387a89a5ac257ec5d667556219c6acc7f45a. As you can see this contract was deployed by ...
Dmytro Zarezenko's user avatar
6 votes
0 answers
1k views

Why does Ethereum use JSON-RPC and not gRPC?

I am fairly new to networking protocols especially JSON-RPC and gRPC as they are not nearly as common in web development as REST. I was reading around and seems like gRPC generally performs better. So ...
RhinoBomb's user avatar
  • 161
5 votes
0 answers
61 views

Why does clef not implement ethereum's JSON-RPC

Assuming that the RPC standard still matches what is to be found today on the ethereum wiki, I was rather surprised to learn that the method calls provided by clef do not match the signer methods in ...
lash's user avatar
  • 685
5 votes
1 answer
1k views

eth_getTransactionReceipt returns null only sometimes and only on my node, tx is successfully mined in

I'm having this strange problem and it may be related to the way my node is configured. I'm making calls to both infura and my own nodes like so: {'id': 123, 'jsonrpc': '2.0', 'method': '...
LampShade's user avatar
  • 640
5 votes
1 answer
551 views

Accessing custom JavaScript functions via RPC API on Geth

Geth allows me to define & load my own custom JavaScript functions with --preload flag or require() on Geth console. But is there way to access my functions via RPC interface? Like : curl -H "...
Kerem atam's user avatar
4 votes
0 answers
3k views

Getting Json file from remix

I have been deploying contracts on rinkeby but we are almost done to go to mainnet. I have been comparing deployments with truffle and remix and there is a huge difference in gas uses, so I would ...
Gustavo Alvarez's user avatar
4 votes
0 answers
512 views

Is it possible to see the event log when using eth_call?

I want to perform a transaction locally (with the call method in web3 which perform a eth_call RPC call). It returns only the return value of the function called and I want to see the event log. I ...
Harold's user avatar
  • 362
4 votes
1 answer
5k views

UTC/json wallet file: deleted -> recovered -> corrupted. 0.1 ETH REWARD

--EDIT-- I have advanced in my research. The UTC/JSON file in question is a 491 byte file. There are 256 random characters in the file with each 16 possible characters. Like a 256-number long ...
BuckField's user avatar
4 votes
0 answers
380 views

Error: Transaction not confirmed for sendTransaction at rpc connection through http

I am trying to send a transaction to a contract deployed on the testnet. I run the geth HTTP JSON-RPC, with unlock option and the necessary apis accessible. When I exec the web3.eth....
macordu's user avatar
  • 61
4 votes
1 answer
200 views

Send json rpc request in Long connection

How can i send rpc request in long connection. Since the default rpc request using the short connection. When i send many requests together, the geth will break down with to many open file error, ...
rong jialei's user avatar
3 votes
3 answers
773 views

How to view the amount of storage a contract uses?

Is it possible to view the amount of storage a smart contract uses from an existing tool? Or if not is it possible to determine it by making json rpc calls? There are a few similar questions such as ...
MShakeG's user avatar
  • 1,693
3 votes
2 answers
5k views

Get full transaction list of an ethereum address using JSON-RPC

I'm currently developing a Java application which communicates with Geth using JSON-RPC. I managed to implement something like @rustyx suggested on this thread using an HTTP connection, but it's too ...
Mattia Monari's user avatar
3 votes
2 answers
3k views

Fetch ERC20 Token Balance for given address using Web3 Python

I’m desperately looking for a method that allows me to retrieve all token owned by a wallet using python. I should insert the wallet address as I put and the code should return the list of the token ...
GKM__'s user avatar
  • 31
3 votes
1 answer
612 views

Getting the latest eth_call result from a cluster of nodes

What's the best way to know the block number associated with the result of an eth_call? Assume I have several nodes that i'm running and i'm making calls to all of them (for redundancy). My goal is ...
LampShade's user avatar
  • 640
3 votes
0 answers
646 views

eth.getTransaction returning null? Troubleshooting steps

Why am I getting null trying to query ANY transaction id? Any ideas to troubleshoot? Running in light mode. I can query last block number. I can query balances of addresses without issue. eth....
Kyle Anderson's user avatar
3 votes
1 answer
2k views

Subscribe to events usign geth websocket

I'm trying to subscribe to geth using the websocket api. First step was to start geth: geth --ws --wsport=8456 --wsorigins="*" --fast --cache=512 --rpcport=8455 --rpc --rpcapi="personal,eth,network" ...
MichaelRazum's user avatar
3 votes
0 answers
312 views

Parity RPC eth_newFilter not returning pending events

I'm trying to create a listener for new pending TXs on the network using Parity RPC's eth_newFilter method. I'm sending the request using the following parameters, expecting to get pending ...
Achia's user avatar
  • 161
3 votes
0 answers
548 views

JSON RPC transfer of ERC20 Tokens with Parity

How can I use Parity with JSON RPC to send and receive ERC20 tokens?
JZ.'s user avatar
  • 153
3 votes
0 answers
965 views

How to run a testnet json rpc server?

I recently tried getting back into developing on Ethereum and it seems that everything about my setup has changed in the last half a year. I used to just be able to download a wallet from https://...
ThePiachu's user avatar
  • 562
3 votes
0 answers
242 views

c++ ethereum could not open wallet

Created 3 accounts as follows: $ eth account new Couldn't open wallet. Does it exist? Enter a passphrase with which to secure this account: Please confirm the passphrase by entering it again: ...
S.Bhaskar's user avatar
  • 101
3 votes
0 answers
369 views

Send JSON RPC request in BATCH

Is there any way i can send rpc request in batch way using pyethapp? If exists, whether it can help to increase the request efficiency? Thanks a lot.
rong jialei's user avatar
3 votes
1 answer
2k views

Encode method signature and parameters using Go-Ethereum

Is there any way to use the Go-Ethereum library to get the string I have to send to JSON RPC to call a contract method. I mean, Go-Ethereum comes with a CLI, so there must be some built-in functions ...
MethDamon's user avatar
  • 803
2 votes
0 answers
22 views
+50

How to sign Ethereum message in C#

I`m trying to convert this code to c# const message = response.data.message; const jsonProvider = new ethers.providers.JsonRpcProvider(RPC_URL) const ethersSigner = new ethers.Wallet(privatekey, ...
Jānis Kļaviņš's user avatar
2 votes
0 answers
416 views

Error HH604: Error running JSON-RPC server: Connect Timeout Error

I'm facing an error while running the command "yarn hardhat node" ERROR: Error HH604: Error running JSON-RPC server: Connect Timeout Error For more info go to https://hardhat.org/HH604 or ...
PsychoPunk_Sage's user avatar
2 votes
0 answers
130 views

How to query the ethereum network to get Validator status, balance and validator reward history

Is there a way to query the ethereum network with a json rpc call to get the current balance, the status and the reward history of a validator? thanks very much!
mazi's user avatar
  • 21
2 votes
0 answers
82 views

eth_getProof for event logs?

Problem Brief Hi, I've been looking for ways to prove to a light client that a log did get emitted on ethereum. I stumbled upon the eth_getProof RPC, but it's for getting the merkle proof for account ...
Patrick's user avatar
  • 21
2 votes
0 answers
136 views

EVM RPC Test Suite to test proper implementation of JSON-RPC Specifications

I'm looking for an existing and still supported EVM RPC Test Suite to test if a custom RPC implementation is in line with the official JSON-RPC Specifications. I'm not looking to build my own suite, I ...
gluneau's user avatar
  • 21
2 votes
0 answers
188 views

Hardhat and Ethers.js Mint Slow with 25 RPC Requests Per Minted Token

We've successfully deployed an ERC-721 contract to testnet and mainnet BSC, but when calling our Mint function, followed by a contract.tokenURI(tokenId) call, the request times are quite long, and we ...
Blue Waters's user avatar
2 votes
1 answer
698 views

Geth Reverse Proxy "Invalid Host Specified"

I am getting 403 "invalid host specified" Running geth this way: docker run --rm -p 8547:8547 -p 30303:30303 --name=geth -dti -v /data/geth:/data ethereum-node --datadir=/data --http --http....
Mohamed Mansour's user avatar
2 votes
0 answers
486 views

how to decode JSON-RPC BSC output result

How to decode the JSON-RPC result of bsc-dataseed1.defibit.io? these are two examples of output: { "jsonrpc": "2.0", "id": 1, "result": { "...
giacomosilli's user avatar
2 votes
1 answer
316 views

Remix IDE Desktop + Geth node as test network

I'm trying to connect the Remix Desktop client to my local Geth node. as usual i added: geth --rpc --rpccorsdomain https://remix.ethereum.org while starting up the node. This obviously only works ...
Henk van der Sloot's user avatar
2 votes
0 answers
101 views

Calculated blockhash of PoA block mismatches with actual blockhash returned by RPC

I set up a Demo PoA chain using Parity Etheruem. I sent some transactions to it and it started producing blocks. A block on my demo PoA chain was generated with block hash ...
Soham Zemse's user avatar
  • 2,041
2 votes
0 answers
60 views

Unable to send large transactions on ethereum private chain

I have a small contract pragma solidity ^0.4.17; contract A10test{ mapping(uint=>string) public data; uint public revisionNo=0; function setdata(string _data) public { data[revisionNo] = ...
ahmed's user avatar
  • 21
2 votes
0 answers
151 views

parity json RPC eth_getBalance timeout on light mode

I have timeout problem with eth_getBalance on light mode enable on parity json-rpc. I have no problem with light mode disabled. Here my command on parity parity --chain ropsten --jsonrpc-apis all -...
Billy Adelphia's user avatar
2 votes
0 answers
53 views

JSON RPC Data Structure

Is there a data structure that contains all the JSON RPC endpoints? Not the wiki, but a JSON or SQL file that I can use to programatically iterate over all the endpoints to generate code.
Count Zero's user avatar
2 votes
0 answers
613 views

eth_sendRawTransaction parameter formatting

we have a JSON RPC method eth_sendRawTransaction as specified here. how is the raw transaction data formatted? I can't seem to find this anywhere. I'm guessing it consists of a signed transaction ...
noot's user avatar
  • 96
2 votes
0 answers
2k views

gRPC vs JSON-RPC API?

gRPC is modern high-performance RPC framework. Using gRPC is certainly than the use of JSON RPC for communication between geth nodes and the clients such as web3. Is gRPC is part of the Ethereum ...
Nathan Aw's user avatar
  • 1,954
2 votes
0 answers
78 views

Programmatically unlock certain accounts with Parity?

Using geth it is easy to send transactions from multiple accounts but I do not know how to do this with Parity. I do not want all accounts unlocked. I do not want any account unlocked when it is not ...
stone.212's user avatar
  • 1,994
2 votes
0 answers
393 views

Parity syncing status for smart contract events with warp

So I'm trying to find the fastest way to fully sync a parity node in order to get all smart contract events, not just account states. The problem I've found is that when parity has warp syncing ...
cheeseandcereal's user avatar
2 votes
0 answers
1k views

public facing full node with nginx

I am running a node on a Hosted root server, and will soon be synced, but I am not sure how I can now use this node to mine with my local Unix miner. What I have Xenon CPU with 32GB RAM 1 Terrabyte ...
Adesso's user avatar
  • 133
2 votes
0 answers
136 views

Why does my JSON-RPC request never complete?

I've set up geth to run in a Docker container with the following command (yes, I realize it's wide open to the world): docker run -it -p 127.0.0.1:8545:8545 -p 30303:30303 -v /data/ethereum:/root/....
EvilJordan's user avatar
2 votes
0 answers
719 views

How to check token transactions with geth

I'm new to smart contracts, my apologies if this is a wrong approach. I want to monitor incoming (confirmed, not caring about pending) token transactions to my wallet (using geth). I found out how to ...
jmd42's user avatar
  • 21
2 votes
1 answer
152 views

How to best react to geth events from a server app?

I have a geth node running on a server. I want my Ruby app to take action every time a contract emits an event. The app cannot miss any events. One way would be to poll for transactions to that ...
will_durant's user avatar
  • 1,154
2 votes
3 answers
1k views

Error: Invalid number of arguments to Solidity function | when trying to pass in parameter from App.js to Solidity

I am trying to call a function in my Solidity file (Coder.sol), while passing through a parameter from my App.js file. My function in my App.js file looks like this: handleStartRequirement: function(...
nigam's user avatar
  • 21
2 votes
0 answers
477 views

Rejected/Removed Transactions how and when can they happen?

Background: I am writing a blockchain viewer/exporter that requests, via Parity JSONRPC, blockchain information and then stores this info off chain. Currently I am trying to accumulate all pending ...
dareniott's user avatar
  • 161
2 votes
1 answer
173 views

Can't access swarm 8500 port from outside

I run local swarm node, so I can access it from localhost:8500. RPC request works fine locally. But when I try to send requests to swarm rpc from another server, it is not accessible. I see port 8500 ...
gelbplaneten's user avatar
2 votes
1 answer
684 views

Ethereum Contract ABI - Encoding for functions with no arguments

I am using argument encoding from this page (https://github.com/ethereum/wiki/wiki/Ethereum-Contract-ABI) to build data field for offline signing. I am using eth.sendRawTransaction to call a function ...
trivikramak's user avatar
2 votes
0 answers
394 views

Detecting exceptions in transactions

I've seen some suggestions from the community about managing throws in transactions using some different methods: Don't use a throw - use events for error checking Check using ...
bozzle's user avatar
  • 896
2 votes
1 answer
844 views

Fetch all tokens (ERC20, ERC721, ERC1155) owned by a specified address

I am building an app and I need to fetch all tokens (ERC20, ERC721, ERC1155) owned by a specified address. I've seen some services for fetching ERC20 (ETHplorer) or ERC721 (Etherscan, OpenSea) tokens ...
microHoffman's user avatar
1 vote
0 answers
4 views

SSZ serialization and JsonRPC usage

As I understand, the SSZ was introduced in Ethereum 2.0 for the serialization of data in different contexts. The previously used serialization is RLP and it is used when making a JSON-RPC request to ...
Mathieu Dutour Sikiric's user avatar