Biconomy Integrates Chainlink Price Feeds to Enable Gas Payments in Various Cryptocurrencies

Aditya Khanduri
Biconomy
Published in
5 min readJun 29, 2021

Biconomy is thrilled to announce that we are working with Chainlink to integrate Chainlink Price Feeds on the Ethereum and Polygon mainnet, enabling our system to calculate execution fees and rebalance our relayers based on the most accurate, up-to-date, and tamper-proof asset prices. As a multi-chain transaction platform planning to support all major blockchains, Biconomy consistently requires current asset prices so users receive fair market rates when paying for transactions in one cryptocurrency while underlying dApps and blockchain networks get paid in their native asset.

We decided to use Chainlink as our oracle provider because it’s price feeds are time-tested through volatile market conditions and widely used by leading blockchain projects. Chainlink Price Feeds have strong market coverage across all trading environments and are updated in a highly secure and reliable manner without central points of failure. It’s why Chainlink Price Feeds protect tens of billions of dollars in value for DeFi and have proven resilient during times of extreme market volatility and network congestion.

Unlocking Gas Fee Limitations with Chainlink

Biconomy is cross-chain transaction infrastructure that simplifies the web 3.0 experience. Our first module is called Gasless — gasless meta-transaction services for dApps that improve the onboarding experience for new users, especially during times of high gas prices. Soon after, we launched another module called Forward — a service for end users to pay dApp gas fees in supported ERC-20 tokens and stablecoins rather than the underlying blockchain cryptocurrency (i.e. ETH or MATIC), massively simplifying transactions for users. Some common examples include:

  • Swap tokens on any DEX and pay fees in stablecoins
  • Provide liquidity on farming protocols and pay fees in the token being deposited
  • Transfer USDT to someone and spend a little extra USDT in fees

Enabling this experience requires current exchange rates between user-supplied tokens and the native assets of underlying blockchains and dApps, which is where Chainlink comes into play. Whenever a user makes a transaction on a Forward-integrated dApp, the tokens that leave their wallets are converted on the backend to the native currency of the blockchain/dApp using a precise exchange rate supplied by Chainlink Price Feeds. Biconomy uses this exchange rate to calculate the gas fee the user must pay using their token of choice to execute the transaction.

How Does It All Fit Together?

From a technical perspective, Forward works through a method call whenever a user wants to pay gas fees in supported tokens. The user then signs a message, and a trusted forwarder pushes a transaction from the relayer to the recipient contract. Execution gas is calculated to find out how many tokens should be charged from the user.

Currently, our oracle aggregator references the following Chainlink Price Feeds: DAI/ETH, USDT/ETH, and USDC/ETH on Ethereum, and SAND/MATIC on Polygon for quick access to the “token gas price” of any given transaction that calls the Forward module. Essentially, if the gas price is 100 Gwei and the ETH price is 300 Dai, the token gas price will be 30,000 Gwei.

The general flow on-chain goes like this:

  1. The Biconomy client gets the current gas price from the servers.
  2. The ERC20 Forwarder receives which token the user wants to pay gas in.
  3. The price for that token is requested from the oracle aggregator, which references Chainlink Price Feeds.
  4. The transfer handler in ERC20 Forwarder calculates correspondingly how many tokens the user should pay to cover their gas and then charges the user.
  5. The user signs the transaction to validate the meta-transaction for the recipient contract call, and the Biconomy relayer pays gas in ETH.

Why Chainlink?

Secured by Chainlink Price Feeds, Forward is able to maintain reliable and fair payment instructure while greatly improving the user experience for dapps. Some of the main reasons we selected Chainlink include:

  • High-Quality Data — Chainlink Price Feeds source data from numerous premium data aggregators, leading to price data that’s aggregated from hundreds of exchanges, weighted by volume, and cleaned from outliers and wash trading. Chainlink’s data aggregation model generates accurate global market prices that are resistant to API downtime, flash crash outliers, and data manipulation attacks like flash loans.
  • Reliable Nodes — Chainlink Price Feeds are secured by a decentralized network of independent, security-reviewed, Sybil-resistant oracle nodes run by leading blockchain DevOps teams with a proven history of hyper-reliability.
  • Decentralized Infrastructure — both the data sourcing and on-chain transmission processes are decentralized, removing any central point of failure.
  • Reputation — Chainlink provides a robust reputation framework and set of on-chain monitoring tools that allow users to independently verify the historical performance of node operators and oracle networks and check the real-time prices being offered.

We are just beginning to leverage Chainlink’s blockchain-agnostic oracle technology. In the future, Biconomy will integrate numerous other ERC-20 token price feeds across different blockchain networks — simplifying dApp and DeFi user experiences across the board, scaling our project to meet the demands of developers, and spearheading blockchain adoption.

“As we continue on our mission of simplifying web 3.0, Chainlink will act as a critical component in our entire architecture, ” Aniket Jindal, co-founder of Biconomy. “The decentralized nature of Chainlink, their attention to ease-of-integration and security, and the trusted team of experts supporting it’s development were key reasons we decided to go with Chainlink.”

“We’re happy to support Biconomy’s Forward solution for simplifying dApp user experiences by providing them with reliable price oracles needed to set fair market exchange rates,” stated Dan Kochis, Head of Partnerships at Chainlink Labs, “Chainlink Price Feeds incorporate multiple layers of decentralization to ensure Biconomy has the highest quality data and strong protections against downtime and data manipulation.”

— — — — — — —

About Chainlink

Chainlink is the industry standard oracle network for powering hybrid smart contracts. Chainlink Decentralized Oracle Networks provide developers with the largest collection of high-quality data sources and secure off-chain computations to expand the capabilities of smart contracts on any blockchain. Managed by a global, decentralized community, Chainlink currently secures billions of dollars in value for smart contracts across decentralized finance (DeFi), insurance, gaming, and other major industries.

Chainlink is trusted by hundreds of organizations, from global enterprises to projects at the forefront of the blockchain economy, to deliver definitive truth via secure, reliable oracle networks. To learn more about Chainlink, visit chain.link, subscribe to the Chainlink newsletter, and follow @chainlink on Twitter. To understand the full vision of the Chainlink Network, read the Chainlink 2.0 whitepaper.

Solutions | Docs | Discord | Reddit | YouTube | Telegram | GitHub

About Biconomy

Biconomy is the multi-chain transaction infrastructure for the next-generation Web 3.0 applications. Through Biconomy’s powerful and easy to use APIs, developers can enable a simple and customized user journey so that their end users don’t get frustrated by blockchain complexities. By solving key pain points at the crypto transactional layer, Biconomy is on a mission to bring the familiarity of web 2.0 to simplify Web 3.0 experiences that will drive mass adoption.

Docs | Telegram | Discord

--

--

Aditya Khanduri
Biconomy

Marketing @Biconomy | Interested in Blockchain, Artificial Intelligence, Biotech & emerging tech startups | Tea aficionado