Contract 3f18920da0c1147589d244a045fe48802fccc8a5fa3eda41f03cfc5715fc91c2

← Back to Index 📥 Download WASM

Meta

rssdkver 23.0.3#6aa930b08eabfd578b7824a0d5de473cbd958282
rsver 1.94.1

Instances

  • CDB7JO24KUZGETT4RKSWL2OMHWCKZTAJT723CTI7IB2O32QGFI4AUNVV

Interface

(Only Owner) Sweep token balances from the contract to to.

fn claim(
    env: soroban_sdk::Env,
    to: soroban_sdk::Address,
    assets: soroban_sdk::Vec,
) -> soroban_sdk::Map
fn get_owner(env: soroban_sdk::Env) -> soroban_sdk::Address

(Only Owner) Rotate ownership.

fn set_owner(env: soroban_sdk::Env, new_owner: soroban_sdk::Address)

Initialize the contract.

Arguments

  • owner - Controls claim, set_owner, set_source_pool.
  • backstop - Blend backstop contract address.
  • usdc - USDC token contract address.
  • source_pool - The Blend pool where this contract holds a USDC supply position. Withdrawals happen from here to fund fills.
fn __constructor(
    env: soroban_sdk::Env,
    owner: soroban_sdk::Address,
    backstop: soroban_sdk::Address,
    usdc: soroban_sdk::Address,
    source_pool: soroban_sdk::Address,
)

Fill an interest auction. Any invoker can call this — the transaction fee is expected to be paid via a fee-bump (e.g. via OpenZeppelin Channels). USDC is withdrawn from the contract's supply position in source_pool, converted to backstop LP tokens via Comet, and used to fill the auction in pool. Any unused USDC is re-supplied back to source_pool so it keeps earning interest.

Arguments

  • pool - Pool whose backstop has the interest auction.
  • fill_percent - Percentage to fill (1-100).
  • max_usdc_in - Upper bound of USDC to spend on this fill.
fn fill_interest(
    env: soroban_sdk::Env,
    pool: soroban_sdk::Address,
    fill_percent: u32,
    max_usdc_in: i128,
)
fn get_source_pool(env: soroban_sdk::Env) -> soroban_sdk::Address

(Only Owner) Change the pool this contract withdraws USDC from.

fn set_source_pool(env: soroban_sdk::Env, new_pool: soroban_sdk::Address)

Imports

WebAssembly Text (WAT) ▶