ethers-rs/ethers-etherscan
DaniPopes 203e350940
docs: fix broken links, update documentation (#2203)
* docs: fix broken links

* docs: update READMEs and module-level documentation
2023-02-27 13:03:17 -07:00
..
resources flatten before verification (#828) 2022-02-04 10:08:52 +02:00
src docs: fix broken links, update documentation (#2203) 2023-02-27 13:03:17 -07:00
Cargo.toml chore(deps): bump reqwest from 0.11.13 to 0.11.14 (#2065) 2023-01-27 13:13:10 -05:00
README.md docs: fix broken links, update documentation (#2203) 2023-02-27 13:03:17 -07:00

README.md

ethers-etherscan

Bindings for the etherscan.io web API.

For more information, please refer to the book.

Examples

# use ethers_core::types::Chain;
# use ethers_etherscan::Client;
# async fn foo() -> Result<(), Box<dyn std::error::Error>> {
let client = Client::new(Chain::Mainnet, "<your_api_key>")?;
// Or using environment variables
let client = Client::new_from_env(Chain::Mainnet)?;

let address = "0xBB9bc244D798123fDe783fCc1C72d3Bb8C189413".parse()?;
let metadata = client.contract_source_code(address).await?;
assert_eq!(metadata.items[0].contract_name, "DAO");
# Ok(())
# }