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

Questions tagged [rpc]

The tag has no usage guidance.

79 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
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
3 votes
0 answers
644 views

How to work with foundry anvil custom rpc methods?

I'm running an anvil fork node on localhost:8545, and I create a provider by ethers: const provider = new ethers.JsonRpcProvider('http://localhost:8545') I tried some common rpc methods like: ...
CT95's user avatar
  • 406
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
0 answers
245 views

GETH gets out of sync from time to time

GETH tooks 6 days to sync, after that it will get out of sync from time to time. (PC is running with SSD, never shutdown, and network availability is 100% with 500mbps connection). May I know how ...
s k's user avatar
  • 886
3 votes
0 answers
339 views

Invalid JSON RPC response: {"id":6,"jsonrpc":"2.0"}

I'm following this tutorial https://medium.com/@ConsenSys/a-101-noob-intro-to-programming-smart-contracts-on-ethereum-695d15c1dab4 I have downloaded the code from github repo. I'm using ganache as ...
M. Dhaouadi's user avatar
3 votes
0 answers
80 views

What RPC APIs are safe to expose?

What RPC APIs are safe to expose (make public, so accessible by anyone), and what are the unsafe ones, and why? I've read: are there "public" ethereum nodes? or any recommendations on ...
Константин Ван's user avatar
3 votes
2 answers
495 views

Deploying to rinkeby doesn't work

It seems I have a bit of trouble deploying a contract to testnet through infura this is my code: var Web3 = require('web3'); var web3 = new Web3(new Web3.providers.HttpProvider('https://rinkeby....
Narcis Ciobotariu's user avatar
2 votes
0 answers
82 views

Creating new accounts using `web3`

In the new version of web3.py, the personal.newAccount functionality has been retained only for the geth client. What is the right cross-client approach to creating new accounts? See v5 migration ...
Peteris's user avatar
  • 1,005
2 votes
2 answers
259 views

Is it possible to connect to public Ethereum like blockchain with Remix to deploy and view contracts?

I've tried to do so by specifying the web3 provider and the 8584 port but it gets stuck on every try. Is this possible? if so, is there another solution for that need?
user3652172's user avatar
2 votes
1 answer
210 views

How do i create account remotely?

I have two servers, one for eth-node, one for web api and user db. I want to send request to create account from web server to eth server, but i see it can be created by running command like geth ...
TomSawyer's user avatar
  • 123
2 votes
0 answers
452 views

"RPC error, your account is locked" when I try to deploy the last version of parity-bridge

I have already success to deploy the last version of parity-bridge (last month), but today i have pull the last version of parity-bridge. I have that on my terminal : env RUST_LOG=info parity-bridge-...
yohan's user avatar
  • 65
2 votes
0 answers
222 views

What does "RlpInvalidIndirection" error mean?

I run my own Parity node for Ropsten network. I am sending raw transactions to the node with "eth_sendRawTransaction" api, and sometimes it returns {-32602, "Invalid RLP.", "RlpInvalidIndirection"} ...
santony's user avatar
  • 135
2 votes
0 answers
586 views

Geth connection rpc vs ws

where I can find same articles or materials to understand differences between rpc and ws connection over geth. From my point of view rpc is part of a websocket connection, so why I have to use ws ...
underdog's user avatar
  • 1,190
1 vote
0 answers
11 views

What is the semantics of block labels in `eth_getNewFilter`?

I am wondering how exactly fromBlock and toBlock in eth_getNewFilter are supposed to work. The documentation is a little confusing. This page (which seems to be official) says that these parameters ...
fjarri's user avatar
  • 111
1 vote
0 answers
136 views

($10 ETH Bounty) Base Chain - My submitted transaction is always 2 blocks behind the current block

For some reason whenever I submit my transaction it is always included 2 or more blocks behind the current block. There's an address that always has their transaction included in the same block as the ...
shlx's user avatar
  • 31
1 vote
1 answer
48 views

Null keys when using `debug_storageRangeAt`

I'm currently trying to use the debug_storageRangeAt on a Hyperledger Besu RPC to extract the contract storage. For some contracts I get the expected response which is a list of keys and values: "...
Valentín Fernández's user avatar
1 vote
1 answer
81 views

How to add a NFT to metamask wallet with a RPC method

We have a way to add an ERC20 token to the metamask wallet from our dapps with a RPC method: const addTokenToMetamask = async () => { if (typeof window.ethereum !== "undefined") ...
Fernando López's user avatar
1 vote
1 answer
264 views

How can I use ethers.js to get streaming events via sockets instead of polling?

I try to use ethers.js events, but they seem to be polling constantly and eventually the RPC provider sends HTTP code 429: Too Many Requests. I understand that I can use non-standard APIs of providers,...
Gregory Magarshak's user avatar
1 vote
0 answers
52 views

What kind of malicious activity could an RPC gateway inflict on the user?

Let's say, a third-party RPC gateway for an Ethereum-like networks decided to turn itself into a malicious one. Apart from the likes of selling users' data, what kind of malicious activity could it ...
Kyell's user avatar
  • 91
1 vote
1 answer
42 views

self-hosted solutions to get account balance

What are the most common solutions self hosted solutions to get the balance of an account with a python script? I know that there are RPC nodes or are there other solutions? Maybe solutions that use ...
RDude's user avatar
  • 11
1 vote
1 answer
291 views

increase the gas limit for read functions

hey guys this may be a broad question... I'm writing a smart contract that recursively builds an svg image given a seed number. the function that draws the image is a view function so it doesn't cost ...
Nolan Jannotta's user avatar
1 vote
1 answer
134 views

Is there a RPC API equivalent of fetching my Ethereum balance by using CURL in the cli?

Since metamask connects to a RPC server and passes in the eth address to make a api request. Is it possible to do the same functionality using CURL in the cli to do a basic balance inquiry of an ...
Patoshi パトシ's user avatar
1 vote
0 answers
138 views

How to recover from intermittent 'the resource eth_call is not available' during runtime?

When I call a contract function using a block_identifier from the past, I get error code -32002 the resource eth_call is not available in ~4/5 times when using a public RPC using Python web3. ~1/5 ...
decryptozoo's user avatar
1 vote
0 answers
40 views

Arbitrum: Mapping L2 blocks to L1 batches using RPCs

I'm looking for a way to programmatically map L2 blocks to their corresponding rollup batches in L1 using RPCs. Is there a way to do this, and if so, what would be the best approach? Any help or ...
Lucas Pecina's user avatar
1 vote
1 answer
125 views

Is it a requirement that RPC providers (Infura, Ankr, Pocket, etc) collect a wallet's IP address?

If you do not run your own node and must interface with Ethereum network through an RPC like Infura, is it a requirement they collect your IP address in order to route the response back to you? Of ...
MattOnChain's user avatar
1 vote
0 answers
54 views

Why the network request of web3 interaction through react or any other frontend framework or library is not showing in the network tab of browser?

All network request we make from browser is shows in the network tab , but the web3 request is not showing in the web browser. Web3 library uses network RPC to interact with the blockchain. The RPC is ...
Vivek Bhatti's user avatar
1 vote
1 answer
102 views

How does MetaMask populate its Infura enpoints securely?

As MetaMask uses Infura as one of its node providers, multiple endpoints have to be generated for that purpose. How does MetaMask manage to acquire that many endpoints? And how do they protect their ...
Hacan's user avatar
  • 11
1 vote
0 answers
250 views

RPC Runtime Errors With Metamask

Im trying to create a basic product list/buy/sell form locally. While trying to run a transaction on Metamask I get a console error with this stack: MetaMask - RPC Error: [ethjs-query] while ...
shrew-tea's user avatar
1 vote
0 answers
83 views

What is metamask waiting for when a transaction is pending?

I'm coding a custom RPC endpoint. When I make a transaction with metamask, I use the sendRawTransaction, I can pick up the transaction on the RPC and process it but metamask keep waiting on something ...
MadeInDreams's user avatar
  • 1,565
1 vote
0 answers
49 views

What changes to the RPC return data will appear due to London hard fork?

I recently upgraded my node software (OpenEthereum) to the London hard fork. As part of my testing, I noticed a new field from the eth_getTransactionReceipt called effectiveGasPrice. Simple enough... ...
Thomas Jay Rush's user avatar
1 vote
0 answers
379 views

Properly Exposing Geth RPC in 2020

With the default allowed ["net", "web3", "eth"], I want to expose Geth 1.9.21-stable RPC to another machine. In config.html I set HTTPVirtualHosts = ["*"]. The ...
Gaia's user avatar
  • 232
1 vote
0 answers
74 views

RPC command to list current nodes

I am using Parity and I want to see a list of the IP addresses of every node my node is talking to. I am sure I have done this before but I can't remember how. Please share the curl/RPC command to ...
stone.212's user avatar
  • 1,994
1 vote
1 answer
1k views

MetaMask - RPC Error: Error: WalletMiddleware - Invalid "from" address

I'm trying to create a simple Dapp (via tutorial) which would allow me to send Ether from sender to receiver (via a contract with an address that automatically approves the transaction). The truffle ...
Shaye's user avatar
  • 123
1 vote
0 answers
383 views

How to use 'geth attach' with Infura?

I have a project in Infura and the project ID is 6f...3a. I'm having problem to start geth attach process with Infura. I tried all protocols (http, https, ws and wss) but all failed. Did I miss ...
Zulhilmi Zainudin's user avatar
1 vote
0 answers
32 views

One rpc connection faster than another

I have four synced peer nodes running on two separate machines. Nodes 1-3 have been around since the beginning of the block chain and are all on one machine while Node 4 was just added around block ...
0TTT0's user avatar
  • 672
1 vote
1 answer
467 views

Is it possible to artificially delete a given block from local chain database without causing any problems?

Is it possible to artificially delete a given block from local chain database without causing any problems? for example, how could I delete the latest block from my local eth node, and resync newly ...
scorpio_lhl's user avatar
1 vote
0 answers
150 views

Handle nonce after RPC timeout

From time to time, I will be making some 5 ~ 10 tx/s on Ethereum via RPC interface. I have to handle the nonce manually because it cannot update fast enough. But I am facing issue below: From time ...
s k's user avatar
  • 886
1 vote
2 answers
1k views

How to get balances of all the accounts(~1000) in Geth node?

How can I get the balance of all the accounts in my Go Ethereum node? I have about 1000 accounts and it is too slow to use eth_getBalance to get balance for each address. Are there any ways to use ...
user avatar
1 vote
0 answers
1k views

Geth RPC send_transaction error -32000

How do you calculate how much gas to use in a send_transaction? Amount: 0x670479cb5385800, // (decimal: 463949500000000000 wei 0.4639495 eth) Gas price: 0x6ddd00 // (decimal: 7200000 wei) Gas: ...
mocode10's user avatar
  • 143
1 vote
0 answers
291 views

Cannot connect to the Web3 provider when rpccorsdomain is on

I am getting the message: Not possible to connect to the Web3 provider. Make sure the provider is running and a connection is open (via IPC or RPC). When I specify: --rpccorsdomain "http://...
DottoreM's user avatar
  • 191
1 vote
0 answers
248 views

Cannot see address on geth instance console in the dev network

I am trying to develop a ethereum private network & i am using a single dev node. I startup my local dev instance of geth using this command below. geth --mine --dev --rpc --rpccorsdomain="...
Sujal Mandal's user avatar
1 vote
0 answers
141 views

ETH Accounts per block

Correct me if Im wrong but from my understanding each block has a "stateRoot" property that point to status of the State tree at the time of mining. I also believe that tha state tree contais a list ...
Diego's user avatar
  • 317
1 vote
0 answers
219 views

Geth on ios and RPC protocol

I'm using Geth Objective-C API on ios and would like to start the node with RPC protocol enabled. Is it possible and if yes how?
elmattic's user avatar
  • 179
1 vote
0 answers
284 views

Parity RPC Mode Compatible with Geth RPC?

I have a program interfacing with geth. But now I have to move to a new server, and geth is taking too long to re-sync. If I install Parity, will the program that interfaces with localhost:8545 work ...
stone.212's user avatar
  • 1,994
0 votes
0 answers
44 views

How to access transaction data in Alastria networks?

I have read an article about a personal data leak on Alastria networks: https://medium.com/@4k-research/personal-data-leak-alastria-blockchain-ecosystem-9366544d1cd9. Following the article idea I have ...
jander_62's user avatar
0 votes
0 answers
22 views

Trying to setup Astar zkEVM Mainnet Permissionless RPC Node but failed

I am trying to setup Astar zkEVM Mainnet Permissionless RPC Node following these docs, but it's not working for me. Looks like the container zkevm-rpc is not functioning. curl -H "Content-Type: ...
Tapas Jana's user avatar
0 votes
0 answers
103 views

Methods allowed by RPCs providers for contracts Solidity Event listeners at etherjs

GM everyone. I'll appreciate any help to know how is the correct form of consume events in a backend listener of EVM solidity contracts, and if can share your favorite Rpcs Providers like infura,...
Gman's user avatar
  • 1
0 votes
0 answers
13 views

My Arbitrum Alchemy node is randomly returning -3 for block number

Basically I'm getting an error from my RPC node provider (Alchemy) where sometimes, when I query for the block_number I get the response -3. I don't quite understand why or if this is a rate limit ...
Rodrigo Pinheiro's user avatar
0 votes
0 answers
12 views

Nethermind Execution Client RPC multiplicity

when running a nethermind-prism node can you route provider communications and local processes through IPC but also allow external HTTP RPC access?
Max.Koeg's user avatar
0 votes
0 answers
8 views

Internal Rpc error when i call claim function on this my contract and i got payload error if use edge browsser instead of chrome to perform same task

My js code document.addEventListener("DOMContentLoaded", async () => { let web3; let accounts; const initWeb3 = async () => { try { // Use the appropriate provider ...
Hallenjay's user avatar