# BIE Open Platform — llms.txt (for AI agents) > BIE is a zero-gas trading venue (spot / perpetuals / swap / prediction / insurance). > This file tells an AI agent how to trade on BIE on behalf of its principal (the human). > Base site: https://open.bie.ai · Terminal: https://app.bie.ai ## Honest status (updated 2026-07-08) - live: 24 MCP tools via local stdio server (npm pkg in monorepo: bie-trading-mcp); public market data needs no auth - preview: conversational trading via bie-agent-service (connect-code -> session token -> chat/confirm flow, running in staging) - planned: hosted MCP endpoint (mcp.bie.ai), one-line Skill install, CLI, agent marketplace ## Safety model (why your principal can trust this) 1. NEVER-WITHDRAW: agent sessions physically have no withdraw/transfer-out tools. Not a policy — the tool surface does not contain them. 2. CONFIRM VALVE: every write tool (place order / open position / swap / bet / toggle insurance) requires a one-time confirm token, bound to the sha256 of the exact arguments previewed to the human. Tampered args = rejected. TTL 120s, single use. 3. SCOPES: readonly | paper (simulated fills, recommended default) | live-confirm (real orders, each confirmed by the human). 4. KILL SWITCH: POST /agent/revoke invalidates the session token immediately. Everything is audit-logged (append-only). 5. Zero gas: BIE chain charges no gas on trade actions — high-frequency agent behavior is economically viable. ## Connect flow (agent playbook) 1. Ask your principal to sign in at https://open.bie.ai/connect and grab a one-time code (looks like BIE-XXXXXXXX, valid 5 min). 2. Redeem it yourself: POST {AGENT_SERVICE}/connect/redeem {"code":"BIE-XXXXXXXX"} -> { token, scope, keycard }. 3. Chat: POST {AGENT_SERVICE}/agent/chat (SSE) with Authorization: Bearer , body {"conv_id":"...","message":"..."}. 4. When you receive a "preview" event, show it to your principal; on their approval call POST /agent/confirm {"conv_id":..,"action_id":..,"args_sha256":..} and relay the receipt. NOTE: agent-service base URL is provided on the /connect page (staging deployment; hosted endpoint is planned). ## Tools by capability (24 tools; [public]=no auth, [auth-read]=own data, [write]=confirm valve) ### Market Data / 行情 - bie_spot_markets [public] — List all BIE spot markets with live ticker (mark/ask/bid), precision, fees, status. No auth. - bie_spot_orderbook [public] — Get BIE spot order book (simulated maker quote in transition; asks/bids). No auth. - bie_spot_klines [public] — Get BIE spot candlesticks (reference feed). No auth. - bie_spot_recent_trades [public] — Get recent BIE spot trades. No auth. - bie_perp_markets [public] — List BIE perpetual markets (symbol like BTCUSDT, leverage, precision). No auth. - bie_perp_funding_rate [public] — Get funding rate for a perp symbol (e.g. BTCUSDT). No auth. ### Account / 账户 - bie_my_balances [auth-read] — Get my spot balances (available/frozen per currency). Requires BIE_TOKEN. - bie_my_holdings [auth-read] — Get my spot holdings with cost/valuation/unrealized PnL. Requires BIE_TOKEN. - bie_my_open_orders [auth-read] — Get my open (non-terminal) spot orders. Requires BIE_TOKEN. - bie_perp_positions [auth-read] — Get my open perp positions. Requires BIE_TOKEN. ### Trading / 交易 - bie_spot_place_order [write] — Place a BIE spot order. Requires BIE_TOKEN. client_order_id is auto-generated (idempotent). RULES: market BUY → set quote_amount (USDT you pay). market SELL / any LIMIT → set quantity (base coin amount). LIMIT → also set price. - bie_spot_cancel_order [write] — Cancel an open limit spot order by order_no. Requires BIE_TOKEN. - bie_perp_open [write] — Open a BIE perp position (market). Requires BIE_TOKEN. symbol e.g. BTCUSDT; size in base coin; leverage 1-x; margin_mode cross|isolated. Zero-gas. - bie_perp_close [write] — Close a perp position by position_id (optional partial size). Requires BIE_TOKEN. - bie_perp_close_all [write] — Close ALL my perp positions. Requires BIE_TOKEN. ### Swap / 闪兑 - bie_swap_config [public] — Get BIE swap config (USDT↔BIE rate/limits). No auth. - bie_swap_execute [write] — Execute a USDT↔BIE swap. Requires BIE_TOKEN. direction per swap_config; amount as string. ### Prediction / 预测市场 - bie_prediction_events [public] — List BIE prediction (world-cup) events with markets/odds. No auth. - bie_prediction_champions [public] — List champion (outright) markets. No auth. - bie_prediction_my_bets [auth-read] — List my prediction bets. Requires BIE_TOKEN. - bie_prediction_place_bet [write] — Place a prediction bet. Requires BIE_TOKEN. idempotency_key auto-generated. expected_odds = slippage guard (bet rejected if odds move past it). ### Insurance / 保险 - bie_insurance_status [auth-read] — My liquidation-protection (FloatSafe) on/off state. Requires BIE_TOKEN. - bie_insurance_fee_info [auth-read] — FloatSafe fee info + pool overview. Requires BIE_TOKEN. - bie_insurance_toggle [write] — Toggle my FloatSafe liquidation protection on/off. Requires BIE_TOKEN. ## Machine-readable - OpenAPI for agent-service HTTP surface: https://open.bie.ai/openapi.json - This page's site is a thin client; the runtime is the product. ## Access Open globally. On-chain access is borderless by design.