alisinabh
Ethers - a comprehensive Web3 library for interacting with smart contracts on Ethereum using Elixir
Hello Elixir community!
I am excited to announce the release of a new Elixir library for interacting with the Ethereum blockchain: Ethers!
Ethers is heavily inspired by the popular ethers.js library and aims to provide a comprehensive and easy-to-use solution for Elixir developers working with Ethereum smart contracts. With Ethers, you can effortlessly interact with Ethereum contracts using automatically generated Elixir modules, complete with documentation and type-specs.
Here are some of the key features that differentiate Ethers from other Ethereum Clients.
- Compile-time contract ABI to Elixir module conversion. This means it is faster in runtime and easier to use than other libraries like
exw3 - Out of the box support for standard contract interfaces such as ERC20, ERC721, ERC1155 and ERC777
- Easy contract function calling and transaction sending
- Simple log fetching and event filter creation
- Developer first experience with typespecs and generated documentation
- Portable RPC modules (Want to use a different RPC or want to add a feature to the RPC? You can swap it with your own)
Right now this is considered beta-testing release. I would encourage and also ask everybody who is interested to interact with and test Ethers. Did I mentioned that contribution is really welcomed?
Happy coding!
Trending in Announcing
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #phoenix_html
- #iex
- #blog-post
- #graphql
- #genstage
- #ai
- #elixirconf-us
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #metaprogramming
- #performance
- #security











Most Liked
alisinabh
Ethers version 0.0.1 of Ethers is now published on hex.pm/packages/ethers.
This initial beta version is now shipped with the following functionalities.
Feel free to give it a try and file your issues in github or your suggestions here.
alisinabh
Ethers 0.2.0 is out. This version adds new features which helps users to sign transactions locally, with JSON RPC endpoints or even bring their own signer implementation (e.g. using AWS KMS or proprietary HSM modules).
Please feel free to try it out and share your feedback.
Thanks!
alisinabh
By default on EVM chains when you issue a getLogs call you get logs from the last block only. You need to specify
fromBlockandtoBlockvalues. (Example below)I can see there is a gap in the docs regarding these parameters. Will create an issue to track and fix this.
Thank you for introducing W3WS to me. Didn’t know about that!
Last Post!
alisinabh
Elixir Ethers
0.6.xReleaseI’m thrilled to announce that Ethers 0.6 has been released.
This release contains long-awaited features such as raw Transaction decoding, native CCIP read support, improved ENS (Ethereum Name Service) support, and more.
Under the hood, it includes a refactored extensible Transaction module, which will make supporting more transaction types (e.g. EIP-4844) easier.
Version 0.6 has a few breaking changes, but for most typical use cases, it should not cause any major issues.
0.6.0 Changelog
Breaking Changes
Ethers.Transactionstruct and replaced with separate EIP-1559 and Legacy transaction structs for improved type safetyEthers.Transaction.from_map/1- useEthers.Transaction.from_rpc_map/1instead for RPC response parsingEthers.Utils.maybe_add_gas_limit/2- gas limits should now be set explicitlyEthersfunctions must use native types (e.g., integers) instead of hex strings encoded valuestx_typeoption in transaction overrides has been replaced withtype, now requiring explicit struct modules (e.g.Ethers.Transaction.Eip1559,Ethers.Transaction.Legacy)Ethers.Transaction.calculate_y_parity_or_v/1toEthers.Transaction.SignedmoduleEthers.send/2in favor ofEthers.send_transaction/2for clarity and prevent collision withKernel.send/2.New features
Ethers.CcipReadmodule for off-chain data resolutionEthers.Transaction.Protocolbehaviour for improved transaction handlingEthers.Utils.decode_address/1andEthers.Utils.encode_address/1Transaction.decode/1to decode raw transactionsEnhancements
Ethers.deploy/2Etherstop module functions which were missingPlease feel free to open issues, reply here or in Elixir’s #ethereum slack channel if you face any issues.