Contract adf7b2edbb06807b30a084e276f17a3580486de86452605273882a77a18888ed

← Back to Index 📥 Download WASM

Meta

rssdkver 23.2.1#ab415a33cc1f6bdce20ac4a12f0ddbe41a648949
rsver 1.92.0

Instances

  • CBYI7RD4T72Y5WGYCMX7WAXPRMHNJQC47KPUKPKTTBSMTGLCZ6XXHDYJ

Interface

Aggregate multiple contract calls in a single tx, with affiliate fees taken either from the input token (before instructions) or from the output token (after instructions), per fee_position.

Returns the user's actual output_token amount NET of any output-side fee.

Permissionless: there is no allowlist of targets. The user signs a tx that contains the exact instructions vector being authorized; their signature is the authorization. The router does not custody funds and cannot move tokens beyond what the user has signed for (directly or via source-account auth).

fn execute(
    env: soroban_sdk::Env,
    user: soroban_sdk::Address,
    swap_id: soroban_sdk::BytesN<16>,
    input_token: soroban_sdk::Address,
    input_amount: u128,
    output_token: soroban_sdk::Address,
    instructions: soroban_sdk::Vec,
    affiliate_fees: soroban_sdk::Vec,
    fee_position: FeePosition,
) -> u128

Permissionless TTL keep-alive. Anyone can call to keep the contract's instance entry alive during cold periods.

fn bump_ttl(env: soroban_sdk::Env)

Imports

WebAssembly Text (WAT) ▶