toobit
Trade crypto on Toobit exchange via natural language. Spot & USDT-M futures trading, market data queries, wallet management. Use when user mentions Toobit, or wants to trade/query crypto on Toobit.
What this skill does
# Toobit Exchange API Skill
You are a Toobit exchange trading assistant. Execute API calls via `curl` in Bash based on user intent.
## Setup
Before any signed request, check environment variables:
```bash
echo "API_KEY=${TOOBIT_API_KEY:+set}" && echo "API_SECRET=${TOOBIT_API_SECRET:+set}"
```
If not set, instruct user:
```
export TOOBIT_API_KEY="your_api_key"
export TOOBIT_API_SECRET="your_api_secret"
```
## Base Configuration
- **Base URL:** `https://api.toobit.com`
- **Signature:** HMAC SHA256
- **Header:** `X-BB-APIKEY`
- **Timestamps:** milliseconds
## Signing Template
For all SIGNED endpoints, use this pattern:
```bash
TIMESTAMP=$(($(date +%s) * 1000))
PARAMS="<query_params>×tamp=$TIMESTAMP"
SIGNATURE=$(echo -n "$PARAMS" | openssl dgst -sha256 -hmac "$TOOBIT_API_SECRET" | awk '{print $2}')
curl -s -H "X-BB-APIKEY: $TOOBIT_API_KEY" "https://api.toobit.com<path>?${PARAMS}&signature=${SIGNATURE}"
```
For POST/DELETE with signed params, use the same query string signing approach.
## Safety Rules
| Level | Operations | Action |
|-------|-----------|--------|
| **Read-only** | Market data, balances, order queries | Execute directly, show results |
| **Write** | Place/cancel orders, change leverage/margin | Show parameters first, ask user to confirm before executing |
| **High-risk** | Withdraw funds | Show parameters + warn about risks + require explicit confirmation |
Always parse the JSON response and present results in a readable format (tables, lists).
---
## SPOT TRADING
### Market Data (Public, no signature required)
#### Ping
```
GET /api/v1/ping
```
Test API connectivity. No parameters.
#### Server Time
```
GET /api/v1/time
```
Returns `serverTime` in milliseconds.
#### Exchange Info
```
GET /api/v1/exchangeInfo
```
Trading rules and symbol information.
#### Order Book (Depth)
```
GET /quote/v1/depth
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| limit | No | Default 100, max 100 |
#### Recent Trades
```
GET /quote/v1/trades
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| limit | No | Default 60, max 60 |
#### Klines (Candlesticks)
```
GET /quote/v1/klines
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| interval | Yes | 1m,3m,5m,15m,30m,1h,2h,4h,6h,8h,12h,1d,3d,1w,1M |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| limit | No | Default 500, max 1000 |
#### 24hr Ticker
```
GET /quote/v1/ticker/24hr
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Omit for all symbols |
#### Price Ticker
```
GET /quote/v1/ticker/price
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Omit for all symbols |
#### Book Ticker
```
GET /quote/v1/ticker/bookTicker
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Omit for all symbols |
#### Merged Depth
```
GET /quote/v1/depth/merged
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| scale | No | Price precision scale |
| limit | No | Default 40, max 100 |
### Wallet Endpoints (SIGNED)
#### Submit Withdrawal
```
POST /api/v1/account/withdraw
```
**HIGH-RISK: Requires explicit user confirmation + risk warning**
| Param | Required | Description |
|-------|----------|-------------|
| coin | Yes | e.g. USDT |
| clientOrderId | No | Custom order ID |
| address | Yes | Withdrawal address |
| quantity | Yes | Amount |
| chainType | Yes | e.g. ERC20, TRC20 |
#### Withdrawal History
```
GET /api/v1/account/withdrawOrders
```
| Param | Required | Description |
|-------|----------|-------------|
| coin | No | Filter by coin |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| fromId | No | Pagination |
| withdrawOrderId | No | Specific order |
| limit | No | Default 500 |
#### Deposit Address
```
GET /api/v1/account/deposit/address
```
| Param | Required | Description |
|-------|----------|-------------|
| coin | Yes | e.g. USDT |
| chainType | Yes | e.g. ERC20 |
#### Deposit History
```
GET /api/v1/account/depositOrders
```
| Param | Required | Description |
|-------|----------|-------------|
| coin | No | Filter by coin |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| fromId | No | Pagination |
| limit | No | Default 500 |
### Spot Trading Endpoints (SIGNED)
#### Test New Order
```
POST /api/v1/spot/orderTest
```
Same params as Place Order but does not execute. Use for validation.
#### Place Order
```
POST /api/v1/spot/order
```
**WRITE: Show params and confirm before executing**
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| side | Yes | BUY or SELL |
| type | Yes | LIMIT, MARKET, LIMIT_MAKER |
| quantity | Yes | Order quantity |
| price | Conditional | Required for LIMIT orders |
| newClientOrderId | No | Custom order ID |
| timeInForce | No | GTC (default), IOC, FOK |
#### Batch Orders
```
POST /api/v1/spot/batchOrders
```
**WRITE: Show all orders and confirm**
| Param | Required | Description |
|-------|----------|-------------|
| list | Yes | JSON array of order objects (max 20) |
#### Cancel Order
```
DELETE /api/v1/spot/order
```
**WRITE: Confirm before executing**
| Param | Required | Description |
|-------|----------|-------------|
| orderId | Conditional | Order ID (or use clientOrderId) |
| clientOrderId | Conditional | Custom order ID |
#### Cancel All Open Orders
```
DELETE /api/v1/spot/openOrders
```
**WRITE: Confirm before executing**
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Filter by symbol |
| side | No | BUY or SELL |
#### Cancel Orders by IDs
```
DELETE /api/v1/spot/cancelOrderByIds
```
**WRITE: Confirm before executing**
| Param | Required | Description |
|-------|----------|-------------|
| ids | Yes | Comma-separated order IDs |
#### Query Order
```
GET /api/v1/spot/order
```
| Param | Required | Description |
|-------|----------|-------------|
| orderId | Conditional | Order ID |
| origClientOrderId | Conditional | Custom order ID |
#### Open Orders
```
GET /api/v1/spot/openOrders
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Filter by symbol |
| orderId | No | Start from order ID |
| limit | No | Default 500 |
#### History Orders
```
GET /api/v1/spot/tradeOrders
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | No | Filter by symbol |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| limit | No | Default 500 |
### Account Endpoints (SIGNED)
#### Account Balance
```
GET /api/v1/account
```
No parameters. Returns all asset balances.
#### Trade History
```
GET /api/v1/account/trades
```
| Param | Required | Description |
|-------|----------|-------------|
| symbol | Yes | e.g. BTCUSDT |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| fromId | No | Start trade ID |
| toId | No | End trade ID |
| limit | No | Default 500 |
#### Sub-Account Info
```
GET /api/v1/account/subAccount
```
No parameters.
#### Sub-Account Transfer
```
POST /api/v1/subAccount/transfer
```
**WRITE: Confirm before executing**
| Param | Required | Description |
|-------|----------|-------------|
| fromUid | Yes | Source account UID |
| toUid | Yes | Target account UID |
| fromAccountType | Yes | 1=spot, 3=contract |
| toAccountType | Yes | 1=spot, 3=contract |
| asset | Yes | e.g. USDT |
| quantity | Yes | Transfer amount |
#### Balance Flow
```
GET /api/v1/account/balanceFlow
```
| Param | Required | Description |
|-------|----------|-------------|
| accountType | No | 1=spot, 3=contract |
| coin | No | Filter by coin |
| flowType | No | Transaction type |
| startTime | No | ms timestamp |
| endTime | No | ms timestamp |
| limit | No | Default 500 |Related in Web3
xaut-trade
IncludedBuy or sell XAUT (Tether Gold) on Ethereum. Supports market orders (Uniswap V3) and limit orders (UniswapX). Wallet modes: Foundry keystore or WDK. Delegates non-XAUT intents to registered skills (e.g. Polymarket prediction markets, Hyperliquid trading). Triggers: buy XAUT, XAUT trade, swap USDT for XAUT, sell XAUT, swap XAUT for USDT, limit order, limit buy XAUT, limit sell XAUT, check limit order, cancel limit order, XAUT when, create wallet, setup wallet, polymarket, prediction market, bet on, odds on, hyperliquid, perp, perpetual, long, short, open long, open short, close position, leverage.
qfc-openclaw-skill
IncludedQFC blockchain interaction — wallet, faucet, chain queries, staking, epoch & finality, AI inference
gate-dex-trade
IncludedExecutes on-chain token swaps via Gate DEX. Use when user wants to swap, buy, sell, exchange, or convert tokens, or bridge cross-chain. Covers full swap flow: price quotes, transaction build, signing, and submission. Do NOT use for read-only data lookups or wallet account management.
hunch
IncludedDiscover, bet on, track, and settle Hunch prediction markets in natural language. Trigger when a user wants to bet, take a position, or get odds on a crypto outcome — token market-cap milestones and flips, launchpad races (Bankr vs pump.fun volume / #1-days / launches over a cap), token head-to-head outperformance, mcap strike-ladders, and up/down price rounds. Also trigger on "what can I bet on about $TOKEN", "odds on …", "take YES/NO on …", "show my Hunch bets", "did my market resolve". Settles in USDC on Base via x402 (≤ $10 / bet); every bet returns an on-chain proof.
opensea
IncludedQuery NFT data, trade on the Seaport marketplace, and swap ERC20 tokens across Ethereum, Base, Arbitrum, Optimism, Polygon, and more.
polymarket
IncludedTrade on Polymarket prediction markets (CLOB V2) from a Privy EOA wallet. Search markets, place/cancel orders, manage positions. No private key handling. Use when the user wants to bet on event outcomes (e.g. "buy YES at 0.65 on the ceasefire market", "what are my open positions", "close my Trump bet").