Skip to content

Getting Started (Market Makers)

The fastest path to earning maker rebates and liquidity rewards is to run the reference market-making bot. It implements a simple inventory-aware two-sided quoter and is the same code Oracle uses to seed liquidity on new markets.

1. Clone the reference bot

git clone https://github.com/parti-labs/oracle-lp
cd oracle-lp

The bot is a ~500-line Rust binary. It:

  • Subscribes to the Oracle order-book WebSocket
  • Maintains a symmetric two-sided quote around mid, scaled by configured spread_bps and size
  • Cancels and re-posts when mid moves > requote_bps
  • Tracks inventory and skews the quote (widens the constrained side) when it drifts

2. Fund your wallet

Market makers get a higher per-tx deposit cap than retail. Ask the Parti team for LP tier — it's a single on-chain bump. Once granted, your /v1/deposit/bridge-address response will show:

{
  "max_usdc_per_tx_micro": 1000000000,    // 1M USDC per tx (LP tier)
  "daily_cap_remaining_usdc_micro": 100000000000
}

See Operations for the full tier table.

3. Generate a trading key

Market makers use the same signer flow as builders — one HMAC-authenticated signer instance per operator:

curl -X POST ${SIGNER}/v1/keys \
  -H "X-Api-Key: ${API_KEY}" \
  -H "X-Signature: ${HMAC}" \
  -H "X-Timestamp: ${TIMESTAMP}" \
  -d '{"user_id": "mm-bot-main"}'

Save the returned public_key — it's your trading address and the wallet that accumulates rebates and reward credits.

4. Configure the bot

# oracle-lp/config.toml
signer_url = "https://signer.parti-oracle.pbcapps.dev"
api_key    = "bld_..."
api_secret = "..."
user       = "7yQ3mH9a..."        # from step 3

[[markets]]
market_id   = "abc123..."
spread_bps  = 50                  # quote 25 bps inside of rewards max_spread_bps
size        = 1000                # contracts per side
requote_bps = 10                  # re-post when mid moves this much

Pick spread_bps inside the market's max_spread_bps (see GET /v1/rewards/config) — quotes outside the rewards band earn rebates on fills but score 0 for the liquidity rewards budget.

5. Run

cargo run --release

Watch for resting orders on the order book. Check your earnings:

# Rebates accrued to your wallet balance
curl https://api.parti-oracle.pbcapps.dev/v1/balance/${PUBKEY}

# Reward credits (claimable, separate from wallet balance)
curl https://api.parti-oracle.pbcapps.dev/v1/rewards/wallet/${PUBKEY}

# Your rank on today's leaderboard
curl "https://api.parti-oracle.pbcapps.dev/v1/rewards/leaderboard?market_id=${MARKET_ID}"

Next steps

  • Tune per-market: every market has its own max_spread_bps, min_size, daily_budget_usdc. Pull from GET /v1/rewards/config and size accordingly.
  • Multi-market: the bot accepts an array of [[markets]] blocks. Capital is pooled; inventory is tracked per market.
  • Risk limits: set max_position_usdc per market to cap drawdown on adverse selection.
  • Claim rewards: see Liquidity Rewards for the on-chain claim flow.