Skip to content

Strategy Status ​

Read one owned Strategy RMS configuration, its legs, and its current run when one exists.

Endpoint URL ​

http
Local Host   :  POST http://127.0.0.1:5000/api/v1/strategy/status
Ngrok Domain :  POST https://<your-ngrok-domain>.ngrok-free.app/api/v1/strategy/status
Custom Domain:  POST https://<your-custom-domain>/api/v1/strategy/status

Sample API Request ​

json
{
  "apikey": "<your_app_apikey>",
  "strategy_id": 7
}

Sample cURL Request ​

bash
curl -X POST http://127.0.0.1:5000/api/v1/strategy/status \
  -H 'Content-Type: application/json' \
  -d '{
  "apikey": "<your_app_apikey>",
  "strategy_id": 7
}'

Sample API Response ​

json
{
  "status": "success",
  "data": {
    "id": 7,
    "name": "NIFTY Short Straddle",
    "strategy_kind": "batch",
    "status": "running",
    "current_run_id": 42,
    "legs": [
      {
        "id": 1,
        "segment": "options",
        "position": "S",
        "lots": 1,
        "option_type": "CE",
        "expiry": "weekly"
      }
    ]
  },
  "run": {
    "id": 42,
    "mode": "sandbox",
    "broker": "sandbox",
    "started_at": "2026-08-30T03:50:11.402118+00:00",
    "stopped_at": null,
    "stop_requested_at": null,
    "stop_requested_reason": null,
    "pnl_realized": 0.0,
    "pnl_peak": 4880.0,
    "pnl_trough": -1220.25,
    "resolved_expiries": {"1": "04-SEP-26"}
  }
}

Request Body ​

ParameterDescriptionMandatory/OptionalDefault Value
apikeyYour Tradeboard API keyMandatory-
strategy_idPositive Strategy RMS idMandatory-

Response Fields ​

FieldTypeDescription
statusstringsuccess or error
dataobjectStrategy configuration, including its saved leg definitions
runobject or nullCurrent run, or null when no run is current

Leg Fields ​

data.legs is the saved configuration, and the two kinds do not share a shape. A batch leg is resolved against the strategy's underlying; a signal leg names its own instrument.

FieldKindDescription
idbothLeg id, unique within the strategy
segmentbothoptions, futures, or cash. A batch leg's segment must be one its universe_tab offers, and cash is offered on stocks_fno only: an index has no cash instrument and an MCX commodity has no spot. A signal leg takes cash or futures only
positionbatchB or S. A short cash leg is refused unless the product is MIS, because cash cannot be carried short
lotsbatchThe configured count, multiplied by the contract's lot size on every segment. A cash row's lot size is 1, so the count reads as a share count
expirybatchExpiry rank; refused outright on a cash leg
option_type, strike_mode, atm_offset, strikebatchOptions legs only
symbol, exchangesignalThe exact instrument, checked against the master contract on every venue. The segment and the exchange must agree: cash cannot sit on a derivative venue
sidesignallong, short, or both. Which signals the leg accepts, not the side it is held
qty, qty_modesignallots multiplies by the contract's lot size; units is the number outright. A derivative venue defaults to lots and a cash venue to units, and lots is refused on cash because there is no lot size to multiply by
sl_pts, target_pts, trailbothPer-leg risk
risk_unitbothpoints (the default) or percent, governing sl_pts, target_pts and trail together. A percentage is measured against the leg's own entry price, so 2 on a short filled at 2500 is a stop at 2550

Run Object Fields ​

FieldTypeDescription
idintegerRun id
modestringlive or sandbox, fixed for the run
brokerstringBroker captured at start; sandbox for a sandbox run
started_at, stopped_atstring or nullISO 8601 UTC timestamps
stop_reasonstring or nullTerminal reason once finalised
stop_requested_at, stop_requested_reasonstring or nullDurable pending-stop state
pnl_realizednumberRealised P&L after confirmed-flat finalisation
pnl_peak, pnl_troughnumberHighest and lowest run P&L
trigger_sourcestringmanual, webhook, or scheduler
resolved_expiriesobject or nullResolved expiry by string leg id

Notes ​

  • A non-null stop_requested_at or stop_requested_reason means the run remains open and managed. Do not treat a stop request as proof of flatness.
  • On an open run, P&L fields are persisted values rather than a current market mark. Use a finalised Run History record for realised P&L.
  • resolved_expiries preserves the contract identity that was chosen at run start.
  • A missing strategy and a strategy owned by another user both return HTTP 404 with Strategy not found.

Back to: Strategy RMS API