Order and Trades
Interop Positions Book
POST
/NorenWClientAPI/InteropPositionBookAuthorization token is required. Enter your access_token from GenAcsTok above.
jData fields
Values are sent as a JSON string in the jData form field.
Account id of the logged in user.
Authorization Token
Required for all API calls. Use the access_token from the GenAcsTok response as a Bearer token.
Request to be POSTed to url : /NorenWClientAPI/InteropPositionBook
Request Details
| Parameter Name | Possible value | Description |
|---|---|---|
| jData* | Should send json object with fields in below list | |
| Authorization* | Bearer <access_token> | access_token from GenAcsTok response. Required for all API calls. |
| Json Fields | Possible value | Description |
|---|---|---|
| actid* | Account id of the logged in user. |
Example
curl https://apitest.kambala.co.in/NorenWClientAPI/InteropPositionBook \
-d "jData={\"actid\":\"ACCT_1\"}"Response Details
Response data will be in json format with Array of Objects with below fields in case of success:
| Json Fields | Possible value | Description |
|---|---|---|
| stat | Ok or Not_Ok | Position book success or failure indication. |
| exch | Exchange segment | |
| tsym | Trading symbol / contract. | |
| token | Contract token | |
| uid | User Id | |
| actid | Account Id | |
| prd | Product name to be shown. | |
| s_prdt_ali | Product display name | |
| daybuyqty | Day Buy Quantity | |
| daysellqty | Day Sell Quantity | |
| daybuyamt | Day Buy Amount | |
| daysellamt | Day Sell Amount | |
| cfbuyqty | Carry Forward Buy Quantity | |
| cfsellqty | Carry Forward Sell Quantity | |
| cfbuyamt | Carry Forward Buy Amount | |
| cfsellamt | Carry Forward Sell Amount | |
| openbuyqty | Open Buy Quantity | |
| opensellqty | Open Sell Quantity | |
| openbuyamt | Open Buy Amount | |
| opensellamt | Open Sell Amount | |
| instname | Instrument Name | |
| upload_prc | Upload Price | |
| buyavgprc | Buy Average Price [(daybuyamt + cfbuyamt) / (daybuyqty + cfbuyqty)] | |
| sellavgprc | Sell Average Price [(daysellamt + cfsellamt) / (daysellqty + cfsellqty)] | |
| rpnl | Realized PnL | |
| netqty | Net Quantity [daybuyqty + cfbuyqty - daysellqty - cfsellqty] | |
| totbuyamt | Total Buy Amount | |
| totsellamt | Total Sell Amount | |
| totbuyavgprc | Total Buy Avg Price | |
| totsellavgprc | Total Sell Avg Price | |
| openbuyavgprc | Open Buy Average Price | |
| opensellavgprc | Open Sell Average Price | |
| cfbuyavgprc | Carry Forward Buy average price | |
| cfsellavgprc | Carry Forward Sell average price | |
| child_orders | Array Object | Details given below |
| netavgprc | Net Average Price | |
| mult | Multiplier | |
| urmtom | Unrealized MTOM | |
| prcftr | Price Factor |
Child Orders Object Format
| Json Fields | Possible value | Description |
|---|---|---|
| exch | Exchange segment | |
| token | Contract token | |
| daybuyqty | Day Buy Quantity | |
| daysellqty | Day Sell Quantity | |
| daybuyamt | Day Buy Amount | |
| daysellamt | Day Sell Amount | |
| cfbuyqty | CF Buy Quantity | |
| cfsellqty | CF Sell Quantity | |
| cfbuyamt | CF Buy Amount | |
| cfsellamt | CF Sell Amount | |
| openbuyqty | Open Buy Quantity | |
| opensellqty | Open Sell Quantity | |
| openbuyamt | Open Buy Amount | |
| opensellamt | Open Sell Amount | |
| upload_prc | Upload Price | |
| totbuyamt | Total Buy Amount | |
| totsellamt | Total Sell Amount | |
| totbuyavgprc | Total Buy Avg Price | |
| totsellavgprc | Total Sell Avg Price | |
| openbuyavgprc | Open Buy Average Price | |
| opensellavgprc | Open Sell Average Price | |
| cfbuyavgprc | Carry Forward Buy average price | |
| cfsellavgprc | Carry Forward Sell average price | |
| netupldprc | Net Upload Price |
Response Details in case of failure
| Json Fields | Possible value | Description |
|---|---|---|
| stat | Not_Ok | Interop Position book request failure indication. |
| request_time | Response received time. | |
| emsg | Error message |
Sample Success Response
[
{
"stat":"Ok",
"actid":"TESTINV1",
"exch":"EQT",
"token":"PRAKASH",
"prd":"I",
"openbuyqty":"00",
"opensellqty":"09",
"openbuyamt":"00",
"opensellamt":"54000",
"daybuyqty":"01",
"daysellqty":"01",
"daybuyamt":"6000",
"daysellamt":"6000",
"cfbuyqty":"00",
"cfsellqty":"00",
"cfbuyamt":"00",
"cfsellamt":"6000",
"child_orders": [
{
"exch":"NSE",
"token":"2708",
"openbuyqty":"00",
"opensellqty":"09",
"openbuyamt":"00",
"opensellamt":"54000",
"daybuyqty":"00",
"daysellqty":"01",
"daybuyamt":"00",
"daysellamt":"6000",
"cfbuyqty":"00",
"cfsellqty":"00",
"cfbuyamt":"00",
"cfsellamt":"00",
"upload_prc":"00"
},
{
"exch":"BSE",
"token":"506022",
"openbuyqty":"00",
"opensellqty":"00",
"openbuyamt":"00",
"opensellamt":"00",
"daybuyqty":"01",
"daysellqty":"00",
"daybuyamt":"6000",
"daysellamt":"00",
"cfbuyqty":"00",
"cfsellqty":"00",
"cfbuyamt":"00",
"cfsellamt":"00",
"upload_prc":"00"
}
]
}
]Sample Failure Response
{
"stat":"Not_Ok",
"request_time":"14:14:11 26-05-2020",
"emsg":"Error Occurred : 5 \"no data\""
}curl --request POST \
--url 'https://api.infinn.in/NorenWClientAPI/InteropPositionBook' \
--header 'Content-Type: text/plain' \
--data 'jData={}'Response will appear here after sending a request