Returned fields in datagrid api different from python api and also not consistent

Hi I am confused about how GetData fields are returned from the datagrid api

I have made the following request:

POST https://api.refinitiv.com/data/datagrid/beta1/

BODY:

{
 "universe": [
   "AAPL.O"
 ],
 "fields": [
   "TR.IssueMarketCap(Scale=6,ShType=FFL)",
   "TR.FreeFloatPct()/100/*FreefloatWeight*/",
   "TR.IssueSharesOutstanding(Scale=3)/*shares outstanding*/",
   "TR.CLOSEPRICE(Adjusted=0)/*close*/"
 ],
 "parameters": {
   "Curn": "USD",
   "SDate": "2020-10-27",
   "EDate": "2020-12-01"
 }
}


See also the resulting screenshot: Screenshot 2023-11-23 114750.png

the returned headers for field:

"TR.IssueSharesOutstanding(Scale=3)/*shares outstanding*/",

are

"TR.IssueSharesOutstanding"

also IssueMarketCap and IssueSharesOutstanding are simplified in a similar manner

While on the other hand field returns for:

"TR.FreeFloatPct()/100/*FreefloatWeight*/"

are as they have been supplied.

How can I make sure that the headers return the fields as previously supplied to them?

Best Answer

  • raksina.samasiri
    Answer ✓

    Hi @laurens ,

    Can you try this

    {
    "universe": [
    "AAPL.O"
    ],
    "fields": [
    "TR.IssueMarketCap(Scale=6,ShType=FFL)",
    "Setlabel(TR.FreeFloatPct()/100,FreefloatWeight)",
    "Setlabel(TR.IssueSharesOutstanding(Scale=3),SharesOutstanding)",
    "Setlabel(TR.CLOSEPRICE(Adjusted=0),close)"
    ],
    "parameters": {
    "Curn": "USD",
    "SDate": "2020-10-27",
    "EDate": "2020-10-28"
    }
    }

    The result is as below

    1701238489601.png

    Hope this helps and please let me know in case you have any further questions

Answers