Skip to main content
POST
Create a bot

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
exchanges
enum<string>[]
required

Venues the pair legs may be opened on; each pair uses two of them

Minimum array length: 2

Supported perpetual exchange

Available options:
aster,
binance,
bybit,
extended,
gate,
hyperliquid,
lighter,
mexc,
ondo,
robinhood
leverage
integer
required

Leverage per leg, capped by each market limit

Required range: x <= 9007199254740991
Example:

2

maxRoundTripCostBps
number
required

Most a round trip (entry plus exit, fees and book crossing) may cost, in basis points of the notional; pairs are ranked by expected funding over the hold minus this cost

Example:

12

notionalUsd
number
required

Notional per leg in USD

Example:

500

categories
enum<string>[]

Asset classes to trade; omit to trade every category

Minimum array length: 1

Asset class of the market

Available options:
commodities,
crypto,
etf-index,
forex,
pre-ipo,
stocks-asia,
stocks-us
maxHoldHours
number
default:24

Longest time to hold a pair before closing it even while the spread still pays; low for frequent rolls, high for carry

requiredExchange
enum<string>

Venue one leg of every pair must be on; omit to let any two venues pair up

Available options:
aster,
binance,
bybit,
extended,
gate,
hyperliquid,
lighter,
mexc,
ondo,
robinhood

Response

config
BotConfig · object | null
required

Bot configuration, applied by the runner on its next poll; null when the stored configuration no longer matches the current schema and the bot must be recreated.

createdAt
string<date-time>
required

When the bot was created.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$
id
string
required

Bot identifier.

Pattern: ^[1-9]\d*$
Example:

"12"

lastError
string | null
required

Why the bot halted, or null when it has never halted.

state
BotState · object | null
required

What the runner is doing with this bot: the pair it holds and the order it waits on; null while the bot is flat, has never run, or its stored state no longer matches the current schema.

status
enum<string>
required

running — the bot executes scheduled ticks. not_started — it has never been started, or you stopped it. halted — it hit a state it will not act on and stopped itself; lastError says which.

Available options:
halted,
not_started,
running
updatedAt
string<date-time>
required

When the bot last changed.

Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$