Last active
December 23, 2022 06:14
-
-
Save a26nine/200734bfa8fdf245f211a5a9746173e7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from web3 import Web3, HTTPProvider | |
import streamlit as st | |
w3 = Web3(HTTPProvider(YOUR_QUICKNODE_ENDPOINT_URL)) | |
st.header("Ethereum Address Explorer") | |
address = st.text_input("Wallet Address") | |
submit = st.button("Fetch Txs") | |
if submit: | |
txs = w3.provider.make_request('qn_getTransactionReceiptsByAddress', [ | |
{ | |
"accounts": [address] | |
} | |
]) | |
for r in txs["result"]: | |
tx = ( | |
f'TxHash: **[{r["transactionHash"]}](https://etherscan.io/tx/{r["transactionHash"]})** \n From: **{r["from"]}** \n To: **{r["to"]}**') | |
st.markdown(tx) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment