Websocket

Order Feed

This document details how to get order feed on the Firstock Websockets.

Overview

The Order‑Feed delivers real-time updates on the status of your orders via a persistent WebSocket connection. It pushes notifications for activities like new orders, cancellations, success, and pending orders.

Response Structure

Body

On successful connection establishment, order updates will be received.

Order Placement API Parameters
Parameter Description
t‘om’ represents order update
norenordnoNoren Order Number
uidUser Id
actidAccount ID
exchExchange
tsymTrading symbol
qtyOrder quantity
prcOrder Price
pcodeProduct
statusOrder status (New, Replaced, Complete, Rejected etc)
reporttypeOrder event for which this message is sent out. (Fill, Rejected, Canceled)
trantypeOrder transaction type, buy or sell
prctypOrder price type (LMT, MKT, SL-LMT, SL-MKT)
retOrder retention type (DAY, EOS, IOC,...)
fillsharesTotal Filled shares for this order
avgprcAverage fill price
fltmFill Time (present only when reporttype is Fill)
flidFill ID (present only when reporttype is Fill)
flqtyFill Qty (present only when reporttype is Fill)
flprcFill Price (present only when reporttype is Fill)
rejreasonOrder rejection reason, if rejected
exchordidExchange Order ID
cancelqtyCanceled quantity, in case of canceled order
remarksUser added tag, while placing order
dscqtyDisclosed quantity
trgprcTrigger price for SL orders
snonumChild order number in cover/bracket orders, needed during exit
snoordtIndicates profit or stoploss type for child orders
blprcDifferential stop loss trigger price for cover/bracket parent orders
bpprcDifferential profit price for bracket parent orders
trailprcTrailing tick value for cover/bracket orders
exch_tmExchange update time (Format: dd-mm-YYYY hh:MM:SS)
amoIndicates if the order is After Market Order. Value: “Yes”
tmTimeStamp
ntmNano TimeStamp
kididKid Id
sno_fillidBO Sequence Id
rejbyIndicates source of rejection if order is rejected
dnameBroker specific contract display name, if applicable
handlinstDMA/TOUCH/WO
ordenttmOrder entry time
uidcUI_DEV_CODE
osOrder Source
aiAlgo ID

Response

{
   "t": "om",
   "norenordno": "25062300004000",
   "uid": "AB1234",
   "actid": "AB1234",
   "exch": "NSE",
   "tsym": "IDEA-EQ",
   "trantype": "B",
   "qty": "1",
   "prc": "0.00",
   "pcode": "C",
   "remarks": "Web app order",
   "rejreason": "RED:RULE:{Dont allow collateral and daylong cash for CAC buy}Shortfall:INR 2.71 Available:INR 3.77 for C-NP2997 [ONLINE]",
   "status": "REJECTED",
   "reporttype": "Rejected",
   "prctyp": "MKT",
   "ret": "DAY",
   "exchordid": "",
   "dscqty": "0"
}