Contract d023145534b1c4092289d95f389775a1f3925c56cddf49f9f60f5a5241d110f5

← Back to Index 📥 Download WASM

Meta

rssdkver 22.0.5#25daaf397971f2c15fd2a5fd0a9967020a19cfcb
rsver 1.84.0

Instances

  • CDHFS6KFUDIW6C6VATFBUE4TCOIRMZ5LVGQTN4XJROSMTEJEKAKJGY5L

Interface

Initialize the contract with an admin address Admin will only be needed for special administrative tasks

fn initialize(env: soroban_sdk::Env, admin: soroban_sdk::Address)

Add a single price entry for a CUSIP This function is public - anyone can add prices

fn add_price(
    env: soroban_sdk::Env,
    caller: soroban_sdk::Address,
    cusip: soroban_sdk::String,
    price: i128,
    yield_value: i128,
    trade_amount: i128,
    trade_type: soroban_sdk::String,
) -> Result<(), MuniError>

Administrative function - only callable by admin This can be used for future administrative tasks

fn admin_function(
    env: soroban_sdk::Env,
    caller: soroban_sdk::Address,
) -> Result<(), MuniError>
fn get_cusip_prices(
    env: soroban_sdk::Env,
    cusip: soroban_sdk::String,
) -> soroban_sdk::Vec
fn get_all_cusips(env: soroban_sdk::Env) -> soroban_sdk::Vec
fn get_all_latest_prices(
    env: soroban_sdk::Env,
    limit: Option,
) -> soroban_sdk::Vec

Imports

WebAssembly Text (WAT) ▶