Open antazoey opened 1 year ago
One could implement a ProviderAPI using Etherscan's Geth/Parity proxy API: https://docs.etherscan.io/api-endpoints/geth-parity-proxy.
ProviderAPI
This is a good opportunity for a contributor to create a ProviderAPI implementation without having to make a whole new plugin!
Just an idea / psuedo-python (missing tons of things - this code wont work at all, just for demo, <3)
(ape_etherscan/provider.py)
from ape.api import ProviderAPI, BlockAPI class EtherscanProvider(ProviderAPI): client_factory @cached_property def client(self) -> ProxyClient: ... def get_block(self, number): response = self.client.get_block(number) return BlockAPI.parse_obj(response)
Include links to any open issues that must be resolved before this feature can be implemented.
Overview
One could implement a
ProviderAPI
using Etherscan's Geth/Parity proxy API: https://docs.etherscan.io/api-endpoints/geth-parity-proxy.This is a good opportunity for a contributor to create a
ProviderAPI
implementation without having to make a whole new plugin!Specification
Just an idea / psuedo-python (missing tons of things - this code wont work at all, just for demo, <3)
(ape_etherscan/provider.py)
Dependencies
Include links to any open issues that must be resolved before this feature can be implemented.