Skip to main content

Flipper

Flipper

MAXIMUM_PER_TRADE

uint256 MAXIMUM_PER_TRADE

dai

contract IERC20 dai

ousd

contract OUSD ousd

usdc

contract IERC20 usdc

usdt

contract Tether usdt

constructor

constructor(address _dai, address _ousd, address _usdc, address _usdt) public

buyOusdWithDai

function buyOusdWithDai(uint256 amount) external

Purchase OUSD with Dai

Parameters

NameTypeDescription
amountuint256Amount of OUSD to purchase, in 18 fixed decimals.

sellOusdForDai

function sellOusdForDai(uint256 amount) external

Sell OUSD for Dai

Parameters

NameTypeDescription
amountuint256Amount of OUSD to sell, in 18 fixed decimals.

buyOusdWithUsdc

function buyOusdWithUsdc(uint256 amount) external

Purchase OUSD with USDC

Parameters

NameTypeDescription
amountuint256Amount of OUSD to purchase, in 18 fixed decimals.

sellOusdForUsdc

function sellOusdForUsdc(uint256 amount) external

Sell OUSD for USDC

Parameters

NameTypeDescription
amountuint256Amount of OUSD to sell, in 18 fixed decimals.

buyOusdWithUsdt

function buyOusdWithUsdt(uint256 amount) external

Purchase OUSD with USDT

Parameters

NameTypeDescription
amountuint256Amount of OUSD to purchase, in 18 fixed decimals.

sellOusdForUsdt

function sellOusdForUsdt(uint256 amount) external

Sell OUSD for USDT

Parameters

NameTypeDescription
amountuint256Amount of OUSD to sell, in 18 fixed decimals.

rebaseOptIn

function rebaseOptIn() external

Opting into yield reduces the gas cost per transfer by about 4K, since ousd needs to do less accounting and one less storage write.

withdraw

function withdraw(address token, uint256 amount) external

Owner function to withdraw a specific amount of a token

withdrawAll

function withdrawAll() external

Owner function to withdraw all tradable tokens

Contract will not perform any swaps until liquidity is provided again by transferring assets to the contract.