play
One-shot autonomous bidding: checks balances, topups SOL, picks the highest-pot live game, and bids via x402 unless you are already holding the head position. Returns a structured status for recurring agent loops.
Instructions
One-shot autonomous playbook. The ONLY tool a stateless agent loop needs.
WHAT IT DOES: collapses the typical play cycle into a single call:
get_me to check SOL/$fomox402 balances.
If SOL < min_sol_lamports, call topup (silently swallowing rate-limits).
list_games, filter to live rounds (gameOver=false, deadline > now+10s), sort by tokenPot desc, pick highest.
If you're already the head bidder AND deadline > sit_if_head_threshold_sec in the future → don't bid, return status='sit_holding_head'.
Else place_bid at effective_min + 1 raw via the full x402 flow.
Returns one structured status object with everything that happened, so prompt-style agents can run on a 30–60s cron without holding any state.
WHEN TO USE: as the only tool in a recurring agent loop. Drop into Claude Desktop / Cursor / Goose / a cron job and run forever. Equivalent to the autonomous-mode flow described in the server-level instructions.
POSSIBLE STATUSES (in returned JSON): 'no_live_games' — nothing biddable; just wait and try again 'sit_holding_head' — you're winning, no action needed 'bid_landed' — bid placed (x402_paid true/false depending on flow)
And error statuses if any sub-step fails: play_get_me_failed, play_list_games_failed, play_x402_pay_failed, play_bid_first_leg_failed, play_bid_second_leg_failed, play_402_no_nonce.
RETURNS: { status, gameId?, amountRaw?, x402_paid?, x402_fee_tx?, tx?, topup? (sub-result of any topup attempt), timer_remaining_sec?, note? }.
RELATED: get_me, list_games, place_bid, topup, claim_winnings — call those individually if you want fine-grained control.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| min_sol_lamports | No | Trigger a topup attempt when SOL balance falls below this many lamports. Default 2_000_000 (= 0.002 SOL). Set to 0 to disable auto-topup entirely. | |
| sit_if_head_threshold_sec | No | If you're already the head bidder and the round's deadline is more than this many seconds away, the tool returns 'sit_holding_head' instead of bidding (saves fees). Default 60. Set to 0 to always bid even when winning. | |
| api_key | No | Bearer api_key (or env). |