GetLastQuoteShortWithClose

GetLastQuoteShortWithClose : Returns LastTradePrice of Single Symbol (short) with Close of Previous Day

Supported parameters
accessKeyAccess key according to your subscriptionRequired parameter.
exchangeString value like MCXName of supported exchange. How to get list of supported exchanges you can find here
instrumentIdentifierValue of instrument identifierHow to get list of available instruments and identifiers you can find here.
You will need to use URL Econding for instrument identifiers with special characters (like BAJAJ-AUTO, M&M, L&T, NIFTY 50, etc.) as explained here
xml[true]/[false], default = [false]Optional parameter. By default function will return JSON data. Functions will return XML data if set as [true]
isShortIdentifier[true]/[false], default = [false]Optional parameter. By default function will use long instrument identifier format. Functions will use short instrument identifier format if set as [true]. Example of ShortIdentifiers are NIFTY25MAR21FUT, RELIANCE25MAR21FUT, NIFTY25MAR2115000CE, etc.
Examplehttp://endpoint:port/GetLastQuoteShortWithClose/?accessKey=0a0b0c&exchange=MCX&instrumentIdentifier=XXX_MCX0_25MAR2021_XX_X&xml=true&isShortIdentifier=true
What is returned ?
Exchange, InstrumentIdentifier (Symbol), LastTradeTime, BuyPrice (Bid Price), Close (Previous Trading Day’s Close), LastTradePrice, SellPrice (Ask Price)
LastTradeTime : In JSON Response, this value is expressed as no. of seconds since Epoch time (i.e. 1st January 1970). Also known as Unix Time. Please Visit https://www.epochconverter.com/ to get formulae to convert human readable time to Epoch and vice versa (scroll to end of their home page)
Example of returned data
JSONXML
{ “BUYPRICE”: 870.1, “EXCHANGE”: “MCX”, “INSTRUMENTIDENTIFIER”: “XXX_MCX0_25MAR2021_XX_X”, “LASTTRADEPRICE”: 875, “LASTTRADETIME”: 1391863200, “SELLPRICE”: 874, “CLOSE”: 860.2}
<?xml version=”1.0″ encoding=”utf-16″ ?>

<Realtime

xmlns:xsd=”http://www.w3.org/2001/XMLSchema”
xmlns:xsi=”http://www.w3.org/2001/XMLSchema-instance”>
Exchange=”MCX” InstrumentIdentifier=”XXX_MCX0_25MAR2021_XX_X” LastTradeTime=”2-8-2014 12:40:00 PM” BuyPrice=”870.1″ LastTradePrice=”875″ SellPrice=”874″ Close=”860.2″

/>

Was this helpful?