Single stock or Basket Order response
Order response enums
{
"orderBatches": [
{
"batchId": "String",
"buyAmount": "Number",
"completedDate": "Date",
"filled": "Number",
"orders": [{
"exchangeOrderId": "String",
"status": {
"type": "String",
"enumValues": [
"PLACED",
"REJECTED",
"CANCELLED",
"COMPLETE",
"ERROR",
"CANCELLED AMO",
"PARTIAL"
]
},
"tradingsymbol": "String",
"quantity": "Number",
"filledQuantity": "Number",
"averagePrice": "Number",
"orderType": {
"type": "String",
"enumValues": [
"MARKET",
"LIMIT"
]
},
"transactionType": "String",
"product": {
"type": "String",
"enumValues": [
"CNC",
]
},
"exchange": {
"type": "String",
"enumValues": [
"NSE",
]
}
}],
"quantity": "Number",
"sellAmount": "Number",
"status": {
"type": "String",
"enumValues": [
"ERROR",
"UNPLACED",
"PARTIALLYPLACED",
"UNFILLED",
"PARTIALLYFILLED",
"COMPLETED",
"FIXED",
"MARKEDCOMPLETE",
"CANCELLED"
]
},
"transactionId": "String",
"unplaced": [{
"exchangeOrderId": "String",
"status": {
"type": "String",
"enumValues": [
"PLACED",
"REJECTED",
"CANCELLED",
"COMPLETE",
"ERROR",
"CANCELLED AMO",
"PARTIAL"
]
},
"tradingsymbol": "String",
"quantity": "Number",
"filledQuantity": "Number",
"averagePrice": "Number",
"orderType": {
"type": "String",
"enumValues": [
"MARKET",
"LIMIT"
]
},
"transactionType": "String",
"product": {
"type": "String",
"enumValues": [
"CNC",
"NRML"
]
},
"exchange": {
"type": "String",
"enumValues": [
"NSE",
"BSE"
]
}
}],
"variety": {
"type": "String",
"enumValues": [
"amo", //for AMO
"regular"
]
}
}
],
"smallcaseAuthToken": "String",
"transactionId": "String",
"notes": "256 char String, if sent while creating transaction",
}
Sample market order response
{
"smallcaseAuthToken": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzbWFsbGNhc2VBdXRoSWQiOiI1ZGQ0MzQwMjVlODFmMDRiMTU5YWIyMzAiLCJpYXQiOjE1NzU1NDg4MTEsImV4cCI6MTU3NTU1MjQxMX0.aBtX5szel5kqkBmkgtP8LAJLwfdJWKJVGzf5MlgmtPY",
"notes": "test string",
"orderBatches": [{
"transactionId": "TRX_0427c6474d984eb1b0e1257e3bcc01d8",
"filled": 5,
"variety": "regular",
"buyAmount": 38410.21,
"sellAmount": 0,
"orders": [{
"orderType": "MARKET",
"product": "CNC",
"exchange": "NSE",
"status": "CANCELLED",
"quantity": 10,
"tradingsymbol": "ITC",
"transactionType": "BUY",
"filledQuantity": 0,
"averagePrice": 246.00300000000001,
"exchangeId": 1100000004830698
}, {
"orderType": "MARKET",
"product": "CNC",
"exchange": "NSE",
"status": "COMPLETE",
"quantity": 10,
"tradingsymbol": "HDFCBANK",
"transactionType": "BUY",
"filledQuantity": 10,
"averagePrice": 1244.996,
"exchangeId": 1100000004830698
}, {
"orderType": "MARKET",
"product": "CNC",
"exchange": "NSE",
"status": "COMPLETE",
"quantity": 10,
"tradingsymbol": "TCS",
"transactionType": "BUY",
"filledQuantity": 10,
"averagePrice": 2121.02,
"exchangeId": 1100000004830698
}],
"unplaced": [{
"exchange": "NSE",
"status": "ERROR",
"quantity": 2,
"tradingsymbol": "ASIANPAINT",
"transactionType": "BUY"
}],
"batchId": "5de8f785e392ec3751dc841d",
"notes": "abc-xyz",
"quantity": 7,
"status": "MARKEDCOMPLETE",
"completedDate": "2019-12-05T12:26:46.535Z"
}]
}
Sample after market order response
{
"smallcaseAuthToken": "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzbWFsbGNhc2VBdXRoSWQiOiI1ZWNkMWUyY2EyOWQ3NzAyYTY5MGU5NGMiLCJpYXQiOjE1OTA1MDEzNTcsImV4cCI6MTU5MDUwNDk1N30.gwTdXPSeaR-e1fb0KbhERLIXnB8Cw-H9iI9anCWpJSg",
"notes": "test string",
"transactionId": "TRX_5ea67528b48c42d1b35c6896d37e5d22",
"batchId": "5ef0a1ee366ba431832dfc30",
"buyAmount": 0,
"sellAmount": 0,
"quantity": 2,
"filled": 0,
"status": "PLACED",
"variety": "amo",
"orders": [{
"status": "PLACED",
"quantity": 1,
"tradingsymbol": "M100",
"transactionType": "BUY",
"exchange": "NSE",
"orderType": "MARKET",
"product": "CNC"
}, {
"status": "PLACED",
"quantity": 1,
"tradingsymbol": "ICICIB22",
"transactionType": "BUY",
"exchange": "NSE",
"orderType": "MARKET",
"product": "CNC"
}],
"unplaced": []
}
Identify if the order was placed as Market or AMO
Please note that variety = amo is used to identify if the order was after market order. Successful after market order will have status as PLACED.
In this case the order will be executed in the next trading sessionIf the variety = regular, order was placed as market order. Status response for a successful order in this case can be COMPLETE
smallcase order response
Order response enums
{
"notes": "test string",
"smallcaseAuthToken": "String",
"transactionId": "String",
"orderBatches": [{
"label": {
"type": "String",
"enumValues": [
"BUY",
"INVESTMORE",
"REBALANCE",
"SIP",
"MANAGE",
"EXIT",
"REPAIR"
]
}
"originalLabel": {
"type": "String",
"enumValues": [
"BUY",
"INVESTMORE",
"REBALANCE",
"SIP",
"MANAGE",
"EXIT",
"REPAIR"
]
},
"status": "COMPLETED",
"variety": {
"type": "String",
"enumValues": [
"amo", //for AMO
"regular"
]
},
"buyAmount": "Number",
"sellAmount": "Number",
"completedDate": "Date",
"quantity": "Number | Integer",
"filled": "Number | integer",
"batchId": "String",
"orders": [{
"exchangeOrderId": "String",
"status": {
"type": "String",
"enumValues": [
"PLACED", //for AMO
"REJECTED",
"CANCELLED",
"COMPLETE",
"ERROR",
"CANCELLED AMO",
"PARTIAL"
]
},
"tradingsymbol": "String",
"quantity": "Number | Integer",
"filledQuantity": "Number | integer",
"averagePrice": "Number",
"orderType": {
"type": "String",
"enumValues": [
"MARKET",
"LIMIT"
]
},
"transactionType": {
"type" : "String",
"enumValues": [
"BUY",
"SELL"
]
},
"product": {
"type": "String",
"enumValues": [
"CNC",
]
},
"exchange": {
"type": "String",
"enumValues": [
"NSE"
]
}
}],
"unplaced": []
}]
}
Broker Holdings response
{
"success": true,
"errors": null,
"data": {
"smallcases": {
"public": [
{
"scid": "SCAW_0001",
"name": "All Weather Investing",
"investmentDetailsURL": "https://smallcase.zerodha.com/details/5f2d22636678954954f29a2d?",
"shortDescription": "Diversify with equity, gold & fixed income ETFs for recession-proof investing",
"imageUrl": "https://assets.smallcase.com/images/smallcases/200/SCAW_0001.png",
"stats": {
"currentValue": 4921.89,
"totalReturns": -36.65253999999927
},
"constituents": [
{
"ticker": "NIFTYBEES",
"shares": 10
},
{
"ticker": "JUNIORBEES",
"shares": 3
},
{
"ticker": "LIQUIDBEES",
"shares": 1
},
{
"ticker": "GOLDBEES",
"shares": 39
}
]
}
],
"private": {
"stats": {
"currentValue": 0,
"totalReturns": 0
}
}
},
"securities": {
"holdings": [
{
"ticker": "ABFRL",
"shares": 8,
"name": "Aditya Birla Fashion and Retail Ltd",
"exchange": "NSE",
"averagePrice": 163.8
},
{
"ticker": "HDFCBANK",
"shares": 2,
"name": "HDFC Bank Ltd",
"exchange": "BSE",
"averagePrice": 1232.65
},
{
"ticker": "ICICIBANK",
"shares": 4,
"name": "ICICI Bank Ltd",
"exchange": "BSE",
"averagePrice": 416.1875
},
{
"ticker": "ICICILOVOL",
"shares": 2,
"name": "ICICI Prudential Nifty 100 Low Vol 30 ETF",
"exchange": "BSE",
"averagePrice": 94.87
},
{
"ticker": "ICICINIFTY",
"shares": 51,
"name": "ICICI Prudential Nifty 50 ETF",
"exchange": "NSE",
"averagePrice": 82.478431
},
{
"ticker": "ICICINV20",
"shares": 2,
"name": "ICICI Prudential NV20 ETF",
"exchange": "BSE",
"averagePrice": 58.87
},
{
"ticker": "ICICINXT50",
"shares": 4,
"name": "ICICI Prudential Nifty Next 50 ETF",
"exchange": "BSE",
"averagePrice": 28.67
},
{
"ticker": "INFY",
"shares": 5,
"name": "Infosys Ltd",
"exchange": "BSE",
"averagePrice": 690.7
},
{
"ticker": "RELIANCE",
"shares": 16,
"name": "Reliance Industries Ltd",
"exchange": "BSE",
"averagePrice": 1909.69375
}
]
},
"updating": false,
"lastUpdate": "2020-11-05T08:12:16.799Z",
"snapshotDate": "2020-11-05T08:12:16.799Z",
"smallcaseAuthId": "5ee21fa8df87c51bab457f96"
}
}
Updated 3 months ago