ProtocolContract Addresses & Events

Contract addresses & events

This page is the on-chain reference for Noether: every deployed contract address on the live stack, the network configuration to reach them, and the complete list of events each contract emits — with exact field order, so indexers and integrations can decode them without guesswork.

⚠️

Noether runs on the Stellar testnet. Addresses change whenever contracts are redeployed or the Stellar testnet resets. Don’t hardcode them — verify against the gateway’s health endpoint (below) before relying on any address.

Deployed contracts (Stellar testnet)

The production stack — what https://noether.exchange and the gateway at https://noetherapi-production.up.railway.app serve — deployed 2026-07-06:

ContractAddressExplorer
Market (trading engine)CAE3U7JKESRWZHPEQ72DVNGOQ6WPA7HSPQZL5YV46NPCE4TMUPAGYMECstellar.expert
Liquidity Vault (LP pool)CBLVZZ557ALB342GBQIMC2E3IYXJ5AEL7XSVMPX36CVLKRDQGDH22UL6stellar.expert
Noeracle Shim (SEP-40 price reader)CBY4YLPYEN5GMV4JMVZGCSU433SO5JTEGCS66GIT3EZOUG2CN2TWT6UKstellar.expert
Noether Router (verify-then-trade)CDH4CY3XMUZ7H73LC3WJYR3AG56U4MTIBMR2WHNORXDTWLLBOQII44S4stellar.expert
Noeracle (signed price source)CAYIP67UDVX5UPXGN3XDAWVIEFBAVG6G7LUESEOU3NUQKTWN55W34YBGstellar.expert
Vault Factory (Trader Vaults)CAZPVI2PLDQJGDDGULG7FSVNYO3B7BTWTTK5OWVH5SSWN7SJ4ZCBTVP5stellar.expert
ReferralCCV5NWLGQTCRFFOTHJDQVFOOLAEUPQTWMPTNNHR2EU64BULV77W5GXEEstellar.expert
USDC token (test asset, SAC)CA63EPM4EEXUVUANF6FQUJEJ37RWRYIXCARWFXYUMPP7RLZWFNLTVNR4stellar.expert
NOE token (LP token, SAC)CD7VRBXIDYP2C2F2AZZL242GY4PRDVDH2BG3LAN2ASXYUXCPHWQJTDP5stellar.expert

Notes:

  • NOE is a SAC-wrapped classic Stellar asset — code NOE, issuer GCKIUOTK3NWD33ONH7TQERCSLECXLWQMA377HSJR4E2MV7KPQFAQLOLN (the admin account). It is pre-minted to the Liquidity Vault and moved by transfer; there is no runtime minting.
  • Noeracle is the external signed-price source; the market reads prices through the shim, and the router relays signed attestations into Noeracle at trade time. See Oracle for the full price chain.
  • All amounts and prices on-chain use 7-decimal fixed point: raw 10_000_000 = 1.0.

Verify what a deployment actually serves

The gateway echoes the exact contract addresses it resolved at boot from GET /v1/health — this is the ground truth for what the live API is pointed at:

curl -s https://noetherapi-production.up.railway.app/v1/health
{
  "status": "ok",
  "network": "testnet",
  "contracts": {
    "market":        { "address": "CAE3U7JK…YMEC", "source": "manifest" },
    "vault":         { "address": "CBLVZZ55…2UL6", "source": "manifest" },
    "noeracleShim":  { "address": "CBY4YLPY…T6UK", "source": "manifest" },
    "noetherRouter": { "address": "CDH4CY3X…44S4", "source": "manifest" },
    "usdcToken":     { "address": "CA63EPM4…VNR4", "source": "manifest" },
    "noeToken":      { "address": "CD7VRBXI…TDP5", "source": "manifest" },
    "vaultFactory":  { "address": "CAZPVI2P…TVP5", "source": "manifest" },
    "referral":      { "address": "CCV5NWLG…GXEE", "source": "manifest" }
  }
}

Addresses are abbreviated here; the live response returns them in full. Each entry carries a source field telling you whether the address came from the deployment manifest or an environment override. See System endpoints for the full health response shape.

Network configuration

SettingValue
NetworkStellar testnet
Network passphraseTest SDF Network ; September 2015
Soroban RPChttps://soroban-testnet.stellar.org
Horizonhttps://horizon-testnet.stellar.org
Friendbot (XLM funding)https://friendbot.stellar.org

The public testnet RPC endpoint is rate-limited; for anything beyond light reads, use your own or a paid RPC provider. Mainnet is planned but not live — no Noether contracts are deployed there. See Networks for details.

Event reference

Soroban contracts publish events as a tuple of topics plus a data payload. Below, the topic symbol is shown in quotes and the data tuple lists fields in their exact on-chain order. Conventions:

  • direction serializes as the Direction enum: Long = 0, Short = 1.
  • Amounts, sizes, and prices are i128 values in 7-decimal fixed point.
  • IDs (position_id, order_id) are u64; addresses are Stellar Address values; asset is a Symbol like BTC.

These events are what the Noether indexer consumes to build the REST projections (positions, trades, leaderboard) and the WebSocket event streams — see WebSocket.

Market contract

TopicData tupleEmitted when
"initialized"(admin, vault, oracle_adapter)Contract initialization
"paused" / "unpaused"() (empty)Admin pauses or unpauses trading
"position_opened"(position_id, trader, asset, direction, size, entry_price)Every open: isolated, cross-margin, and keeper-executed limit entries
"position_closed"(position_id, trader, asset, direction, size, entry_price, current_price, pnl)Manual close (isolated or cross), stop-loss / take-profit / trailing-stop execution, reduce-only close
"position_liquidated"(position_id, trader, asset, direction, size, keeper_reward, current_price)Isolated-position liquidation
"cross_liq"(trader, total_pnl, keeper_reward)Cross-account liquidation — one event for the whole account; per-position position_liquidated events are NOT emitted
"order_placed"(order_id, trader, trigger_price)place_limit_order, set_stop_loss, set_take_profitNOT emitted by place_stop_limit_order or place_trailing_stop
"order_cancelled"(order_id, reason)Any cancellation; reason is a Symbol (table below)
"order_executed"(order_id, reward)Successful keeper execution of a pending order
"funding_applied"(funding_rate, hours_elapsed)Hourly apply_funding call (the rate is stored globally; settlement is lazy, per position, at close or liquidation)

order_cancelled reasons:

ReasonMeaning
"user"Owner called cancel_order
"slippage"Execution price breached the order’s slippage tolerance; collateral refunded, order status set to CancelledSlippage
"ioc_not_filled"IOC order placed while its trigger condition wasn’t met; collateral refunded at placement
"pos_closed"An attached stop-loss / take-profit / trailing stop was cancelled because its position closed or was liquidated
"reduce_only_no_position"Reduce-only order executed with no suitable opposing position to close

Because stop-limit and trailing-stop placements emit no event, an event-only indexer will not see those orders until they execute (order_executed) or cancel (order_cancelled). To enumerate all resting orders, read contract state directly (get_all_order_ids plus get_order).

Liquidity Vault contract

TopicData tupleEmitted when
"initialized"(admin, market_contract, usdc_token, noe_token)Contract initialization
"deposit"(depositor, usdc_amount, noe_amount, fee)LP deposits USDC, receives NOE
"withdraw"(withdrawer, noe_amount, net_usdc, fee)LP redeems NOE for USDC
"pnl_settled"(pnl)Every settle_pnl call from the market (win, loss, or zero)
"payout_shortfall"(pnl, paid, short)A winner’s payout exceeded the pool-plus-buffer capacity; the unpaid remainder is recorded
"loss_received"(amount)Market credited a real USDC receipt (trader losses, funding, fees)
"exposure_synced" (second topic: asset)(asset_unrealized_pnl, total_unrealized_pnl, release)Market pushed a fresh per-asset mark or released a payout reservation
"market_updated"(old_market, new_market)Admin re-pointed the vault at a new market contract
"deposit_fee_updated" / "withdraw_fee_updated"(fee_bps)Admin changed a vault fee
"deposit_cap_set"(cap)Admin set the guarded-launch per-account deposit cap
"buffer_seeded"(amount)Admin seeded the insurance buffer
"buffer_funded"(amount)Market credited the insurance buffer
"paused" / "unpaused"() (empty)Vault pause state changed (blocks deposits and withdrawals only)
"admin_updated"(old_admin, new_admin)Admin transfer
"emergency_withdraw"(amount, recipient)Paused-only admin escape hatch

Vault Factory contract (Trader Vaults)

Vault Factory events carry the vault ID as a second topic, so you can filter per vault without decoding payloads.

TopicsData tupleEmitted when
"initialized"(admin, market, usdc)Contract initialization
"vault_created", id(leader, name)New Trader Vault created
"deposit", vault_id(depositor, amount, shares)Depositor buys shares
"withdraw", vault_id(depositor, shares, usdc_out)Depositor redeems shares
"leader_open", vault_id(leader, position_id, collateral)Leader opened a market position through the vault
"leader_close", vault_id(leader, position_id)Leader closed a vault position
"leader_limit", vault_id(leader, order_id)Leader placed a limit order through the vault
"leader_cancel", vault_id(leader, order_id)Leader cancelled a vault order
"fees_claimed", vault_id(leader, owed, new_nav)Leader claimed profit share above the high-water mark
"paused" / "unpaused", vault_id() (empty)Leader paused or unpaused the vault
"admin_paused" / "admin_unpaused", vault_id() (empty)Factory admin paused or unpaused the vault

Referral contract

TopicData tupleEmitted when
"initialized"(admin, market)Contract initialization
"code_created"(referrer, code)A referral code is registered
"referrer_set"(referee, referrer, code)A trader binds to a referral code (permanent, one-time)
"trade_recorded"(referee, referrer, original_fee, discount, payout)record_trade — market-only entry point; not currently emitted (see note)
"claimed"(referrer, amount)Referrer claims accrued rewards

The deployed market contract does not yet call the referral contract’s record_trade, so trade_recorded events do not appear on-chain today. Code registration and referrer binding (code_created, referrer_set) are live now; the fee economics — the 4% referee discount and 10% referrer share — activate in v1.1, when a market upgrade wires the on-chain hook. See Referrals for how the program works in practice.

Reading events yourself

Events are available three ways:

  • Soroban RPCgetEvents against https://soroban-testnet.stellar.org, filtered by the contract addresses above.
  • Noether gateway — the indexer archives raw events and serves them over REST (GET /v1/events) and streams them over WebSocket. See the REST API and WebSocket references.
  • Explorer — each stellar.expert link above shows a contract’s recent invocations and events.

Next steps

  • Architecture — how the market, vault, router, and oracle fit together
  • Oracle — the Noeracle price chain these contracts depend on
  • Networks — testnet details and the mainnet plan