Upgrade the contract WASM. Admin only. ⚠️ NEVER REMOVE THIS FUNCTION — doing so bricks the contract permanently.
fn upgrade(env: soroban_sdk::Env, new_wasm_hash: soroban_sdk::BytesN<32>)
Contract version.
fn version(env: soroban_sdk::Env) -> u32
Distribute amount of token according to configured splits.
Caller must have approved this contract for the token amount.
fn distribute(
env: soroban_sdk::Env,
from: soroban_sdk::Address,
token: soroban_sdk::Address,
amount: i128,
)
Query current splits.
fn get_splits(env: soroban_sdk::Env) -> soroban_sdk::Vec
Initialize with admin and split configuration. Total BPS across all splits must equal 10000.
fn __constructor(
env: soroban_sdk::Env,
admin: soroban_sdk::Address,
splits: soroban_sdk::Vec,
)
Update the split configuration (admin only).
fn update_splits(
env: soroban_sdk::Env,
admin: soroban_sdk::Address,
splits: soroban_sdk::Vec,
)