Skip to content

lz-asia/oChai

Repository files navigation

OmniChai (oChai)

OmniChai (oChai) is an innovative ERC4626 token that is intricately integrated with the Dai Savings Rate (DSR) and also leverages the capabilities of LayerZero's Omnichain Fungible Token (OFT). This provides users with a unique advantage: earning interest through DSR and allowing easy asset transfers between Ethereum and other chains.

What is oChai?

oChai is a unique token that represents a claim on Dai tokens deposited in the DSR. Rather than corresponding one-to-one with Dai, each oChai token represents a claim on an amount of Dai that's earning interest in the DSR. As the DSR generates interest, the value of oChai tokens grows proportionately, allowing holders to benefit from DSR interest without the need to directly engage with the Maker Protocol.

Integration with DSR

oChai's integration with the DSR allows oChai token holders to earn passive income from Dai Savings. The interest that accumulates from the DSR is automatically factored into the value of the oChai tokens. This means decentralized applications, wallets, or exchanges can provide their users with the advantages of the DSR without requiring them to directly interact with the DSR contract.

LayerZero's OFT Integration

Through its integration with LayerZero's OFT, oChai facilitates seamless cross-chain asset transfers, providing users with the opportunity to move their assets between Ethereum and other supported chains. This significantly expands the potential uses and liquidity of oChai tokens.

Wrapper Functions

For added convenience, the oChai contract includes wrapper functions depositAndSendFrom and mintAndSendFrom. These allow users to mint oChai tokens and send them to a different chain in a single operation, greatly simplifying the process.

How to Use oChai

Using oChai tokens is as straightforward as using any ERC4626 token:

  1. Mint oChai: Users can obtain oChai tokens by calling the deposit/mint function directly on the oChai contract. This will deposit Dai and mint the corresponding oChai tokens.

  2. Hold oChai: By simply holding oChai tokens, users automatically benefit from the DSR as the interest generated is incorporated into the value of their tokens.

  3. Transfer Assets: With the integration of LayerZero's OFT, users can transfer their oChai tokens between Ethereum and other supported chains.

  4. Redeem Dai: When users wish to exit their position, they can redeem their oChai tokens for the corresponding Dai value, inclusive of any interest generated by calling the withdraw/redeem function directly on the oChai contract.

oChai brings together the power of DeFi and the convenience of seamless cross-chain asset transfers.

How to Test

  1. yarn install
  2. update FORKING as true and add ALCHEMY_API_KEY in .env
  3. yarn test

License

oChai is MIT licensed.

Contact

For any questions or suggestions, please feel free to reach out to us through email or by opening an issue on our GitHub repository.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published