Case Study: Router Nitro

Zyfi’s integration with Router Nitro marks a significant development in the DeFi space, enabling cross-chain swaps from ZKsync without the need for ETH to pay gas fees.

Router Nitro, developed by Router Protocol, is an ultra-efficient cross-chain bridge designed for high performance and low costs, supporting transactions across both EVM and non-EVM blockchains. This integration reflects a growing need for smoother, more accessible cross-chain swaps while minimizing the overhead of multiple assets for transaction fees.

Gas management issue

One of the biggest challenges in the DeFi ecosystem is the need to hold ETH in order to pay gas fees, even when conducting transactions using other tokens. This creates friction for users who might not have ETH in their wallet, especially when engaging in cross-chain swaps. Users often face delays or added complexity, needing to first acquire ETH before completing their desired transaction. This issue significantly affects user experience and the overall efficiency of DeFi transactions.

Paymasters for EOA on ZKsync

Zyfi solves this long-standing issue on ZKsync by leveraging native AA and the Zyfi’s ERC-20 paymaster to allow the use of source tokens for gas fees. On ZKsync and ZK Stack chains, all wallets are treated as smart wallets by default, using the same mempool and transaction flow, enabling EOAs to enjoy Smart Wallet features like paymaster. By integrating Zyfi’s solution with a simple API call, Zyfi allows Router Nitro users to perform swaps without worrying about gas-fees. Now, when initiating a cross-chain swap from ZKsync, users can simply check “Pay Gas Using Source Asset” to use Zyfi’s paymaster, eliminating the need for ETH. This seamless gas abstraction experience supports all ERC-20 tokens as payment for gas fees, greatly simplifying the transaction process and improving accessibility.

UX/UI Implementation

The UX/UI implementation time depends on your design choice. As a cross-chain bridge, Router Nitro opted for:

  • Simplicity: A simple checkbox that doesn't impact the ease of performing a swap.

  • Design: An implementation that seamlessly fits with Router Nitro’s website.

With an integration like Zyfi that simplifies the user experience, you encourage users to return frequently to your protocol. A simple checkbox, and your users no longer need to hold ETH in their wallet to complete the swaps they want.

In terms of development time, expect about 0.5 day for the API call and 0.5 day for the UI implementation (depending on your sponsorship or integration model). For example, if you want to let users choose their gas fee token, it will take a bit more time, as seen with PancakeSwap.

Zyfi integration, enhance the developer experience

Zyfi’s biggest advantage is its straightforward integration process, enabling developers to deliver a seamless gasless experience in under a day. Router Nitro, for example, followed just two simple steps to allow their users to enjoy the power of paymaster on both Smart Wallets and EOAs:

  1. Select the Paymaster they want to use—ERC20 or Sponsored.

  2. Integrate the Paymaster into their front-end.

And that’s it! 🎉

Additionally, by providing 1 or 2 wallet addresses to the Zyfi team, they can track all ERC20 paymaster transactions enabled for their users through a clear Partner dashboard.

Conclusion

As a result, Router Nitro users can now benefit from hassle-free, low-cost cross-chain swaps. This solution not only improves the user experience by removing the ETH dependency but also furthers Zyfi’s mission to offer a gasless experience across the entire ZKsync ecosystem. This collaboration positions Router Nitro as a key player in gas abstraction, making DeFi transactions more fluid and efficient while reducing costs for users.

Last updated