AIP - 33 - Accept Curve FRAXBP as a collateral for agEUR on mainnet

Hello,

This is a proposal to accept Curve FRAXBP as a collateral for agEUR on mainnet.

Context

Angle can so far only support “classical” ERC20 tokens as a collateral of its borrowing module. By “classical”, I mean collateral assets that are routed on 1inch and that are not yield bearing tokens.

We’ve been working over the last few weeks on setting up an infrastructure to enable the protocol to list virtually any type of ERC-20 token as a collateral, including assets that do not have liquidity pools.
Reason for this is that there is a wide range of valuable tokens that have little to no utility in DeFi except for holding them: this is notably the case for Curve LP tokens which when staked in gauges (on Convex or StakeDAO for instance) do not let you do far more things.

Abracadabra was one of the first protocols to propose using such tokens as a collateral for its USD stablecoin MIM. They grew quite rapidly thanks to these integrations, but fees for borrowing MIM against these assets remain quite high: 3.5% a year for Tricrypto2 for instance with a 0.5% upfront fee.

With our borrowing module tech and the UX (on which we are continuously iterating) for getting leverage and borrowing agEUR, we believe we can improve what’s currently being done. On top of that, we are working on zaps to allow people to acquire the LP tokens and start borrowing without ever owning this LP token: basically you’ll be able to come with USDC in the protocol and then contracts will route your USDC to FRAXBP that will then be used to borrow agEUR which will then be swapped to FRAXBP again.

Proposal

Proposal is to start by accepting FRAXBP as collateral asset of the borrowing module.
Risk parameters can still be refined, but this is what I had in mind to start with:

# Liquidation surcharge for liquidators
surcharge = 0.02
# Max discount given to liquidator
maxDiscount = 0.08
# Collateral factor
CF = 0.85
# Liquidation boost
boost = 2.5
# Target health factor
targetHealthFactor = 1.05

Implementation

Implementation will rely on slightly amended VaultManager contracts together with an additional infrastructure around to wrap the LP tokens. Idea is that you’ll still be able to claim your CRV, CVX or SDT when you have a position that is borrowing agEUR.

Idea would be to have both options possible: StakeDAO and Convex for places where the Curve LP tokens are staked.

Value to the protocol

People will be able to get leverage on Curve LP tokens in a way and for a price that other similar protocols (Gearbox, Abracadabra) cannot match yet. This has the potential to drastically increase demand for borrowing agEUR and usage of the protocol.

FRAXBP is just a start but any kind of yield bearing token could then follow after that.

Risks

The risk is the risk of not being well able to liquidate. We are currently working as well on the liquidation infra to makes sure that everyone will be able to efficiently liquidate and that having these tokens as a collateral will not cause any threat for the protocol or to agEUR’s peg.

There may be also price manipulation risks with Curve LP tokens. These two pools however are not subject to the most common price manipulation attacks you might see on Curve.
We are going to use similar oracles than the ones which made their proofs with Abracadabra.

Super happy to hear thoughts on this. We’re around 1/2 weeks away to have this fully ready, but I think it’s important to launch discussions right now on the matter.

Could also give ideas of other LP tokens to integrate on other platforms.

Hi @sogipec ,

Just to understand, will it be possible to use Curve LP tokens directly, Convex Curve LP tokens and Stake DAO Curve LP Tokens? Is that the idea?

Best regards

Yes that’s the idea! You’ll be able to use Curve LP tokens as well as Convex LP tokens and StakeDAO LP tokens. If you come with Curve LP tokens they’ll either be staked on Convex or on StakeDAO

1 Like

Hi @sogipec,

Let´s vote.

Need to get ready on some technical aspects of it, will create a vote when all this is good!

As I said. Total trust in the developer team.

It’s important to specify that the additional contracts involved, Swapper and Staker have not been audited. Though they all come from other audited and battle-tested contracts, this is still a risk that is important to evaluate.

Staker contract

The Staker contract is the one staking LP tokens to earn rewards, and crediting users with an IOU. Its logic comes from other audited contracts such as staking contracts and ERC4626. VaultManagers will then read the balance of this IOU to determine users’ collateral value and how much they can borrow.

Swapper contract

The Swapper contract doesn’t hold funds and only transfer them. It won’t put any funds at risk as long as the instructions sent to it are correct. This can be double checked before sending any transaction through our simulation mode.

Any estimated timeframe for completing the audit and implementing this new type of collateral?

I hope it’d be live by the end of next week! This week for us is mostly about finishing up the front interfaces and guaranteeing the smoothest UI possible

1 Like

Amending the proposal because I think that at this point it’s not best move to accept Tricrypto2 as a collateral. Markets are pretty wild, there are many uncertainties related to USDT and Tether solvency, and as such I don’t think it’s a good idea to start getting USDT exposure with the protocol

Hello,

Interesting!

I am also worried about the choice of collateral. What do we know about “Curve FRAXBP” ? All the assets in the Liquidity Pool (LP) are “safe” (not like UST or any ponzi-like) ?

Regards,

Thanks for your question! All the assets in the pool are effectively safe! FRAXBP is composed of USDC and FRAX which are non-Ponzi assets

Thank you,

Do you know this table about stablecoins: Stablecoin strategy and risk adjustment - by TyrionLionstar - Google Drive

It says that FRAX is not the best stablecoin :frowning:

I mean I don’t know who made this table but FRAX can easily resist any bank run and it’s 1:1 collateralized by USDC on Curve at least so I feel it’s still a solid stablecoin

Interesting table. I didn’t know about it, thanks!

How are the risk score computed? FRAX can be seen as a ponzi due to how it works (mainly algorithmic/automated market operations, called AMOs) but this is actually a pretty sound way of backing a stablecoin. In any case, it has nothing to do with UST’s mechanism.

We wrote about AMOs on our docs here: ⚙️ Algorithmic Market Operations - Angle Docs