如何使用web3py获取整个以太坊网络的所有交易数据
How to get all transaction data from the entire Ethereum network using web3py
我正在尝试 运行 对加密货币(例如比特币、以太坊)数据进行一些分析,但找不到数据源。比如我想收集以太坊的输入地址、输出地址、交易时间、交易金额等交易数据
我发现我可以使用 web3py 访问以太坊数据,但是是否有可能获取最近在整个以太坊网络中进行的“所有”交易的数据,而不仅仅是连接到我自己钱包的交易(地址)?例如,我想获取今天发生的所有以太坊交易的数据。
此外,我是否必须拥有自己的以太坊钱包(地址)才能使用 web3py 访问他们的数据?我想知道我是否需要一个特定的地址作为起点,或者我可以 抓取 数据而不创建钱包。
谢谢。
For example, I'd like to collect transaction data such as input address, output address, transaction time, transaction amount, etc. for Ethereum.
You can iterate over all blocks and transactions using web3.eth.get_block call。但是,您需要自己解析交易内容。
要访问所有数据,建议您run your own node为JSON-RPC 调用设置最大网络带宽。
Also, do I must have my own Ethereum wallet(address) in order to access their data with web3py?
Address is just a derived from a random number and you do not need to generate one.
我正在尝试 运行 对加密货币(例如比特币、以太坊)数据进行一些分析,但找不到数据源。比如我想收集以太坊的输入地址、输出地址、交易时间、交易金额等交易数据
我发现我可以使用 web3py 访问以太坊数据,但是是否有可能获取最近在整个以太坊网络中进行的“所有”交易的数据,而不仅仅是连接到我自己钱包的交易(地址)?例如,我想获取今天发生的所有以太坊交易的数据。
此外,我是否必须拥有自己的以太坊钱包(地址)才能使用 web3py 访问他们的数据?我想知道我是否需要一个特定的地址作为起点,或者我可以 抓取 数据而不创建钱包。
谢谢。
For example, I'd like to collect transaction data such as input address, output address, transaction time, transaction amount, etc. for Ethereum.
You can iterate over all blocks and transactions using web3.eth.get_block call。但是,您需要自己解析交易内容。
要访问所有数据,建议您run your own node为JSON-RPC 调用设置最大网络带宽。
Also, do I must have my own Ethereum wallet(address) in order to access their data with web3py?
Address is just a derived from a random number and you do not need to generate one.