9

I would like to create my own wallet system but I don't have enough funds to run my own node yet. If I would like to borrow a public node to process the account creation, retrieve a public key and private key, transfer token, etc.

Is there a suggestion for a public node? can I assume it works the same in binance?

Thank you.

6 Answers 6

9

Please see Ethereum Nodes for available options.

https://ethereumnodes.com/

Multiple options might be cheaper than Infura. For example, CloudFlare is free. However they offer limited history and might be slower.

You can also run your own node for ~$75/month.

2
  • 1
    when you say run your own node for ~$75/month is running locally or in the cloud like Amazon and GCP? assuming $75 is USD 75? I use GCP Cloud Run at my workplace, the auto scalability is really awesome, but the same time I'm still learning how the Ethereum backend works so probably starting with the Free plan of Infura is not a bad idea.
    – nobsoph
    Jul 4, 2021 at 23:46
  • $75/month for a decent dedicated Hetzner server. It is better to have a cheap dedicated server with fast directly attached IO than a cloud VM with slow Elastic Block Storage or similar. Dedicated servers are faster, cheaper, better for runningnodes. Jul 5, 2021 at 7:44
2

There are dozens of free and public RPC nodes:

You can also find some node providers, that have a free-tier plan:

Also, you can look at blockchain documentation, many of them have also public RPC nodes, e.g.

above links may not work in a year, use google to search for RPC nodes.

The problem here is not to find out free RPC nodes, but to consume them:

  • server is down
  • request time-out
  • throttling
  • reaching the usage limits per day, month, etc...
  • not in sync (the height is far behind the current block)
  • stuck on syncing

You can solve those issues by having something like a pool of URLs (providers) from different sources, and before you query the blockchain, you perform some kind of discovery process, to find out dead URLs, compare the block numbers, the sync status, etc. Then using some round-robin technique you pick a provider, perform a request, and monitor the request - latency, throttling, or timeouts. On any Network Error - mark the provider as down, pick another provider, and retry the request. Ideally, all of this would be supported in your SDK of choice.


I'm working on a 0xweb library, and here is an example of how I'm using the Web3Client.ts class which wraps web3js and the pool of providers:

In config.yml I have the URLs listed per chain:

bsc:
    endpoints:
      - url: 'https://bscrpc.com'
      - url: 'https://bsc-dataseed.binance.org/'
      - url: 'https://bsc-dataseed1.defibit.io/'
        rateLimit: '100/1s;5000/1m'
      - url: 'wss://bsc-ws-node.nariox.org:443'

import { Config } from '@dequanto/Config'
import { Web3ClientFactory } from '@dequanto/clients/Web3ClientFactory'

await Config.fetch();
let client = Web3ClientFactory.get('bsc')
let block = await client.getBlock('latest');
let transactions = await client.getTransactions(block.transactions);
console.log(`Latest block`, block, `Transactions`, transactions);
0

Is there a suggestion for a public node?

Infura

Infura is a node api/gateway that is talked about very often (although I haven't used it myself yet so I can't give you my own experience). They also offer an IPFS querying service.

Ethereum Provider API

However, often times dapp developers don't interact with a node directly. Instead they interact with the Ethereum provider API.

When a website fetches a resource (some URL) in a browser, the web developer is not expected to find a DNS service that will convert those URLs to IP addresses. Instead the browser will have a built-in mechanism for resolving those IP addresses.

Simlarly, when a website needs to communicate with a blockchain, the dapp developer is not expected to find a node that will do this for them. Instead the browser will offer a built-in provider to fulfil/facilitate this communication.

This is what the Ethereum Provider API is. Similar to other web APIs, the Ethereum Provider API allows you to communicate with blockchains where the browser will do the hard work of finding a node to communicate with. Often times the browser user will also have control over what node they want to use, should they so wish.

Unfortunately, not many browsers implement this API. I believe (although I might be wrong) that the Brave browser natively supports this API along with ".eth" domains. For all other browsers, users will be required to install an extension which implements (injects) this API. The most common extension at the moment is MetaMask and is used by many (if not the majority) of dapp developers and users.

The MetaMask website offers great documentation for the Ethereum API and also offers an NPM package for detecting/retrieving this provider object. I believe none of this is specific to MetaMask but should work for all ethereum providers (including browsers that support it natively).

The Ethereum API offers many services including, but not limited to, sending transactions, calling contract functions, retrieving wallet addresses from the user, and signing transactions securely. You should check out this getting started guide.


can I assume it works the same in binance?

Unfortunately, I'm not sure if I understand what you mean by this question.

Are you referring to the Binance Smart Chain? If so, the ethereum API works with all EVM-compatible chains including the Binance Smart Chain. There are also methods for registering a chain and switching chain so that the user does not need to take these steps manually.

Or are you referring to integrating with the Binance app? If so, cryptocurrencies should be transferable between the Binance app and any dapp as long as you have a valid wallet set up.

0

For free you have LinkPool.

Mainnet RPC: https://main-light.eth.linkpool.io Websocket: wss://main-light.eth.linkpool.io/ws

Rinkeby RPC: https://rinkeby-light.eth.linkpool.io Websocket: wss://rinkeby-light.eth.linkpool.io/ws

Goerli RPC: https://goerli-light.eth.linkpool.io Websocket: wss://goerli-light.eth.linkpool.io/ws

Test if they are still working at time of reading in interactive node shell after installing web3 with npm.

> const Web3 = require('web3')
undefined
> var web3 = new Web3('wss://main-light.eth.linkpool.io/ws')
undefined
> web3.eth.getBlockNumber().then(console.log)
Promise {
  <pending>,
  [Symbol(async_id_symbol)]: 1361,
  [Symbol(trigger_async_id_symbol)]: 1359,
  [Symbol(destroyed)]: { destroyed: false }
}
> 14122891
0

Did you know that http://therpc.farm offers a whopping 10 Million API calls under its FREE account? And guess what - these calls can include archive, debug, AND trace!

0

Another alternative for free less bloated public Ethereum and other EVM RPC endpoints can be found at https://www.noderpc.xyz/:

Ethereum mainnet: https://www.noderpc.xyz/rpc-mainnet/public

Polygon mainnet: https://www.noderpc.xyz/rpc-polygon/public

Ethereum Goerli testnet: https://www.noderpc.xyz/rpc-goerli/public

Ethereum Sepolia testnet: https://www.noderpc.xyz/rpc-sepolia/public

Polygon Mumbai testnet: https://www.noderpc.xyz/rpc-mumbai/public

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.