Interacting with Ethereum Network in Python using Web3.py : Part 3

How to find the balance of any address using Web3.py library

Abhijith Chandradas
Geek Culture

--

Web3.py is a python library which can be used to interact with Ethereum blockchain.
This is the third part of Web3.py tutorial, you can check the first and second parts below:

Photo by Zoltan Tasi on Unsplash

Connect to Ethereum Network

To access the Ethereum network, we have to connect to an Ethereum node. We will use Infura API to access the blockchain as explained in Part 1.

#Import Library
from web3 import Web3
#Connect to INFURA HTTP End Point
infura_url='https://mainnet.infura.io/v3/29547...' #your uri
w3 = Web3(Web3.HTTPProvider(infura_url))
#Check Connection…

--

--

Abhijith Chandradas
Geek Culture

Data Analyst | Hacker | Financial Analyst | Freelancer | IIM MBA | Opensource | Democratize Knowledge | https://www.youtube.com/channel/UCLpBd4gzfIBXm2BPpdHOWdQ