API · Signals

Signals API (Pro)

The Signals API lets a Pro subscriber read the Trigr strategy library and trade it from their own system. List every strategy with its backtest and live paper results, read each one's backtest trades and live paper record, then pull its live signal together with the order it means: side, size, leverage, take profit and stop. The recipe stays private: you get what to trade, never the strategy's rules.

How it fits together

  • 1. List. GET /api/v1/signals/strategies returns the strategies you may pull, with their market, timeframe and results. Pick the ones you want.
  • 2. Check. GET /api/v1/strategies/{id}/backtest and GET /api/v1/strategies/{id}/live return a strategy's backtest trades and its live paper record, trade by trade.
  • 3. Pull. After each bar closes, call GET /api/v1/strategies/{id}/signal (or the batch form). The answer states the signal for the bar that just closed and when the next one is due.
  • 4. Execute. Place entry if you hold no position, or apply positions to the one you hold. See Executing a signal. A Pair trade or Basket answers with a target per leg: see Pair trades and Baskets.

List strategies

GET/api/v1/signals/strategies

Every strategy you may pull: each published strategy that is free to use, Trigr's own strategies included, plus any paid strategy you subscribe to. The figures are the ones shown on the strategy's page. Without limit the whole list is returned in one response.

QueryMeaning
assetTicker, for example BTC. Matches any leg of a Pair trade or Basket.
timeframeThe strategy’s timeframe as the list states it, for example 4h. Case-insensitive.
officialtrue: only strategies built by Trigr. false: only community strategies.
limitPage size, 1 to 1000.
offsetRows to skip. The order is stable.
Request
curl "https://trigr.xyz/api/v1/signals/strategies?asset=BTC&timeframe=4h" \
  -H "Authorization: Bearer $TRIGR_KEY"
200 OK
{
  "strategies": [
    {
      "id": "cmg1x2y3z0001abcd",
      "name": "BTC Trend Rider",
      "url": "https://trigr.xyz/strategy/cmg1x2y3z0001abcd",
      "asset": "BTC",
      "assets": ["BTC"],
      "mode": "single",
      "timeframe": "4h",
      "timeframes": ["4h"],
      "direction": "both",
      "official": true,
      "access": "open",
      "listed": true,
      "signalAvailable": true,
      "publishedAt": "2026-10-09",
      "backtest": {
        "returnPct": 184.2,
        "sharpe": 1.41,
        "maxDrawdownPct": -22.6,
        "winRatePct": 47.5,
        "trades": 312,
        "start": "2021-01-01",
        "end": "2026-10-01"
      },
      "live": {
        "returnPct": 3.8,
        "sharpe": null,
        "days": 35,
        "start": "2026-10-09"
      }
    }
  ],
  "total": 1,
  "offset": 0,
  "limit": null
}
FieldMeaning
modesingle: one market. spread: a Pair trade. basket: a Basket.
timeframe · timeframestimeframes is every timeframe the strategy’s rules read, finest first, and timeframe is the finest one. The signal response states the timeframe the strategy is evaluated on.
accessopen: any Pro key may pull it. subscribed: you may pull it through your subscription.
listedfalse only for a strategy you subscribe to that is no longer in the library. Its other fields are then empty.
signalAvailabletrue when the signal endpoint serves this strategy: a single-market strategy, a Pair trade or a Basket. false for a backtest-only strategy.
backtestThe published backtest: net return, Sharpe, maximum drawdown, win rate, trade count and the tested window. null when none is published.
liveThe live paper record since publication: return, Sharpe (null until there is enough history), days and start date. null before the record starts.

Get a strategy's backtest

GET/api/v1/strategies/{id}/backtest

The published backtest of one strategy: the headline figures, the return of each month, and the trades, newest first. Page through the trades with limit (1 to 1000, default 200) and offset.

Request
curl "https://trigr.xyz/api/v1/strategies/cmg1x2y3z0001abcd/backtest?limit=2" \
  -H "Authorization: Bearer $TRIGR_KEY"
200 OK
{
  "strategyId": "cmg1x2y3z0001abcd",
  "summary": {
    "returnPct": 184.2,
    "sharpe": 1.41,
    "maxDrawdownPct": -22.6,
    "winRatePct": 47.5,
    "trades": 312,
    "start": "2021-01-01",
    "end": "2026-10-01"
  },
  "monthlyReturnsPct": [4.1, -2.3, 7.8],
  "tradesStatus": "complete",
  "trades": [
    {
      "side": "short",
      "openedAt": "2026-09-27T08:00:00.000Z",
      "closedAt": "2026-09-29T16:00:00.000Z",
      "entryPrice": 65120.5,
      "exitPrice": 63480,
      "pnlPct": 2.4
    },
    {
      "side": "long",
      "openedAt": "2026-09-20T00:00:00.000Z",
      "closedAt": "2026-09-22T12:00:00.000Z",
      "entryPrice": 62900,
      "exitPrice": 62310,
      "pnlPct": -1.0
    }
  ],
  "total": 312,
  "offset": 0,
  "limit": 2
}
FieldMeaning
summaryThe same figures as backtest in the list. null when the list has no figures for the version you are entitled to.
monthlyReturnsPctReturn of each calendar month of the tested window, in percent, oldest first. null when not recorded.
tradesStatuscomplete: every backtest trade is available. partial: only the most recent trades were saved. unavailable: no trade list is served for this strategy.
tradesNewest first. side is long or short; openedAt and closedAt are ISO 8601 UTC (openedAt is null on older rows); pnlPct is the result of the trade in percent, as listed on the strategy’s page. It reflects the strategy’s leverage.
totalTrades available, before paging.

Get a strategy's live record

GET/api/v1/strategies/{id}/live

The live paper record since publication: the paper account's equity over time, the positions it holds, and its closed trades, newest first. Same paging as the backtest. Add equity=false to leave the equity series out, for example when you page through the trades.

Request
curl "https://trigr.xyz/api/v1/strategies/cmg1x2y3z0001abcd/live?limit=1" \
  -H "Authorization: Bearer $TRIGR_KEY"
200 OK
{
  "strategyId": "cmg1x2y3z0001abcd",
  "record": {
    "startedAt": "2026-10-09T00:00:00.000Z",
    "lastPointAt": "2026-11-13T08:00:00.000Z",
    "running": true,
    "startEquity": 10000,
    "lastEquity": 10380,
    "returnPct": 3.8,
    "closedTrades": 9,
    "winRatePct": 55.56,
    "equity": [
      { "time": "2026-10-09T00:00:00.000Z", "equity": 10000 },
      { "time": "2026-11-13T08:00:00.000Z", "equity": 10380 }
    ]
  },
  "openPositions": [
    { "side": "long", "openedAt": "2026-11-12T12:00:00.000Z", "entryPrice": 64210.5 }
  ],
  "positionsAsOf": null,
  "tradesAsOf": null,
  "tradesStatus": "complete",
  "trades": [
    {
      "side": "short",
      "openedAt": "2026-11-08T04:00:00.000Z",
      "closedAt": "2026-11-10T20:00:00.000Z",
      "entryPrice": 66020,
      "exitPrice": 64890,
      "pnlPct": 1.7,
      "replayEnded": false
    }
  ],
  "total": 9,
  "offset": 0,
  "limit": 1
}
FieldMeaning
recordnull when there is no live paper record. running is true while the record is extended bar by bar. winRatePct is null until a trade is decided. closedTrades and winRatePct are null for a Pair trade or a Basket. If you subscribe to an earlier version of a strategy, this is that version’s record, which stops when the strategy moves on.
record.equityThe paper account’s equity over time, oldest first. null with equity=false.
openPositionsWhat the paper record holds: side, entry time and entry price. For a Pair trade or Basket, one entry per held leg, with its asset and its weight (size at entry as a share of the record’s equity then). null when not served: before the record starts, or for a Pair trade or Basket whose record names no legs yet or has stopped. An empty list means the record holds nothing.
positionsAsOfPair trade or Basket only: the close of the record’s last bar. openPositions are the legs the record held through that bar, so a change the strategy decided at that close is not in them yet: the signal has it. null for a single-market strategy, and whenever no legs are served.
tradesAsOfPair trade or Basket only: the bar of the record through which its closed legs are listed. Normally the record’s last bar. It stays earlier when the latest runs could not list the legs, so compare it with record.lastPointAt before treating the list as up to date. null for a single-market strategy, and whenever no closed leg list is served.
tradesStatuscomplete: closed trades are listed in trades. unavailable: none is listed: before the record starts, or for a Pair trade or Basket record that does not keep its closed legs yet.
tradesClosed trades, newest first, with the same fields as a backtest trade. pnlPct is the result on the margin used, in percent.
trades (Pair trade or Basket)The legs the record closed, newest first: asset, side, weight (size at entry as a share of the record’s equity then), openedAt, closedAt, entryPrice, exitPrice, equityPnlPct and position. Every leg has an asset; a single-market trade has none. entryPrice and exitPrice are null when no price was recorded for that fill. equityPnlPct is the leg’s result after fees, in percent of the record’s equity at its entry: what the leg added to or took from the account, not a result on its margin. The record models no slippage and no funding. Legs opened together share a position number. A leg is not a strategy trade, so closedTrades and winRatePct stay null; total counts the closed legs.
replayEndedtrue when the row was closed by the end of a replay window and not by the strategy. It is not an exit the strategy took and is not counted in winRatePct.

Get a strategy's signal

GET/api/v1/strategies/{id}/signal

The signal of the bar that just closed, evaluated on the same inputs as the strategy's live paper record and Trigr Agents. Act on the first answer you get for a bar. A later call for the same bar normally returns the same answer, but it can differ when a data source revises its last value.

Request
curl https://trigr.xyz/api/v1/strategies/cmg1x2y3z0001abcd/signal \
  -H "Authorization: Bearer $TRIGR_KEY"
200 OK
{
  "strategyId": "cmg1x2y3z0001abcd",
  "mode": "single",
  "asset": "BTC",
  "market": "BTCUSDT",
  "timeframe": "4h",
  "signal": "long",
  "confidence": 72,
  "barCloseTime": "2026-11-13T12:00:00.000Z",
  "nextBarCloseTime": "2026-11-13T16:00:00.000Z",
  "price": 68250.5,
  "entry": {
    "side": "long",
    "orderType": "market",
    "referencePrice": 68250.5,
    "marginPct": 50,
    "leverage": 2,
    "notionalPct": 100,
    "takeProfitPct": 3,
    "takeProfitPrice": 70298.015,
    "stopLossPct": 1.5,
    "stopLossPrice": 67226.7425,
    "trailingStopPrice": null
  },
  "entryBlockedReason": null,
  "positions": {
    "long": { "action": "hold", "reason": null },
    "short": { "action": "reverse", "reason": "flip" }
  },
  "risk": {
    "direction": "both",
    "onOpposite": "reverse",
    "exitOnFlip": true,
    "sizePct": 50,
    "leverage": 2,
    "takeProfitPct": 3,
    "stopLossPct": 1.5,
    "trailingAtrMultiple": null,
    "trailingAtr": null,
    "maxBars": null,
    "breakEvenAtPct": null,
    "breakEvenOffsetPct": null,
    "maxConcurrentPositions": 1
  },
  "session": null,
  "bar_close_time": "2026-11-13T12:00:00.000Z"
}

Signal

FieldMeaning
modesingle for a strategy on one market, with the fields below. spread (a Pair trade) and basket answer with legs: see Pair trades and Baskets.
signallong, short or flat: the side the strategy wants at this bar, after its filters and allowed direction.
confidence0 to 100 when the strategy states one, otherwise null.
marketThe reference market the signal is computed on. asset is its ticker.
timeframeHow often the strategy is evaluated: one signal per closed bar of this size, in UTC.
barCloseTimeClose of the evaluated bar. bar_close_time is the same value under its earlier name.
nextBarCloseTimeWhen the next bar closes and a new signal is due.
priceClosing price of the evaluated bar.

entry

The order to place when you hold no position in this strategy and have not acted on this bar yet. It is null when the signal is flat or when this bar opens nothing; entryBlockedReason then says why.

FieldMeaning
orderTypeAlways market. Trigr Agents enter at market right after the bar closes. No limit entry is used.
referencePriceThe bar close the price levels below are computed from. Your fill will differ; recompute the levels from your fill if you want the same percentages.
marginPctMargin to post, in percent of the capital you allocate to this strategy. It already includes this bar’s size adjustment.
leverageLeverage of the position. notionalPct is marginPct × leverage.
takeProfitPct / takeProfitPriceTake-profit distance and level. null: the strategy has no take profit.
stopLossPct / stopLossPricestopLossPct is the fixed stop distance. stopLossPrice is the stop the live paper record opens with: the fixed stop, or the start of the ATR trailing stop when that is closer. null: no stop.
trailingStopPriceWhere the ATR trailing stop starts. null without a trailing stop.
entryBlockedReasonMeaning
session_closedThe US market is closed at this bar.
size_unavailableThe strategy sizes each entry from market conditions, and this bar’s size is zero or not available.
barriers_unavailableThe strategy sets a take profit and stop per entry, and this bar has none.
trailing_stop_unavailableThe ATR for the trailing stop is not available for this bar.
price_unavailable · direction_not_allowedNo usable close price, or a side the strategy does not trade.

positions

What to do with a position you already hold, by its side. You know your position; the API does not, so both sides are always stated.

actionMeaning
holdKeep the position. Its take profit and stop stay in place.
closeClose the position at market. Open nothing on this bar.
reverseClose the position at market, then place entry (the opposite side) on the same bar.

reason is flip (the signal turned), custom_exit or formula_exit (the strategy's own exit rule fired), or null for a hold.

risk

The strategy's standing risk settings, the same ones a Trigr Agent shows when you deploy the strategy.

FieldMeaning
directionlong, short or both: the sides the strategy trades.
onOppositeWhat an opposite signal does to an open position: reverse, ignore (keep it) or reduce_only (close it, open nothing).
exitOnFliptrue: a flat or opposite signal closes the position. false: only the take profit, stop and the strategy’s exit rules close it.
sizePct · leverageThe strategy’s base position size, in percent of allocated capital, and its leverage.
takeProfitPct · stopLossPctThe standing take-profit and stop distances, in percent of the entry price. null when unset.
trailingAtrMultiple · trailingAtrATR trailing stop: the multiple, and this bar’s ATR in price units. Both null without one.
maxBarsTime stop: close the position after this many bars. null without one.
breakEvenAtPct · breakEvenOffsetPctBreak-even: once a bar closes this far in profit, move the stop to the entry price plus the offset. null without one.
maxConcurrentPositionsPositions the strategy holds at once. Strategies served here hold one.

session is present only for a strategy that trades US market hours: open says whether the market is open at this bar and nextSessionOpen when it opens next. While it is closed, open nothing and close nothing; your take profit and stop stay in place.

Executing a signal

  • Timing. Pull shortly after nextBarCloseTime. If the bar is not ready you get 409 NO_SIGNAL with retryable: true; wait retryAfterMs and ask again.
  • Once per bar. Act on the first answer you get for a bar and key it on barCloseTime; ignore later answers for the same bar. After your take profit or stop fills, do not re-enter from that bar's entry: wait for the next bar.
  • Size. Margin = your capital for this strategy × marginPct / 100. Position value = margin × leverage. Quantity = position value / your entry price. At 100% keep a little capital aside for fees.
  • Order. Enter at market right after the bar closes, then place the take profit and stop as resting reduce-only orders at the stated levels. If the price has already moved well away from referencePrice, skip the entry: the live paper record and Trigr Agents skip it too.
  • Stop with a trailing stop. stopLossPrice is the level the live paper record uses. Trigr Agents rest the fixed stop on the venue (with a trailing stop alone, a wider protective stop) and apply the trailing stop from the next bar close. Either way, never leave a position without a stop when the strategy has one.
  • One position per strategy. If you already hold the side signal names, do not add to it; follow positions.
  • Exits you manage. A trailing stop, a break-even move and a time stop are not resting orders: your system applies them at each bar from the risk settings. The strategy builder guide explains each rule.

Pair trades and Baskets

A Pair trade or a Basket trades several markets as one position, so its signal is a target for every leg, not one side. The same endpoint serves it; mode tells the answers apart: single, spread for a Pair trade, or basket. The legs follow the strategy's own run since it was published; for a Trigr strategy that is the run behind its live paper record. Pair trades and Baskets trade crypto perps on the 1h, 4h and 1d timeframes.

200 OK
{
  "strategyId": "cmg4x2y3z0009wxyz",
  "mode": "spread",
  "timeframe": "4h",
  "barCloseTime": "2026-11-13T08:00:00.000Z",
  "nextBarCloseTime": "2026-11-13T12:00:00.000Z",
  "action": "open",
  "opensLegs": true,
  "legs": [
    { "asset": "AAVE", "market": "AAVEUSDT", "side": "long", "weight": 0.45, "closePrice": 212.4, "stopped": false },
    { "asset": "ETH", "market": "ETHUSDT", "side": "short", "weight": 0.45, "closePrice": 3405.1, "stopped": false }
  ],
  "sizing": {
    "basis": "dollar_weights",
    "grossWeight": 0.9,
    "marginMode": "isolated",
    "legLeverage": 1
  },
  "exit": null,
  "stopChecks": {
    "resolution": "5m",
    "checkedThrough": "2026-11-13T08:10:00.000Z",
    "barCloseOnlyAssets": []
  },
  "regimeFilter": null,
  "liquidated": false,
  "runStartedAt": "2026-11-10T13:00:11.320Z"
}
FieldMeaning
actionWhat the strategy did at this bar. open (Pair trade) and rebalance (Basket) take new legs, close leaves every leg, hold changes nothing. Decide whether to open on opensLegs, not on action: a Basket stop between two rebalances is rebalance with opensLegs false.
opensLegstrue when this answer opens legs. When false, open nothing, even a leg whose side you do not hold: an entry you missed is not taken late. No answer opens legs while the latest stop check is not in it: you get opensLegs false, or 409 NO_SIGNAL to retry.
legsOne entry per market, in the order of assets in the list. side is long, short or flat (no position on this leg). weight is the leg’s position value as a share of your capital for this strategy (0.45 = 45%): the size to open at an entry, and the size the position has drifted to while it is held. closePrice is the leg’s close at barCloseTime. stopped is true when a stop (not a take profit) closed the leg.
sizingbasis says how to size the legs (see below). grossWeight is the sum of the weights. Open every leg at legLeverage on marginMode margin. With cross margin legLeverage is null: use the lowest leverage that funds the legs.
exitAn exit that fired since the previous bar closed: when (a 5-minute close), why (leg_stop, stop_loss, take_profit or trail) and which legs it closed. It closes the legs you opened before its time. legs and opensLegs state the position after it: the strategy can enter again at the bar close. null when none fired.
stopChecksSet when the strategy checks its stops on 5-minute closes between bars. checkedThrough is the last 5-minute close whose check is in this answer. barCloseOnlyAssets are legs with no 5-minute data, checked at the bar close only; a Pair trade with such a leg is checked at the bar close only as a whole. null when the strategy has no such stop.
regimeFilterA Basket’s regime filter at this bar: on, off (the Basket holds nothing) or unknown. null when it has none.
liquidatedtrue when the strategy’s run lost its whole balance. Every leg is flat and it opens nothing more.
runStartedAtWhen the run these legs belong to started: the strategy’s publication.

Executing it

  • Exit first. If exit is set, close every leg it names that you opened before exit.time, even when the leg's side still matches yours. Then apply the rest of the answer.
  • Close next. Close every leg you hold whose side is flat or the opposite of yours. When legs change side, close all of them before you open the new side.
  • Open only when told. If opensLegs is true, open each leg whose side you do not hold. If it is false, open nothing and wait for the next answer that opens legs. Enter soon after the bar closes: later in the bar the answer still opens legs, but prices have moved away from closePrice.
  • Once per bar. Open at most once for a given barCloseTime. After you close a position yourself (a failed leg, a liquidation, an exit), do not open it again from an answer with the same barCloseTime: wait for a later bar whose answer opens legs.
  • Never resize. A leg you already hold on the stated side stays as it is. The weights of a held position drift with prices.
  • Size. With dollar_weights, a leg's quantity = your capital × weight / your entry price. With unit_weights the hedge is fixed in units: size each leg in proportion to weight / closePrice, then scale all legs by one factor so the position is worth your capital × grossWeight. Round every leg down to the venue's lot and keep the legs in proportion.
  • Stops. When stopChecks is set and you hold legs, pull again about 90 seconds after every 5-minute mark and check that checkedThrough has reached that mark. If it has not, or the answer is 409 NO_SIGNAL, the check is not in yet: retry.
  • All legs or none. If one leg of a Pair trade cannot be opened, or your venue liquidates one, close the others: a Pair trade with a missing leg is not hedged.

Batch

GET/api/v1/signals?strategyIds=a,b,c

Pull up to 50 strategies in one request. Each distinct id gets one entry, in the order you gave: the signal (with legs for a Pair trade or Basket), or an error for that id alone. A request with more ids is refused with 422 VALIDATION.

Request
curl "https://trigr.xyz/api/v1/signals?strategyIds=cmg1…abcd,cmg2…efgh,cmg3…ijkl" \
  -H "Authorization: Bearer $TRIGR_KEY"
200 OK
{
  "signals": [
    {
      "strategyId": "cmg1…abcd",
      "signal": { "strategyId": "cmg1…abcd", "signal": "short", "entry": { … }, … }
    },
    {
      "strategyId": "cmg2…efgh",
      "error": { "code": "NO_SIGNAL", "message": "The bar that just closed is not available yet. Retry shortly.", "retryable": true, "retryAfterMs": 5000 }
    },
    {
      "strategyId": "cmg3…ijkl",
      "error": { "code": "NOT_ENTITLED", "message": "You are not entitled to pull signals from this strategy. …" }
    }
  ]
}

Errors

StatusCodeMeaning
403SIGNALS_API_REQUIRES_PROThe key’s plan is not Pro.
403NOT_ENTITLEDA paid strategy you do not subscribe to.
404NOT_FOUNDNo strategy has this id. The backtest and live endpoints also answer this for a strategy that is no longer published.
409NO_SIGNALNo signal for the current bar. retryable says whether asking again can get one; retryAfterMs is the suggested wait. With retryable false, wait for the next bar.
409STRATEGY_HALTEDThe strategy cannot go on: its model must be retrained by its builder, or the run of a Pair trade or Basket cannot be continued (for example a leg was delisted). Open nothing and close any position you hold for it. The answer stays the same until the builder republishes.
409SIGNAL_UNSUPPORTEDThe strategy has no live signal: it runs in backtests only. signalAvailable in the list says so in advance.
422VALIDATIONA malformed query value, no strategyIds, or too many of them.
409 NO_SIGNAL
{
  "error": "NO_SIGNAL",
  "message": "The bar that just closed is not available yet. Retry shortly.",
  "retryable": true,
  "retryAfterMs": 5000
}

Notes

  • Private recipe. No endpoint returns a strategy's rules, indicators or conditions.
  • Pair trades and Baskets have a signal with a target per leg. Their live record is the equity over time, the legs held and the legs closed. On stocks they run in backtests only and are not listed.
  • Not financial advice. A signal is the output of a strategy, not a recommendation. Past results, backtested or live, do not predict future results.