Multi-Step Widgets: Teaming up with Alchemix to Streamline Liquidity Migration

OKcontract
3 min readJun 5, 2023

--

OKcontract is excited to announce a major product development and our collaboration with Alchemix. Our team worked hard on a new feature: OKcontract Widget Creator now allows Web3 projects to create Multi-step widgets, that enable multiple onchain operations within a single interface.

Many DeFi operations involve more than one transaction, often necessitating interaction with multiple smart contracts. This can involve a series of steps, such as unstaking tokens from one liquidity pool, swapping tokens, and then staking them in another pool. Currently, each of these steps typically requires interfacing with different dApps (decentralized applications), each with their own user interfaces and transaction approval processes. This can create a disjointed and sometimes confusing user experience, especially for those new to the DeFi space.

In our conversations with numerous DeFi projects, it became clear that we needed to equip Web3 builders with the widgets that can call multiple smart contracts, enabling users to smoothly complete multiple transactions step-by-step within the same interface. With this goal in mind, OKcontract team has added multi-step feature to its Widget Creator.

Teaming up with Alchemix

We teamed up with Alchemix to create a multi-step widget for their use case. Alchemix is taking a new approach to loans that are both self-repaying and non-liquidatable. By depositing ETH or stablecoins, taking out a loan, you can then watch your full deposit earn yield that, over time, pays off your loan.

Alchemix has developed a liquidity migration tool. This tool seamlessly transitions liquidity from any Sushiswap or Uniswap V2 liquidity pool to its corresponding Balancer pool, and then stakes in Aura. It’s a general-purpose solution that supports the migration of any Sushi LP to a Balancer LP, allowing projects to leverage existing live contracts and eliminating the need for additional deployments.

OKcontract has created a multi-step widget for Alchemix to facilitate this liquidity migration process. The widget calls both Sushi Farming contract and Alchemix Migrator contract to execute the migration of staked funds from 50/50 Sushi pool to 80/20 Balancer pool. The widget has 3 steps that enable users to:

  1. Withdraw SLP tokens and claim unclaimed rewards from Sushi pool
  2. Approve Migrator contract for spending X amount of LP tokens
  3. Migrate to Balancer (and optionally stake in Aura pool)

With the OKcontract widget, Alchemix users can now easily migrate their liquidity from Sushi to Balancer, executing multiple transactions within a single interface that can be embedded into any web page. Our multi-step widget can significantly simplify complex blockchain operations, providing users with a seamless and integrated transactional experience.

About Alchemix

Alchemix offers self repaying non liquidatable loans: deposit eth or stables, take a loan, and then watch as your entire deposit earns yield to pay off your loan over time.

--

--

OKcontract

OKcontract Interaction Layer simplifies blockchain interaction implementation across apps