Contract d7a809b2a278feaeafd46d10c8cca50ca032e796ee4bb07d97164b8c47ec7672

← Back to Index 📥 Download WASM

Meta

cliver 27.1.0#8e402ea28202950b272fbabc34caad4d2f64fe87
rssdkver 27.0.0#e5cb4b52c3da8e56fc48adfd7b85d85976c1a059
rsver 1.97.1

Instances

  • CBGM366XLWT3S34X5YY4RIT7YIK3OBEZLEMLAQOAQH77TNA5FY6RTITL
  • CCA73ZYKH5BB4EVVPVJJNJJV6ALY6DG3FGCNCJMEUA6VJTBNVRGEWBMH

Interface

Read-only getter to fetch market metadata by market_id

fn get_market(env: soroban_sdk::Env, market_id: u64) -> MarketMeta

Initialize the factory with the core market contract address

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

Read-only getter to list all market IDs

fn list_markets(env: soroban_sdk::Env) -> soroban_sdk::Vec

Creates a new prediction market. Anyone can call this. Triggers downstream contract creation/initialization on the market contract. Returns the newly generated market_id.

fn create_market(
    env: soroban_sdk::Env,
    creator: soroban_sdk::Address,
    question: soroban_sdk::Symbol,
    resolution_time: u64,
    oracle_id: soroban_sdk::Address,
) -> u64

Imports

WebAssembly Text (WAT) ▶