Is there any websocket ethereum provider? Except etherscan one. Maybe there are paid wss subscriptions?
8 Answers
Use Infura.io to connect to different blockchains. You will need an account and project id.
Steps to create an Infura.io Project and remarks
1) Open Infura.io page and sign up for an account. On your dashboard, you now can create a new project.
2) Change the endpoint to Kovan and directly copy the endpoint URL for connecting to blockchain.
3) The web socket URL is slightly different from the http interface — the correct pattern for web services is:
wss://kovan.infura.io/ws/v3/{your-infura-project-id}
Please, be aware that your personal API key to use Infura should be secret. So, don’t give it away to anyone else.
wss://mainnet.infura.io/ws
wss://ropsten.infura.io/ws
wss://rinkeby.infura.io/ws
-
don't see any info about wss in their doc, am I reaching the wrong documentation? Or how do I access wss one?– AlexeyMay 25, 2018 at 3:18
-
Nothing special to access:
var web3 = new Web3(Web3.givenProvider || 'wss://mainnet.infura.io/_ws');
. You can track some of the websocket talk on their GitHub. May 25, 2018 at 3:29 -
Is it somekind of reliable/stable working service? cuz i don't see any responses from wss://mainnet.infura.io/ws– AlexeyMay 25, 2018 at 3:31
-
Isn't there any ready to use wss, which isn't in beta/is fully supported?– AlexeyMay 25, 2018 at 3:47
-
Infura websocket support is now documented here.
From the intro:
Infura's websocket endpoint provides support for Pub/Sub API as well as JSON-RPC filter support.
-
1Hi @foba if you need to disclose something, please do so. meta.stackexchange.com/questions/57497/… You may have edited around 10 or more questions with this website. Thanks– eth ♦Jul 13, 2019 at 8:06
-
1this is really awesome. normally I use infura but sometimes infura doesn't response on websocket. Sep 24, 2019 at 21:03
-
@kodmanyagha Yeah! Did you try it out? We have a nice tool as well to make listening for blockchain or market data simple: github.com/web3data/web3data-js– fobaNov 6, 2019 at 22:04
I'm using
const web3 = new Web3(new Web3.providers.WebsocketProvider("wss://mainnet.infura.io/ws"))
the best one for me is Fastlynode, they provide private node but for the moment they only provide private node for binance smart chain, you can use this discount code FASTLY20 to get 20% OFF