30 秒內取得匿名自助沙盒金鑰。使用相同的 api.predictasiax.com 主機。受等級限制,因此你做的任何操作都不會動到真實資金。無需電子郵件。
sandbox.predictasiax.com 主機,提供 faucet 與 mock-oracle。自 v2.0.0 (2026-08-19) 起,沙盒位於同一個生產 API 上,透過每個金鑰的 tier=sandbox 旗標,將訂單硬性限制在每筆 $10 及每日 $100。訂單在模擬中成交:金鑰初始擁有 1,000 虛擬 USDT,以等於或高於市場當前價格的買單會以該價格成交,較低的限價單則掛單直到價格達到該水平。回應包含 is_simulated: true;沒有真實資金移動。
任何人,來自任何 IP,無需驗證:
curl -X POST https://api.predictasiax.com/v1/sandbox-keys \
-H "Content-Type: application/json" \
-d '{"org_name":"my-test"}'
回應:
{
"data": {
"sk": "sk_live_abcdef0123...", // this is your bearer — shown ONCE
"api_key_id": "api_sbx_...",
"builder_id": "bld_sbx_...",
"app_id": "app_sbx_...",
"tier": "sandbox",
"caps": {
"max_order_usdt": "10",
"daily_notional_usdt": "100"
},
"expires_at_ms": 1789741484472, // 30 days out
"sandbox_url": "https://api.predictasiax.com",
"docs_url": "https://docs.predictasiax.com/getting-started",
"upgrade_url": "https://docs.predictasiax.com/request-access.html",
"notice": "Sandbox keys expire in 30 days. ..."
}
}
POST /v1/sandbox-keys 的速率限制為 每個 IP 每天 1 次 mint 以及 每個瀏覽器指紋每天 1 次 mint。兩項限制都必須通過。此機制用於防止金鑰濫發。來自已觸發限制來源的後續 mint 請求都會回傳 429 RATE_LIMITED。
| 功能 | 沙盒等級 | 交易上限等級 | Trade-full 等級 |
|---|---|---|---|
| 讀取市場、活躍市場、結算 | 是 | 是 | 是 |
| 讀取自己的持倉與訂單 | 是 | 是 | 是 |
| 下單 | 可以,每筆最高 $10,在模擬環境中成交(1,000 虛擬 USDT) | 是,每筆最高 $100 | 無上限 |
| 每日名目金額上限 | $100 | $1,000 | 無上限 |
| 撤銷訂單 | 是 | 是 | 是 |
| 速率限制 | 各權限範圍的預算,在所有等級中均相同 — 請參閱 速率限制 | ||
| 手續費歸因帳本 | 否(模擬成交不會寫入任何內容至帳本) | 是 | 是 |
| 可歸因於你的應用程式 | 接受歸因標頭;模擬成交不累計任何數值 | 是 | 是 |
| 到期 | 自鑄幣起 30 天 | 永續 | 永續 |
API 上的其他所有功能運作方式相同。訂單會經過與生產環境相同的驗證與等級上限檢查,然後在模擬環境中成交,而非真實訂單簿。每個金鑰初始擁有 1,000 虛擬 USDT。以等於或高於市場當前價格的買單會立即以該價格成交;較低的限價單會掛單,將其金額保留在 reserved_usdt 中,並在價格達到該限價時成交(無論金鑰何時讀取 /v1/orders、/v1/positions、/v1/balance 或 /v1/portfolio 都會進行檢查)。取消訂單會退回保留金額。所有模擬回應的 data 和 meta 中都會包含 is_simulated: true;不會影響真實餘額或手續費帳本。持倉會按當前價格標記,且當市場結算時不會進行結算,也沒有 faucet、reset 或存款端點。真實成交需要生產環境金鑰(請參閱 從沙盒升級)。
# List markets
curl https://api.predictasiax.com/v1/markets \
-H "Authorization: Bearer $SK"
MARKET_ID=... # an "id" from the list
# Place a $1 order (well within $10 cap)
curl -X POST https://api.predictasiax.com/v1/orders \
-H "Authorization: Bearer $SK" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: my-first-order-$(date +%s)" \
-d '{
"market_id": "'"$MARKET_ID"'",
"side": "yes",
"price": "0.55",
"size": "2",
"client_order_id": "cli-001"
}'
# → 201, simulated fill at the market's current price (or status "open" if your limit is lower):
# {"data": {"order_id": "sbx_ord_...", "status": "filled", "fill_price": "0.42", ...,
# "is_simulated": true}, "meta": {..., "is_simulated": true}}
# Virtual balance and positions
curl https://api.predictasiax.com/v1/balance -H "Authorization: Bearer $SK"
curl https://api.predictasiax.com/v1/positions -H "Authorization: Bearer $SK"
# Order over $10 → 429 TIER_LIMIT_EXCEEDED with detail:
# { "tier": "sandbox", "cap": "10" }
沙盒旨在提供零摩擦的探索體驗。當你準備好導入真實用戶流程時,沒有審查佇列、NDA 或核准步驟:
sk_live_* 金鑰,等級為 self_serve。無需人工審核,無需簽署 NDA。self_serve → read_live ($100) → trade_capped ($1,000) → trade_full ($50,000) → partner ($1,000,000),每個等級皆為 admin_signoff: false。genesis 是實時前 20 名交易量排行榜,自動授予——絕非申請制。請參閱 等級運作方式。sk_live_* 前綴,並指向 api.predictasiax.com/v1。金鑰上的 tier 旗標控制功能範圍 — sandbox 將每筆訂單限制在 $10、每日 $100,並針對 1,000 虛擬 USDT 進行模擬成交;較高的信任等級會提高你的每筆訂單與每日名目金額上限(見上表)。各等級的請求速率限制完全相同 — 提升等級不會改變你的請求速率。透過自動交易量階梯提升等級 — 無需修改程式碼,無需切換主機。