Peggy hook provides an automated way to issue and redeem an over-collateralised XRP-backed stablecoin.
Sending XRP to it creates a vault and sends back stablecoin, which can be redeemed against the vault to get back the original XRP.
The exchange rate between XRP and stablecoin is the limit set on a trustline established between two special oracle accounts.
If the value of XRP falls too far, the vault gets under a minimum collateralization threshold. This means anyone who wants to top up the vault above the threshold can come along and take it over.
to test:
- make sure Hooks Builder has at least 5 accounts: Alice, Bob, Carol, Carlos and Charlie