furqansiddiqui / erc20-php

Interact with Ethereum ERC20 Tokens
MIT License
163 stars 96 forks source link

Possible to use Infura.io as Ethereum node? #6

Closed dformdotdk closed 6 years ago

dformdotdk commented 6 years ago

Hi

I have a Ethereum node running in light mode. When I was developing on Rinkeby, everything was running fine, but as soon as I changed to mainnet, I began to have issues with "no suitable peers available".

I've been looking at Infura.io, but I can't figure out how to send a transaction using their service with your code.

I have tried using my Infura endpoint - e.g. https://mainnet.infura.io/v3/MYAPITOKEN And If I change $this->ssl = false to true in EthereumRPC.php in line 56 it seems like it's trying to connect but get an error 401 Unauthorized

Have you tried using Infura ?

furqansiddiqui commented 6 years ago

I am not sure about Infura service, haven't checked them out but this package is specifically designed to work with Ethereum server via RPC and ERC20 package relies on EthereumRPC because all base contract API handling functionality are in EthereumRPC package and ERC20 package is just an interface for EthereumRPC package.