Skip to Content
NeurotraderDocs
Reference

API reference

Every operation of the engine's HTTP API, version 0.1.0-alpha.5, with its parameters, bodies and responses.

The local engine's HTTP surface, served on loopback only. Every route but GET /v1/health sits behind bearer-token verification. Non-resource replies use the Standard envelope (result/message/details/timestamp).

This page describes version 0.1.0-alpha.5 of the API.

Address

  • http://127.0.0.1: Loopback only; the port(s) come from server.hosts in config.yaml

Authentication

A Cognito access token (token_use == "access"). Every route but GET /v1/health requires one. The websocket upgrade at /v1/events takes the same token via Sec-WebSocket-Protocol: v1.updates.neurotrader, auth.bearer.<token> because browsers cannot set Authorization on a handshake.

See Authentication for how a client obtains a token.

Health

Liveness, unauthenticated

GET /v1/health

Liveness, and the one version a client can read without a credential.

Authentication: none.

Responses

StatusBodyDescription
200HealthResponse (application/json)The engine is up

Info

What this binary is

GET /v1/info

The facts about this binary: version, commit, build, target.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200InfoResponse (application/json)Unknown values are null, never omitted

Catalog

The asset catalog: assets, tickers and venues, and the venues a live source streams from

GET /v1/asset

Every asset in the catalog, optionally narrowed by type.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
typequerystringNoAn asset type: fiat, crypto, stock, etf or fund

Responses

StatusBodyDescription
200array of object (application/json)Assets, as neurotrader_market_data::Asset serializes
400string (text/plain)Unknown type value

GET /v1/ticker

Every ticker in the catalog, narrowed by any combination of filters, or found by text.

Filters intersect; they never union. base and quote are asset ids; market, broker and provider are the catalog's enum names. A ticker that reached the catalog through a data provider has no broker, so broker=… never matches one.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
qquerystringNoText search over symbols and asset names, case-insensitive, ranked: exact symbol, symbol prefix, the base asset's symbol, then its name. At most 200 hits, before the other filters narrow them
symbolquerystringNoThe provider's symbol, exactly, case included, e.g. BTCEUR. Unique only together with provider and market
basequerystringNoBase asset id
quotequerystringNoQuote asset id
marketquerystringNoVenue code, e.g. XNAS or binance; see GET /v1/venue
brokerquerystringNoBroker enum name
providerquerystringNoHistorical data provider enum name

Responses

StatusBodyDescription
200array of object (application/json)Tickers, as neurotrader_market_data::Ticker serializes, each with a coverage object beside its fields: intervals (the SDK's codes), from (earliest date, or null to ask the provider) and live
400string (text/plain)Unknown enum value, named in the body

GET /v1/venue

Every venue the catalog lists.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of object (application/json)Venues, as neurotrader_market_data::Venue serializes: code (ISO 10383 MIC where one exists, else a lowercase code of the catalog's own), name, mic, country

GET /v1/venue/live

Every venue a live data source can stream from.

Not the catalog's venues and not GET /v1/ticker's provider (the historical data provider): these are the values a live data source's venue takes. Each names the catalog market its tickers must be listed on, so a client can offer only the pairs a venue streams.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of LiveVenueView (application/json)Every quant::data::LiveVenue, in the order a client lists them

Runner

Runners: create, configure, operate

GET /v1/runner

Every runner the engine holds.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
typequerystringNoall, simulation, or live (any live kind — today paper); anything else is refused

Responses

StatusBodyDescription
200array of object (application/json)Runners, as core::runner::Runner serializes
400Standard (application/json)Invalid type

POST /v1/runner

Creates a runner, bare or whole.

The body is a RunnerDescription: a type tag (simulation | multi_simulation | sweep_simulation | paper | multi_paper | sweep_paper) over a SimulationDescription — name, broker account (initial_holdings, mandatory primary_quote_asset, fees), and optionally the same data and algorithms payloads the incremental routes take — or the venue tag over a VenueDescription: name, venue, environment (demo is the one offered in this release), credential (the name of a stored secret, never the secret), primary_quote_asset, and the same optional data and algorithms. The tag alone decides the kind and the arrangement. The sweep_ tags make an instrument sweep: the multi_ arrangement, with sweep: true on the runner, and a run is refused unless every instance runs the same algorithm with the same parameters over exactly one data source of its own, all at one interval. Creation checks that the primary quote asset is funded and that any inline data source matches the kind (the simulation tags take only historical sources, the paper tags only live), and nothing else; a runner that cannot yet run is accepted exactly as the incremental routes leave one. The one plan question asked here: multi_simulation and sweep_simulation need the lease feature runs.multi, refused with 403 feature_not_in_plan (details.feature). With entitlement configured, the caller's token first mints or refreshes the lease where that is due, so a freshly enrolled engine is not refused for a lease nobody has asked for yet; a refusal comes only from what then stands on disk, as the device routes' own (404 not_enrolled, 409 lease_unusable). multi_paper and sweep_paper are live runners and do not need the feature.

Authentication: an access token. See Authentication.

Request body

object (application/json), required.

A core::runner::RunnerDescription

Responses

StatusBodyDescription
201object (application/json)The created runner, as core::runner::Runner serializes
403Standard (application/json)The plan lacks a feature the runner needs; details.reason is feature_not_in_plan and details.feature names it
404Standard (application/json)Entitlement is configured and this engine is not enrolled: details.reason is not_enrolled
409Standard (application/json)No usable lease: details.reason is lease_unusable
500Standard (application/json)Refused, with the reason in details.error

GET /v1/runner/{id}

One runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id

Responses

StatusBodyDescription
200object (application/json)The runner, as core::runner::Runner serializes
404Standard (application/json)No such runner

PATCH /v1/runner/{id}

Updates a runner's own fields — name, favourite, broker configuration.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id

Request body

object (application/json), required.

A core::runner::RunnerUpdate: a type tag (simulation | paper, which must name the runner's own kind) over the fields to change

Responses

StatusBodyDescription
204NoneUpdated
404Standard (application/json)No such runner, or the update was refused

DELETE /v1/runner/{id}

Deletes a runner and everything it recorded.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id

Responses

StatusBodyDescription
204NoneDeleted
404Standard (application/json)No such runner

GET /v1/runner/{simulation_id}/algorithm

The algorithm instances a runner binds.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id

Responses

StatusBodyDescription
200array of object (application/json)Instances, as AlgorithmInstance serializes
404Standard (application/json)No such runner

POST /v1/runner/{simulation_id}/algorithm

Adds an algorithm instance to a runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id

Request body

object (application/json), required.

An AlgorithmDescription: the algorithm definition id, the data source ids it consumes, and its parameters

Responses

StatusBodyDescription
201Standard (application/json)Added; details.algorithm_instance_id names the instance
400Standard (application/json)Refused, with the reason in details.error

PATCH /v1/runner/{simulation_id}/algorithm/{algorithm_id}

Changes one algorithm instance: its data sources or its parameters.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id
algorithm_idpathstring (uuid)YesAlgorithm instance id

Request body

ChangeAlgorithmRequest (application/json), required.

Responses

StatusBodyDescription
202NoneChanged
204Standard (application/json)Runner or instance not found (historical quirk: reported as 204 with an error envelope)
500Standard (application/json)The change could not be persisted

DELETE /v1/runner/{simulation_id}/algorithm/{algorithm_id}

Removes an algorithm instance from a runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id
algorithm_idpathstring (uuid)YesAlgorithm instance id

Responses

StatusBodyDescription
204NoneRemoved
400Standard (application/json)Refused, with the reason in details
404Standard (application/json)No such runner

POST /v1/runner/{simulation_id}/data

Adds a data source to a runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id

Request body

object (application/json), required.

A quant::data::DataSourceDescription: a type tag (historical, with ticker, interval and range, or live, with ticker, interval and venue). A simulation takes only historical sources, a paper runner only live ones

Responses

StatusBodyDescription
201string (uuid) (text/plain)The minted data source id
400Standard (application/json)Refused, with the reason in details.error

DELETE /v1/runner/{simulation_id}/data

Removes data sources from a runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id

Request body

array of string (uuid) (application/json), required.

The data source ids to remove

Responses

StatusBodyDescription
204NoneRemoved
400Standard (application/json)Refused, with the reason in details.error

POST /v1/runner/{simulation_id}/operate

Starts, stops, pauses, resumes or resets a runner.

start and resume answer 200 with the run's context id in details.context; stop and pause answer 202 — the run winds itself down, and clients watch the runner's event topic for the state_change. Starting a runner may first fill the data store, which needs the caller's bearer token to forward to the Data Plane. The same token mints or refreshes the lease the plan is read off, where that is due, before a backtest is gated on it.

The body is the bare operation word ("stop") or the object OperateRunnerBody. Stopping a live runner needs the object with a disposition: close cancels its working orders and flattens what its fills opened, leave lets them stand; the engine has no default, and a live stop without one is a 400 with details.reason disposition_required. The run's topic then carries a stopped payload with what the stop did, and the run record keeps it as stop.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
simulation_idpathstring (uuid)YesRunner id

Request body

object (application/json), required.

The operation word as a bare JSON string ("start", "stop", "pause", "resume", "reset"), or an OperateRunnerBody object; a live runner's stop needs the object with disposition close or leave

Responses

StatusBodyDescription
200Standard (application/json)Started / resumed / reset; for start and resume details.context is the run id
202Standard (application/json)Stopping / pausing; watch the runner's event topic. For a live stop details.disposition echoes what was asked
400Standard (application/json)A live runner's stop without a disposition: details.reason is disposition_required
403Standard (application/json)Start or resume of a backtest the plan does not allow: details.reason is feature_not_in_plan, details.feature the catalogue key
404Standard (application/json)No run in progress, or no paused run; or, on start and resume with entitlement configured, this engine is not enrolled (details.reason not_enrolled)
409Standard (application/json)The runner is paused; resume or stop it before starting. Or, on start and resume, no usable lease (details.reason lease_unusable). Or, on start, the runner as configured cannot run (details.reason not_runnable, details.message the refusing check's own words: a sanity check, a credential issued for another environment than the runner declares, an algorithm that could not be built)
429Standard (application/json)As many runs of this kind are executing as the plan allows: details.reason is concurrent_runs_exhausted for a backtest and live_runners_exhausted for a live runner, with details.limit and details.running. The two are counted apart
500Standard (application/json)The operation failed

Live

The active run, addressed by its runner — doc/09. live-view.md

POST /v1/live/stop

Stops every active live run at once, Live Simulation and venue-backed alike, with one disposition (doc/08. live-modes.md section 6.2). Backtests are not touched. The answer waits for each run to act on the disposition and lists what its stop did: the orders cancelled, flattened, left standing and failed, or why nothing was reported. An empty runs list means nothing live was active.

Authentication: an access token. See Authentication.

Request body

StopAllRequest (application/json), required.

Responses

StatusBodyDescription
200object (application/json)disposition as asked and runs, one entry per live run: runner_id, run_id, and outcome (disposition, cancelled, flattened, failed as {order, reason}, left, optional error) or error when the run reported nothing within its grace
400NoneNo disposition, or one that is not close or leave

GET /v1/live/{id}

The runner's active live run: the in-flight record a client starts from.

run_id is the topic of the run's step stream; history_from/history_to is the span the in-memory history covers, which the three routes below answer from. Nothing here is on disk: the record exists exactly as long as the run is registered, so every route of this family answers 404 the moment nothing live is in progress — and for a backtest, which has no view.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id

Responses

StatusBodyDescription
200object (application/json)The in-flight record, as core::runner::runner_controller_live::LiveRecord serializes: run_id, runner_id, clock, started_at, steps, history_from, history_to, warm_up (per instance: fed, warm, cold_reason), data, algorithms
404Standard (application/json)No such runner, no run in progress, or the run in progress is a backtest

GET /v1/live/{id}/account

Every account event of one instance of the active live run, out of its in-memory history — the same response as …/run/{run_id}/account, over the ring's events. Empty on a spot account.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
algorithmquerystring (uuid)YesAlgorithm instance id
fromquerystringNoISO 8601 instant ending in Z; clamped to the history's span
toquerystringNoISO 8601 instant ending in Z; clamped to the history's span
kindquerystringNoComma-separated kinds to keep; omit for every kind

Responses

StatusBodyDescription
200object (application/json)The list, as core::runner::run_account::AccountList serializes
400Standard (application/json)Malformed query
404Standard (application/json)No such runner, no live run in progress, or no such instance

GET /v1/live/{id}/actions

Every order one instance of the active live run issued on one ticker, folded to one entry each — the same response as …/run/{run_id}/actions.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
algorithmquerystring (uuid)YesAlgorithm instance id
tickerquerystring (uuid)YesWhich of that algorithm's tickers the orders were on
fromquerystringNoISO 8601 instant ending in Z; matched against an order's submission
toquerystringNoISO 8601 instant ending in Z

Responses

StatusBodyDescription
200object (application/json)The order list, as core::runner::run_actions::ActionList serializes, each order with its leverage and the margin_level it was submitted at
400Standard (application/json)Malformed query
404Standard (application/json)No such runner, no live run in progress, or no such instance

GET /v1/live/{id}/data

The candles and indicator series of the active live run, out of its in-memory history.

The same response as …/run/{run_id}/data. from/to default to the history's span and are clamped to it; limit keeps the newest that many candles of the window — a chart opens with the latest candle and N before it, then pages back by moving to to the oldest shown.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
algorithmquerystring (uuid)YesAlgorithm instance id
tickerquerystring (uuid)YesWhich of that algorithm's tickers to chart
intervalquerystringYesCanonical interval spelling; may be coarser than the run's cadence, never finer
fromquerystringNoISO 8601 instant ending in Z; defaults to the history's span
toquerystringNoISO 8601 instant ending in Z; defaults to the history's span
limitqueryintegerNoKeep only the newest that many candles of the window

Responses

StatusBodyDescription
200object (application/json)The candle series with indicators, as core::runner::run_data::CandleSeries serializes
400Standard (application/json)Malformed query, or one this run cannot answer
404Standard (application/json)No such runner, or no live run in progress

GET /v1/live/{id}/performance

The equity curve so far of one instance of the active live run — the same query, paging and response as …/run/{run_id}/performance, the margin figures and their bucket rules included; a spot runner answers 400 to those.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
algorithmquerystring (uuid)YesAlgorithm instance id
resolutionquerystringYesCanonical interval spelling; may be coarser than the run's cadence, never finer
fromquerystringNoISO 8601 instant ending in Z; a cursor from a previous page
directionquerystringNoforward (default) or backward
limitqueryintegerNoPoints per page, 1 to 5000; 1000 by default
typequerystringNoComma-separated, in the order wanted: percent (default), asset, both, liabilities, margin_level; the last two on a margin account only

Responses

StatusBodyDescription
200object (application/json)The performance series, as core::runner::performance::PerformanceSeries serializes; points are arrays as wide as type, margin_level as null while nothing is owed, reductions per column
400Standard (application/json)Malformed query, or one this run cannot answer
404Standard (application/json)No such runner, no live run in progress, or no such instance

Run

A runner's recorded runs and their output

GET /v1/runner/{id}/run

Every recorded run of a runner.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id

Responses

StatusBodyDescription
200array of object (application/json)Run records: each pairs the run's info.json (ExecutionInfo) with its results.json (RunResults)
404Standard (application/json)No such runner

GET /v1/runner/{id}/run/{run_id}

One recorded run.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id

Responses

StatusBodyDescription
200object (application/json)The run record (ExecutionInfo + RunResults)
404Standard (application/json)No such run

PATCH /v1/runner/{id}/run/{run_id}

Edits a run's label and tags. Absent fields are left untouched; tags replaces the whole list.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id

Request body

UpdateRunRequest (application/json), required.

Responses

StatusBodyDescription
204NoneUpdated
404Standard (application/json)No such run, or the run is paused

DELETE /v1/runner/{id}/run/{run_id}

Deletes one run — its whole output directory, and nothing else.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id

Responses

StatusBodyDescription
204NoneDeleted
404Standard (application/json)No such run
409Standard (application/json)The run is still in progress; stop it first
500Standard (application/json)The deletion failed

GET /v1/runner/{id}/run/{run_id}/account

The account journal of one algorithm instance: every loan, repayment, interest charge, margin call raised or cleared, liquidation and bankruptcy, each with the account after it (doc/13. margin-and-leverage.md §9).

Rows come back ascending by seq, each as trading::journal::AccountEvent serializes — the same row the live step frames quote — with margin_level as null while nothing is owed. asset_id is the runner's primary quote asset, which assets, liabilities and equity are in. Neither paged nor capped: a levered run writes an interest_charged row every candle, so kind is how a client asks for the calls and liquidations alone. A spot run has no account journal and answers an empty list, not 404: the account exists and nothing happened to it.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id
algorithmquerystring (uuid)YesAlgorithm instance id
fromquerystringNoISO 8601 instant ending in Z, inclusive, matched against the row's timestamp
toquerystringNoISO 8601 instant ending in Z, exclusive, matched against the row's timestamp
kindquerystringNoComma-separated kinds to keep: borrowed, repaid, interest_charged, margin_call, margin_call_cleared, liquidation, bankruptcy; omit for every kind

Responses

StatusBodyDescription
200object (application/json)The list, as core::runner::run_account::AccountList serializes: algorithm_id, asset_id, from, to, kinds (echoed, or null), events (each: sequence, timestamp, algorithm, kind, asset, amount, order, assets, liabilities, equity, margin_level or null)
400Standard (application/json)Malformed query
404Standard (application/json)No such run or instance, or the run is paused
500Standard (application/json)The read failed

GET /v1/runner/{id}/run/{run_id}/actions

Every order one algorithm instance issued on one ticker, rolled up to one entry each.

Neither paged nor capped: the response grows with how much the algorithm traded. Each entry carries, from the order's first journal row, leverage (the order's own; 1 on a spot order, so a levered order is told apart by it) and margin_level (the account's when the order was submitted; null while nothing was owed, and on a journal written before margin existed).

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id
algorithmquerystring (uuid)YesAlgorithm instance id
tickerquerystring (uuid)YesWhich of that algorithm's tickers the orders were on
fromquerystringNoISO 8601 instant ending in Z, matched against submission
toquerystringNoISO 8601 instant ending in Z, matched against submission

Responses

StatusBodyDescription
200object (application/json)The order list, as core::runner::run_actions::ActionList serializes: actions (one OrderAction per order, leverage and margin_level included), round_trips, unattributed_quantity
400Standard (application/json)Malformed query, or one this run cannot answer
404Standard (application/json)No such run, or the run is paused
500Standard (application/json)The read failed

GET /v1/runner/{id}/run/{run_id}/data

The candles one algorithm instance saw for one ticker, with its indicator series folded onto the same buckets.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id
algorithmquerystring (uuid)YesAlgorithm instance id
tickerquerystring (uuid)YesWhich of that algorithm's tickers to chart
intervalquerystringYesCanonical interval spelling; may be coarser than the run's cadence, never finer
fromquerystringNoISO 8601 instant ending in Z; defaults to the run's own range
toquerystringNoISO 8601 instant ending in Z; defaults to the run's own range
directionquerystringNoWhich end of the window limit counts from: forward (default) keeps the oldest candles, backward the newest
limitqueryinteger (int32)NoAt most this many candles, counted from the end direction names; omit for the whole window

Responses

StatusBodyDescription
200object (application/json)The candle series with indicators
400Standard (application/json)Malformed query, or one this run cannot answer
404Standard (application/json)No such run, or the run is paused
500Standard (application/json)The read failed

POST /v1/runner/{id}/run/{run_id}/operate

Stops one specific run. Only stop applies here; everything else is runner-level. A live run's stop needs a disposition, as on the runner-level route.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id

Request body

object (application/json), required.

"stop", or an OperateRunnerBody with operation stop and, for a live run, disposition close or leave

Responses

StatusBodyDescription
202Standard (application/json)Stopping; watch the runner's event topic
400Standard (application/json)The command is not applicable to a single run, or a live run's stop carries no disposition (details.reason disposition_required)
404Standard (application/json)No run in progress with this id
500Standard (application/json)The stop failed

GET /v1/runner/{id}/run/{run_id}/performance

One algorithm instance's equity curve for a run.

Points are valued in the runner's primary quote asset — there is no denominator to ask for. Paused runs answer 404: their output is parked, not merged.

type names the figures each point carries, comma-separated and in the order wanted: percent (the default), asset (equity), both (the two, in that order), and on a margin account liabilities and margin_level. A spot run, or a timeline written before margin existed, answers 400 to the two margin figures rather than a column of zeroes. Each point is an array as wide as the list, timestamp first; margin_level is null while nothing is owed. A resolution bucket reduces to one row per figure: the last row for percent and asset, the lowest row for margin_level and the highest for liabilities, so the curve shows how close the account came to the call bar inside the period rather than where it closed; the response states the rule per column in reductions.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id
algorithmquerystring (uuid)YesAlgorithm instance id — a key of the runner's algorithms, not a definition id
resolutionquerystringYesCanonical interval spelling: 1m, 1h, 1d, 1w, 1mo, …
fromquerystringNoISO 8601 instant ending in Z; omitted on the first page
directionquerystringNoforward (default) or backward
limitqueryinteger (int32)NoPoints per page, clamped to the server's maximum
typequerystringNoWhat each point states, comma-separated and in the order wanted: percent (default), asset, both, liabilities, margin_level; the last two on a margin account only

Responses

StatusBodyDescription
200object (application/json)The series, as core::runner::performance::PerformanceSeries serializes: type echoed, asset_id, reductions (per column: last, lowest or highest), and points as arrays as wide as type, timestamp first, margin_level as null while nothing is owed
400Standard (application/json)Malformed query, or one this run cannot answer
404Standard (application/json)No such run, or the run is paused
500Standard (application/json)The read failed

POST /v1/runner/{id}/run/{run_id}/restore

Restores the runner's parameters from the snapshot stored with one of its past runs.

Config, data sources and algorithms only — never name, status, favourite or identity. No body: the run id says everything.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesRunner id
run_idpathstring (uuid)YesRun (execution context) id

Responses

StatusBodyDescription
200object (application/json)The runner as it now stands, same shape as GET /v1/runner/{id}
404Standard (application/json)No such run
409Standard (application/json)The runner has a run in flight
500Standard (application/json)The restore failed

Algorithm

The algorithms the engine knows about

GET /v1/algorithms

Every algorithm the engine knows about, and whether each can actually run.

Each entry is a flattened algorithm Definition plus available: bool. false means the algorithm's library is registered and did not load this start — it does not mean unknown; an unknown algorithm is simply absent.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of object (application/json)Sorted by name

Repository

The local market-data store and downloads into it

GET /v1/repository

What the local store holds, per ticker: provider, symbol, and the contiguous ranges on disk.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of object (application/json)RepositoryInfo records, keyed by ticker
500string (text/plain)The store could not be read

POST /v1/repository

Starts a download into the store, through the Data Plane.

The caller's bearer token is forwarded — every Data Plane request needs it alongside the lease the engine mints against it. The reply's details.topic is the job id to subscribe to on /v1/events for progress.

Authentication: an access token. See Authentication.

Request body

CreateRepositoryRequest (application/json), required.

Responses

StatusBodyDescription
201Standard (application/json)Task created; details.topic is the event topic
500Standard (application/json)The download could not be started

GET /v1/repository/job

Every download job this engine remembers: running ones first, then the finished ones it has kept (the most recent 256), newest first.

What a client that reloaded reads to find the downloads it started. Each job's topic is its id, and its progress fields repeat the last DataEvent published there — the socket is the hint, this is the state.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of JobResponse (application/json)Running first, then finished, newest first

GET /v1/repository/job/{id}

One download job, by the id POST /v1/repository answered with.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesThe job id, which is also its event topic

Responses

StatusBodyDescription
200JobResponse (application/json)The job
404Standard (application/json)No such job: it never ran here, or was pruned

Secret

Credentials in the platform key store; nothing is ever read back

GET /v1/secret

Every secret the engine knows how to hold: its form, and whether it is stored.

Nothing here — or anywhere — reads a credential back; the only fact reported about a stored secret is that it is stored.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of SecretStatus (application/json)One status per known secret
503Standard (application/json)The platform key store could not be asked

GET /v1/secret/{name}

One secret's form and whether it is stored.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
namepathstringYesThe secret's name, e.g. binance.credentials

Responses

StatusBodyDescription
200SecretStatus (application/json)The status
404Standard (application/json)No secret goes by that name
503Standard (application/json)The platform key store could not be asked

PUT /v1/secret/{name}

Stores a filled-in form, replacing whatever was there.

The body is the secret's own fields, as the form describes them — a bare JSON object, never echoed and never logged.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
namepathstringYesThe secret's name, e.g. binance.credentials

Request body

object (application/json), required.

The fields the secret's form declares

Responses

StatusBodyDescription
200Standard (application/json)Stored
400Standard (application/json)The form was wrong, or the platform refused it
404Standard (application/json)No secret goes by that name
409Standard (application/json)Something is stored and cannot be used; clear and re-enter
503Standard (application/json)The platform key store could not be asked

DELETE /v1/secret/{name}

Clears a stored secret.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
namepathstringYesThe secret's name, e.g. binance.credentials

Responses

StatusBodyDescription
200Standard (application/json)Cleared
404Standard (application/json)No secret goes by that name, or nothing was stored
503Standard (application/json)The platform key store could not be asked

POST /v1/secret/{name}/api-key

Completes a generated credential with the API key the venue issued for its public half.

The body is never echoed and never logged.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
namepathstringYesThe secret's name

Request body

ApiKeyRequest (application/json), required.

Responses

StatusBodyDescription
200Standard (application/json)Completed
404Standard (application/json)No secret goes by that name, or nothing is stored
409Standard (application/json)The stored credential is not awaiting an API key, or the key cannot be taken
503Standard (application/json)The platform key store could not be asked

POST /v1/secret/{name}/generate

Generates an Ed25519 key pair for the venue and stores the private half under the secret's name, replacing whatever was there.

The answer is the public half as PEM, for the user to register on the venue's API management page; the private half goes from the generator into the key store and nowhere else, which is the reason the engine generates the pair rather than taking one. The credential then awaits its API key (awaiting_api_key on its status) and is not usable until POST .../api-key completes it. Only binance.credentials has a generator.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
namepathstringYesThe secret's name; binance.credentials is the one with a generator

Request body

GenerateRequest (application/json), required.

Responses

StatusBodyDescription
201GeneratedKey (application/json)The public half of the generated pair
404Standard (application/json)No secret goes by that name
503Standard (application/json)The platform key store could not be asked

Device

Enrolment: this engine is the device

GET /v1/device

Where this engine stands: enrolment, entitlement view, seats.

Answers 200 even when no entitlement server is configured or the configured one is unreachable — unavailable says so — because "not enrolled" and "cannot currently say" call for different screens.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200object (application/json)configured, enrolled, belongs_to_caller, holds_key, the device record, the entitlement view, the account's devices
502Standard (application/json)The Entitlement Server refused or could not be reached; details.reason carries its reason

POST /v1/device

Enrols this engine, spending one of the account's seats. The engine is the device: it generates the keypair, and the caller's bearer token names the account.

Authentication: an access token. See Authentication.

Request body

EnrolRequest (application/json), required.

Optional; only the label is the client's to say

Responses

StatusBodyDescription
200object (application/json)The enrolled device: id, label, platform, client version, key algorithm, state
502Standard (application/json)The Entitlement Server refused; details.reason carries its reason (out of seats, not entitled, …)

DELETE /v1/device

De-enrols this engine. The seat is released into the server's cooldown, and the local key material is forgotten.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200Standard (application/json)De-enrolled; details.seats is the seat position left behind
502Standard (application/json)The Entitlement Server refused or could not be reached

POST /v1/device/lease

Mints or refreshes the entitlement lease, installing the cache keys it carries into RAM.

The lease envelope itself is deliberately absent from the answer — it is a credential the Data Plane accepts, and a client holding one could present it without this engine.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200object (application/json)plan, features, expires_at, not_after, epoch, cache_readable
502Standard (application/json)The Entitlement Server refused or could not be reached

Billing

Changing the plan this account is on

GET /v1/billing/plans

The plan menu a purchase page is drawn from: every plan on sale, in catalogue order.

Relayed from the Entitlement Server's GET /v1/plans with the caller's token, and not in the standard envelope: the 200 body is that service's document unchanged, \{ amounts_available, plans: [\{ key, display_name, features, quotas, seats, prices: [\{ id, interval, amount?, currency? \}] \}] \}, described in its doc/API.md, "The plan menu". amounts_available: false means the provider could not be asked; the plans are still listed and buying still works. To buy, send a plan's key and a price's interval to POST /v1/billing/session.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200object (application/json)The Entitlement Server's plan menu, unchanged
401Standard (application/json)The Entitlement Server would not take the token (unauthenticated, expired_token); relayed with its reason
501Standard (application/json)This engine has no entitlement server configured (entitlement_not_configured)
503Standard (application/json)The menu cannot be read right now: the Entitlement Server could not be reached or answered a 5xx. details.reason keeps its reason where it gave one

POST /v1/billing/session

Opens a checkout or management page at the payment provider, and starts watching for the plan to move.

200, not 201: the page was created by the Entitlement Server. The URL leaves in this response and is retained nowhere — a portal link is spent when followed. details.topic is the session's event topic.

Authentication: an access token. See Authentication.

Request body

SessionRequest (application/json), required.

Optional; no body means "manage what I have"

Responses

StatusBodyDescription
200Standard (application/json)details.url to open, its kind, the topic to watch, and expires_at when the provider set one
400Standard (application/json)Relayed from the Entitlement Server with its reason. interval_required (the plan is sold at several intervals and none was named) and unknown_interval (it is not sold at the one named) carry details.details.plan_key and details.details.intervals, the intervals the plan is sold at
429Standard (application/json)A session is already in flight; Retry-After says when to ask again
502Standard (application/json)The Entitlement Server refused or could not be reached

GET /v1/billing/session/{session_id}

What became of one plan change — the fallback for a client that reloaded and lost its websocket. No url field, in any state.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
session_idpathstring (uuid)YesThe session id POST /v1/billing/session handed back as topic

Responses

StatusBodyDescription
200Standard (application/json)state, requested_plan, plan_before, plan_after, kind, timestamps, reason
404Standard (application/json)No such session

The legal documents a user must agree to, relayed to the Entitlement Server

Records the caller's agreement to the documents named, and answers with the standing afterwards.

The user agent is taken from this request; a client cannot supply its own origin, and anything it sends as remote_addr or user_agent is ignored.

Authentication: an access token. See Authentication.

Request body

LegalAcceptance (application/json), required.

Responses

StatusBodyDescription
200LegalStanding (application/json)Recorded; the body is the standing afterwards
400Standard (application/json)A document this deployment does not declare (unknown_legal_document), or an unreadable body
409Standard (application/json)The version accepted is no longer in force (legal_version_stale); details.details.current_version names the one that is
501Standard (application/json)This engine has no entitlement server configured (entitlement_not_configured)
503Standard (application/json)Nothing was recorded: the Entitlement Server could not be reached or would not take the call

The legal documents in force, and where the caller's account stands against each. Relayed to the Entitlement Server with the caller's token; nothing is cached or decided here.

Reachable on an engine that is not enrolled: consent comes before a seat is spent.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200LegalStanding (application/json)The documents in force and this account's position against each
501Standard (application/json)This engine has no entitlement server configured (entitlement_not_configured)
503Standard (application/json)The standing cannot be checked right now. Never a statement that the caller has not agreed

Plugin

The algorithm plugin catalog: upload, link, load, unload, build, remove

GET /v1/plugin

Every catalogued plugin, with the state this process holds it in.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200array of PluginResponse (application/json)The catalog

Links a Rust project on the engine's machine and starts its first build.

Answers before the build runs, with the entry in the building state. The outcome lands in the entry's state and on the catalog topic: build_started, build_finished with the log's tail, then loaded or failed. The whole log is in the plugin's build.log. The build command runs as the engine's user; under an installed Windows service that user has no toolchain, and the failure says so.

Authentication: an access token. See Authentication.

Request body

LinkPluginRequest (application/json), required.

Responses

StatusBodyDescription
202PluginResponse (application/json)Linked; building
400Standard (application/json)invalid_project_dir, not_a_rust_project or invalid_name
409Standard (application/json)plugin_exists
500Standard (application/json)catalog_unwritable

POST /v1/plugin/reload

Reloads every plugin that is neither in use nor being built, and reports what happened to each under details.reloaded, details.skipped and details.failed.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
200Standard (application/json)Per-plugin outcomes

POST /v1/plugin/upload

Uploads a built package, validates it in a subprocess, files it under the library's own name and loads it.

multipart/form-data with the file in a part named package. A native library for this platform and nothing else: .whl and .jar are refused with unsupported_package. A second upload under a name the catalog holds is refused with plugin_exists unless ?override=true, and then only when no run in flight binds the plugin being replaced (plugin_in_use, with the runs). The reply is the entry, loaded or failed with the reason.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
overridequerybooleanNoReplace a plugin already filed under this name

Request body

any (multipart/form-data), optional.

The package, in a part named package

Responses

StatusBodyDescription
201PluginResponse (application/json)Installed and loaded, or installed and failed
400Standard (application/json)unsupported_package, not_loadable, invalid_name or bad_upload
409Standard (application/json)plugin_exists, plugin_in_use, plugin_building or algorithm_id_clash
413Standard (application/json)package_too_large: more than 50 MiB
500Standard (application/json)catalog_unwritable

GET /v1/plugin/{id}

One catalogued plugin.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
200PluginResponse (application/json)The entry
404Standard (application/json)no_such_plugin

DELETE /v1/plugin/{id}

Removes a plugin: unloads it, forgets its algorithms and deletes its files. A run in flight that bound one of its algorithms keeps the code until it ends; the removal is refused while one exists.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
200Standard (application/json)Removed
404Standard (application/json)no_such_plugin
409Standard (application/json)plugin_in_use or plugin_building
500Standard (application/json)catalog_unwritable

POST /v1/plugin/{id}/build

Rebuilds a linked project. The current generation stays loaded while the build runs; when it succeeds and nothing in flight binds the plugin, what it produced is installed as the next generation and loaded. Linked plugins only.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
202PluginResponse (application/json)Building
404Standard (application/json)no_such_plugin
409Standard (application/json)not_linked or plugin_building

POST /v1/plugin/{id}/load

Loads a plugin that is unloaded or failed.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
200PluginResponse (application/json)Loaded
400Standard (application/json)not_loadable; the entry is now failed with the reason
404Standard (application/json)no_such_plugin
409Standard (application/json)already_loaded or plugin_building

POST /v1/plugin/{id}/reload

Unloads and loads again. Refused while a run in flight binds one of its algorithms.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
200PluginResponse (application/json)Loaded
400Standard (application/json)not_loadable; the entry is now failed with the reason
404Standard (application/json)no_such_plugin
409Standard (application/json)plugin_in_use or plugin_building

POST /v1/plugin/{id}/unload

Unloads a plugin. Its algorithms stay named and stop being constructible; a runner bound to one is told it is not loaded when it starts. Refused while a run in flight binds one.

Authentication: an access token. See Authentication.

Parameters

NameInTypeRequiredDescription
idpathstring (uuid)YesPlugin id

Responses

StatusBodyDescription
200PluginResponse (application/json)Unloaded
404Standard (application/json)no_such_plugin
409Standard (application/json)plugin_in_use, not_loaded or plugin_building

Events

The realtime websocket

GET /v1/events

The realtime websocket: topic-scoped subscribe/unsubscribe over the event bus.

The token rides in Sec-WebSocket-Protocol as auth.bearer.<token> beside the protocol name, because browsers cannot set Authorization on a handshake; Authorization wins when both are present. A refusal is an HTTP 401 before the upgrade, never a close frame. After the upgrade the server sends an unprompted welcome frame; clients speak JSON commands (ping, subscribe, unsubscribe) and receive topic-scoped events. See doc/07. realtime-updates.md for the frame vocabulary — a websocket conversation is beyond what OpenAPI describes.

Authentication: an access token. See Authentication.

Responses

StatusBodyDescription
101NoneSwitching protocols; the selected subprotocol is the single real protocol name
401NoneThe handshake carried no valid token

Schemas

AcceptedLegalDocument

FieldTypeRequiredDescription
keystringYes
versionstringYesThe version the user was shown. Compared for equality with the version in force, so a consent screen left open while the document was revised is refused rather than recorded.

ApiKeyRequest

POST /v1/secret/{name}/api-key: the API key the venue issued for the generated public key.

Deserialize only. A [SecretString] has no Serialize, so this body cannot be echoed by any response type.

FieldTypeRequiredDescription
api_keystringYes

ChangeAlgorithmRequest

One of the following:

FieldTypeRequiredDescription
dataarray of string (uuid)Yes
type"add_data_provider"Yes
FieldTypeRequiredDescription
dataarray of string (uuid)Yes
type"remove_data_provider"Yes
FieldTypeRequiredDescription
paramsanyYes
type"change_parameters"Yes

CreateRepositoryRequest

FieldTypeRequiredDescription
endstring (date-time)Yes
intervalstringYesThe candle interval, in its canonical serde spelling: 1m, 1h, 1d, 1w, 1mo, … Example: "1h"
startstring (date-time)Yes
tickerstring (uuid)YesWhich ticker to fetch. A TickerId rather than an exchange symbol: the id names the provider too (via the asset catalog), and a symbol like BTCEUR does not — it is only unique within one provider.

EnrolRequest

What a client may say about the machine it is enrolling. Only the label, and only because it is what the user sees in their own device list — everything else about this machine the engine knows better than the client does.

FieldTypeRequiredDescription
labelstring or nullNo

FieldKind

How a field is entered. Secret is the instruction to mask it; nothing here changes how the engine treats the value, which is masked in every direction regardless.

One of: "text", "secret", "choice".

FieldOption

FieldTypeRequiredDescription
labelstringYes
valuestringYes

FormField

FieldTypeRequiredDescription
defaultstring or nullNoWhat the engine assumes when the field is omitted, if anything.
helpstringYes
keystringYes
kindFieldKindYes
labelstringYes
multilinebooleanYesWhether the value may span lines. A PEM private key does.
optionsarray of FieldOptionYesThe permitted values of a [FieldKind::Choice], empty for anything else.
requiredbooleanYes

GenerateRequest

POST /v1/secret/{name}/generate: which environment the key pair is for.

FieldTypeRequiredDescription
environmentstringYesWhich venue the key will be registered at. A Demo Mode key is valid nowhere else, and a venue runner is refused a key issued for another environment than it declares. Example: "demo"

GeneratedKey

What a generated key pair answers with: the public half, and nothing else of the pair.

FieldTypeRequiredDescription
environmentstringYes
key_typestringYesAlways ed25519: the one key type the venue's session logs on with.
nameSecretNameYes
public_keystringYesThe public key as PEM, for the user to paste into the venue's API management page. The private half is in the key store and nowhere else.

HealthResponse

FieldTypeRequiredDescription
statusstringYes
timestringYes
versionstringYesThe engine's version, from [crate::build_info] and never written out here. This is the one version a client can read without a credential — GET /v1/info is behind the token layer with everything else — so it is what an About box shows before anyone has logged in. Example: "0.0.1"

InfoResponse

The facts about this binary, as a client renders them.

A plain resource rather than an [crate::api::responses::Standard] envelope, the way [crate::api::health] is: the envelope is for replies that are not a thing.

Unknown values are null rather than omitted. A GUI drawing a fixed list of rows should not have to tell a missing key from an unknown value, and serde writes None as null here precisely because nothing carries skip_serializing_if.

FieldTypeRequiredDescription
branchstring or nullNoThe branch at build time; null on a detached HEAD as well as with no repository.
build_idstring or nullNoThe CI run id, which is what addresses that run's logs.
build_numberinteger (int64) or null (int64)NoThe CI run number, null for a build from a developer's machine.
built_atstringYesWhen the build script last ran, RFC 3339 in UTC.
commitstring or nullNoThe full commit hash, or null when the build had no repository to read.
commit_datestring or nullNoThe commit's own date, which a rebuild of an old tag does not move.
commit_shortstring or nullNoThe first eight characters of the hash — what a person quotes.
dirtyboolean or nullNoWhether tracked files were modified at build time, or null when there was no way to tell.
namestringYesThe binary's name.
osstringYesThe operating system this process is running on, which for a cross-compiled build is not something [InfoResponse::target] can be read off.
profilestringYesdebug or release.
rustcstringYesThe compiler, as it reported itself.
targetstringYesThe target triple this was compiled for — also the one a plugin must match.
versionstringYesThe version in Cargo.toml.

JobResponse

One download job: what was asked for, its state, and the last progress said on its topic.

The progress fields repeat the last event published on the job's topic (DataEvent, tagged on kind): completed and total count objects — months of one series — and message is the sentence a client can show. A client that subscribed late, or reloaded, reads here what it missed; one that is subscribed hears the same figures a frame at a time. The socket is the hint and this is the state.

FieldTypeRequiredDescription
completedinteger or nullNoObjects settled so far, from the last event that counted them; null before the first.
endstring (date-time)Yes
errorstring or nullNoWhy the job failed; null unless state is failed.
finished_atstring (date-time) or null (date-time)No
idstring (uuid)YesThe job id, which is also the topic it reports on.
intervalstringYesExample: "1h"
messagestring or nullNoThe last sentence published on the topic.
startstring (date-time)Yes
started_atstring (date-time)Yes
stateJobStatusYes
tickerstring (uuid)Yes
totalinteger or nullNoObjects the request resolved to, from the same event.

JobStatus

How far a download job has got, as GET /v1/repository/job/{id} answers it.

One of: "running", "completed", "failed".

LegalAcceptance

What a client posts to record agreement.

Several documents at once is the ordinary case: one checkbox covers the terms and the privacy notice, and the server writes them in one transaction so that half of that click cannot land.

There is no field here for the connection's address or user agent. A client cannot report its own origin as evidence — it would be evidence of whatever it chose to say — so the engine fills in the user agent from the request it received, and anything a client sends under either name is discarded by deserialization. See [Forwarded].

FieldTypeRequiredDescription
documentsarray of AcceptedLegalDocumentYes
methodLegalAcceptanceMethodNoWhere in the flow this was given. Defaults to reconsent, the answer that claims less: a client that forgot to say "signup" should not have that read into its request.

LegalAcceptanceMethod

One of: "signup", "reconsent".

LegalDocument

One declared document, and where this account stands against it.

FieldTypeRequiredDescription
accepted_atstring (date-time) or null (date-time)No
accepted_versionstring or nullNoThe version this account last accepted, whichever it was. Present and different from version is the revision case: "our terms have changed" rather than "please agree to our terms".
blockingbooleanYesWhether the product may be used without agreeing to this version. False for a document served as notice, such as a privacy policy — still listed, and acknowledging it is still recorded.
display_namestringYes
keystringYesThe stable id — terms-of-service. It outlives versions, so it names none.
satisfiedbooleanYesWhether accepted_version is the version in force.
urlstring or nullNoWhere the text is published. The server does not hold the text; it holds which version of it this account agreed to.
versionstringYesThe version in force. An acceptance must name exactly this: a client posting "whatever is current" would be recording agreement to text it never displayed.

LegalStanding

Where an account stands against every legal document the deployment declares.

blocked and outstanding are what a client's gate reads; documents is what it renders.

FieldTypeRequiredDescription
account_idstring (uuid)Yes
blockedbooleanYesWhether a blocking document is outstanding. A client that reads only this and outstanding is reading the answer correctly.
documentsarray of LegalDocumentYes
outstandingarray of stringYesThe keys of the blocking documents still to be accepted.

LinkPluginRequest

Link a project directory on the engine's machine. POST /v1/plugin/link.

The engine builds the project, validates what the build produced, copies it into the catalog and loads it; the route answers before any of that, with an entry in the building state and the catalog topic to watch. Rust projects only — a Cargo.toml at the root is what makes a directory one — until another runtime exists to host anything else.

FieldTypeRequiredDescription
artifactstring or nullNoWhere the build leaves the library, relative to project_dir. Defaults to what cargo build --release produces for the project's own package or library name.
build_commandstring or nullNoWhat to run in project_dir to build it, through the platform shell. Defaults to cargo build --release.
project_dirstringYesAn absolute path to the project's root, on the engine's own filesystem. Relative paths are refused rather than resolved: they would be interpreted against the engine's working directory, which is not something a client can see.
rebuildstring or nullNoWhen the project is rebuilt once it is linked. Only manual exists; the build route is how a rebuild is asked for.

LiveVenueView

A venue a live data source can stream from, as GET /v1/venue/live serves it.

Not a catalog venue (neurotrader_market_data::Venue): those are where tickers are listed, and this is where a live source connects. The two meet at market, which is how a client narrows a ticker picker to the pairs a venue can stream instead of letting the run refuse one later.

FieldTypeRequiredDescription
idstringYesThe wire value, exactly what a live data source's venue takes, e.g. binance. Example: "binance"
marketstringYesThe catalog venue code (Ticker.market, one of GET /v1/venue's codes) a ticker must be listed on to stream from this venue.
namestringYesThe name a client shows, e.g. Binance.

OperateRunnerBody

The object spelling of [OperateRunnerRequest], and the shape the API document shows.

FieldTypeRequiredDescription
dispositionstring or nullNoWhat to do with a live run's working orders: close or leave. Required to stop a live run, ignored by a backtest, refused with any operation but stop.
operationOperationYes

Operation

The operation word, in either spelling of the body.

One of: "start", "stop", "pause", "resume", "reset".

PluginResponse

One catalogued plugin, as the API reports it.

The entry's own shape, plus the state this process holds it in. algorithms is what the library published when it was validated, not necessarily what it publishes now: the live manifest is read at every load and always wins, and GET /v1/algorithms is where the live answer is.

FieldTypeRequiredDescription
abi_versioninteger (int32)Yes
added_atstring (date-time)Yes
algorithmsarray of objectYesEach entry is an algorithm [Definition] as GET /v1/algorithms reports it.
filestringYesThe file the engine loads, inside the plugin's directory under the storage directory. Empty for a linked project that has not been built yet.
generationinteger (int32)YesHow many times this plugin has been installed, counting the first.
idstring (uuid)Yes
namestringYesThe name the plugin is filed under: its package name, lowercased.
sdk_versionstringYes
sha256stringYesSHA-256 of that file. What a record can name the code by.
sourceobjectYesWhere the code came from, and so whether the engine can rebuild it.
stateobjectYesloaded, unloaded, failed (with reason) or building.
targetstringYes
updated_atstring (date-time)Yes

ResponseType

One of: "Success", "Error".

SecretForm

One secret's form, as a client renders it.

FieldTypeRequiredDescription
descriptionstringYes
fieldsarray of FormFieldYes
nameSecretNameYes
titlestringYes

SecretName

The name of one secret form.

One of: "binance.credentials".

SecretStatus

One secret: its form, whether this machine holds it, which environment what it holds was issued for, and whether it is waiting for the venue to issue its API key.

The form is flattened in, so name, title, description and fields sit beside present in one object — a client reads the list and has everything it needs to render and to show state.

Every field of each of:

FieldTypeRequiredDescription
awaiting_api_keybooleanYesWhether the stored credential is a key pair this engine generated whose API key has not been registered yet (#206). The next step is then the user's: register the public key at the venue and submit the API key it issues. false whenever present is.
environmentstring or nullNoThe environment the stored credential was issued for (mainnet, demo, testnet), so a client can tell before a start that a demo runner has no demo key to run with. null when nothing is stored. Not a secret: it names the host the key is valid at, never the key. Example: "demo"
presentbooleanYesWhether a credential is stored under this name. Never anything about what it contains.

SessionRequest

What a client is asking for.

Two optional fields, and the shape does not vary with the answer. A body whose fields depended on whether the account already subscribes would be the client making the choice again, one layer below the route that exists to make it for them.

FieldTypeRequiredDescription
intervalstring or nullNoWhich of the plan's prices, in the billing provider's own words: month, year. The values a plan is sold at are its prices[].interval on GET /v1/billing/plans. Absent means what the Entitlement Server says it means: the plan's only price, or interval_required when it is sold at several. It is forwarded only when present, and never checked here; an interval the plan is not sold at is that service's unknown_interval.
plan_keystring or nullNoThe plan the user wants, or absent for "let me manage what I have": payment method, invoices, cancellation. Naming the deployment's default plan is how a cancellation is spelled.

Standard

The uniform envelope for replies that are not a resource: acknowledgements, refusals, and anything else where the answer is a sentence rather than a thing.

FieldTypeRequiredDescription
detailsanyNo
messagestringYes
resultResponseTypeYes
timestampstring (date-time)Yes

StopAllRequest

The body of POST /live/stop (#299): one disposition for every active live run. Required, with no default, for the reason the single stop has none.

FieldTypeRequiredDescription
dispositionstringYes

UpdateRunRequest

Fields left as None are left untouched. tags, when provided, replaces the whole list.

FieldTypeRequiredDescription
labelstring or nullNo
tagsarray of string or nullNo

On this page

AddressAuthenticationHealthGET /v1/healthInfoGET /v1/infoCatalogGET /v1/assetGET /v1/tickerGET /v1/venueGET /v1/venue/liveRunnerGET /v1/runnerPOST /v1/runnerGET /v1/runner/{id}PATCH /v1/runner/{id}DELETE /v1/runner/{id}GET /v1/runner/{simulation_id}/algorithmPOST /v1/runner/{simulation_id}/algorithmPATCH /v1/runner/{simulation_id}/algorithm/{algorithm_id}DELETE /v1/runner/{simulation_id}/algorithm/{algorithm_id}POST /v1/runner/{simulation_id}/dataDELETE /v1/runner/{simulation_id}/dataPOST /v1/runner/{simulation_id}/operateLivePOST /v1/live/stopGET /v1/live/{id}GET /v1/live/{id}/accountGET /v1/live/{id}/actionsGET /v1/live/{id}/dataGET /v1/live/{id}/performanceRunGET /v1/runner/{id}/runGET /v1/runner/{id}/run/{run_id}PATCH /v1/runner/{id}/run/{run_id}DELETE /v1/runner/{id}/run/{run_id}GET /v1/runner/{id}/run/{run_id}/accountGET /v1/runner/{id}/run/{run_id}/actionsGET /v1/runner/{id}/run/{run_id}/dataPOST /v1/runner/{id}/run/{run_id}/operateGET /v1/runner/{id}/run/{run_id}/performancePOST /v1/runner/{id}/run/{run_id}/restoreAlgorithmGET /v1/algorithmsRepositoryGET /v1/repositoryPOST /v1/repositoryGET /v1/repository/jobGET /v1/repository/job/{id}SecretGET /v1/secretGET /v1/secret/{name}PUT /v1/secret/{name}DELETE /v1/secret/{name}POST /v1/secret/{name}/api-keyPOST /v1/secret/{name}/generateDeviceGET /v1/devicePOST /v1/deviceDELETE /v1/devicePOST /v1/device/leaseBillingGET /v1/billing/plansPOST /v1/billing/sessionGET /v1/billing/session/{session_id}LegalPOST /v1/legal/acceptancesGET /v1/legal/standingPluginGET /v1/pluginPOST /v1/plugin/linkPOST /v1/plugin/reloadPOST /v1/plugin/uploadGET /v1/plugin/{id}DELETE /v1/plugin/{id}POST /v1/plugin/{id}/buildPOST /v1/plugin/{id}/loadPOST /v1/plugin/{id}/reloadPOST /v1/plugin/{id}/unloadEventsGET /v1/eventsSchemasAcceptedLegalDocumentApiKeyRequestChangeAlgorithmRequestCreateRepositoryRequestEnrolRequestFieldKindFieldOptionFormFieldGenerateRequestGeneratedKeyHealthResponseInfoResponseJobResponseJobStatusLegalAcceptanceLegalAcceptanceMethodLegalDocumentLegalStandingLinkPluginRequestLiveVenueViewOperateRunnerBodyOperationPluginResponseResponseTypeSecretFormSecretNameSecretStatusSessionRequestStandardStopAllRequestUpdateRunRequest