Skip to main content
Developers

Market alerts

Market alerts flag unusual price moves on the JAFX feed: a market that moves at least 5 times more than it usually does in 15 or 60 minutes. They are the alerts JAFX Terminal shows in its Alerts tab, and your program reads them with GET /alerts, the stream's alerts channel or the MCP tool get_alerts, all with market:read.

Information, not advice

An alert says what a price just did, never what it will do, and it isn't a signal to trade. What the price did afterwards (follow_up) shows what happened next, not what will happen. Every trading decision, and its risk, is yours.

How JAFX detects them

Every 5 minutes, each market on JAFX's central price feed is checked for a move over the last 15 or 60 minutes that is both:

  • unusual: at least 5 times the market's usual move over the same window (the median of the last 7 days), and
  • big enough for that market: a share of its typical daily range, from 30% to 60%, set from the market's own last 20 days so that each market alerts on about one trading day in four.

The move must still hold a minute later. The daily rollover (20:45 to 22:15 UTC) and the first hour after a market opens are left out, and a market alerts at most once an hour in each direction. When a move keeps going the same way, each new sharp leg (starting within 2 hours of the last) updates its alert instead of adding another, until the market gives back half of the move. For 4 hours after the latest leg, the alert follows the price.

Alerts are JAFX's own reading of its central price feed: the same for every key, whichever account and server the key is on. Their prices are the feed's bid, as candles are (price_basis: "raw", see Conventions).

An alert

JSON
{
  "id": 1203,
  "symbol": "XMRUSD",
  "asset_class": "Cryptos",
  "direction": "down",
  "pct": -3.615,
  "window_minutes": 60,
  "times_usual": 7.99,
  "share_of_day": 0.888,
  "tier": "normal",
  "start_price": 497.89,
  "price": 479.89,
  "window_start": "2026-11-14T19:35:00.000Z",
  "fired_at": "2026-11-14T20:36:00.000Z",
  "legs": 1,
  "last_leg_at": "2026-11-14T20:36:00.000Z",
  "updated_at": "2026-11-14T21:39:31.706Z",
  "group_id": 1203,
  "group_size": 2,
  "group_label": "XMR weakening",
  "follow_up": {
    "until": "2026-11-15T00:36:00.000Z",
    "peak_price": 462.69,
    "peak_at": "2026-11-14T21:18:00.000Z",
    "worst_price": 479.89,
    "price_1h": 472.5,
    "price_4h": null,
    "outcome": null
  }
}
FieldMeaning
idThe alert's number. Ids only grow, in the order alerts fire.
symbol, asset_classThe instrument and its group, as GET /symbols names them (group there).
directionup or down.
pctThe move in percent, from start_price to price, negative when down: -3.615 is a 3.615% fall.
window_minutes15 or 60: the window the first leg was measured over. A 15-minute alert belongs on an M15 chart, a 60-minute one on H1.
times_usualHow many times the market's usual move over the same window it was: at least 5. For a move of several legs, its sharpest leg.
share_of_dayThe move as a share of the market's typical daily range (the median of its last 20 trading days): 0.888 is 89% of a typical day.
tiernormal, or strong for a big move: at least 12 times usual, or half again the market's size bar and at least half a typical day. A move of several legs becomes strong once the whole run is big enough, and stays so.
start_price, priceThe price where the move started (at window_start) and at the latest leg.
window_start, fired_atWhen the move started, and when the alert fired: the close of the minute that confirmed it.
legs, last_leg_atHow many sharp legs the move has had (1 for a single sharp move), and when the latest was confirmed. For more than one leg, the move runs from window_start to last_leg_at.
updated_atThe last time anything in the alert changed: a new leg, or its follow-up.
group_id, group_size, group_labelAlerts that fire within 15 minutes of each other and share a driver (a currency getting stronger or weaker, metals, oil, or stocks and indices) share a group, named by its first alert's id; an alert on its own is its own group. group_size: how many alerts it had when the answer was made. group_label: what they share, such as USD strengthening or Stocks & indices falling, or null for an alert on its own.
follow_up.untilWhen the follow-up ends: 4 hours after the latest leg.
follow_up.peak_price, peak_atThe furthest price in the move's direction since the alert fired, and when.
follow_up.worst_priceThe furthest price against the move since the latest leg.
follow_up.price_1h, price_4hThe price 1 hour and 4 hours after the latest leg; null until then.
follow_up.outcomeHow it ended, 4 hours after the latest leg, measured from where the move started: kept_going (20% or more beyond the move at the alert), held (at least half of it kept), faded (less than half kept) or reversed (back past the start); null until then.

A new leg restarts the follow-up: price_1h, price_4h, outcome and worst_price count from the newest leg.

Read them: GET /alerts

The alerts that fired in the last 24 hours, newest first, on every market or on the ones you name. Alerts are kept, so since reads back as far as you like, a page at a time.

ParameterMeaning
symbolsComma-separated instruments, at most 50, in any case. Names JAFX doesn't list come back in missing.
sinceISO-8601 or epoch milliseconds: alerts fired at or after it. Default: 24 hours ago. The answer's since says which time it used.
after_idOnly alerts with a larger id: those that fired after the one you last saw.
updated_sinceOnly alerts that changed at or after this time: fired, extended by a new leg, or followed up.
limit1–1000, default 100.
cursorThe next_cursor of the previous page, for older alerts; null when there are none.
curl
curl -s "https://terminal.jafx.com/trading-api/v1/alerts?symbols=XMRUSD,BTCUSD&limit=20" \
  -H "Authorization: Bearer $JAFX_API_KEY"
JSON
{"data": [{"id": 1203, "symbol": "XMRUSD", "direction": "down", "pct": -3.615, "…": "…"}],
 "next_cursor": null, "since": "2026-11-13T21:40:00.000Z", "missing": [], "price_basis": "raw"}

Polling. To catch new alerts and new legs, ask every minute or so with updated_since set to the newest updated_at you have seen: the answer repeats an alert changed at that same millisecond, so keep each alert by its id. Answers are the same for every key and come within a few seconds of a new alert, so asking more often gains nothing; the stream pushes them instead.

Follow them: the alerts channel

JSON
{"op": "subscribe", "channels": ["alerts"]}
{"op": "subscribe", "channels": ["alerts:XAUUSD,EURUSD"]}

alerts on its own follows every market; alerts:SYM,SYM,… only those (at most 100 instruments a connection; unknown ones are skipped). On subscribe, before the subscribed answer, the channel sends the alerts of the last 24 hours on those markets, at most 50, oldest first, as alert.snapshot. Then each new alert and each new leg, as it fires:

JSON
{"ch": "alerts", "event": "alert.fired", "time": "2026-11-14T20:36:03.512Z",
 "data": {"id": 1203, "symbol": "XMRUSD", "direction": "down", "pct": -3.615, "…": "…"}}
eventWhen
alert.snapshotThe alert was there when you subscribed.
alert.firedA new alert.
alert.extendedA new leg of an alert: its legs, pct, price, last_leg_at and perhaps tier change, and its follow-up restarts.

Every frame carries the whole alert, as GET /alerts gives it. The follow-up's prices send no frame: read them with GET /alerts. Alert frames have no seq and no since_seq replay: after reconnecting, the snapshot sends the last day's alerts again, so keep each alert by its id and you miss nothing. {"op": "unsubscribe", "channels": ["alerts"]} ends it; alerts:SYM drops those instruments.

Ask an assistant: get_alerts

Over MCP, get_alerts answers the same JSON as GET /alerts: symbols (1–20), since, limit (1–50, default 10) and cursor. It is marked read-only. The check-before-trade prompt uses it to say whether the market has just moved sharply, and the server tells assistants to mention an alert as information, never as a signal or advice.

Automated and AI-driven trading can lose money quickly; nothing in these docs is investment advice.

JAFX (PTY) LTD · FSCA FSP No. 52058 · Trading leveraged derivatives with JAFX carries a high risk of losing money rapidly. It is not suitable for everyone.