Case 08449503 - I'm trying to pull historical bond prices via the API. I can find this informatio...

...n under the "Price History" tab when looking at the bond's Eikon page (for example, CUSIP 64966MHL6 shows Bid/Ask prices for March 2nd as 124.273 and 124.773)

I'm trying to pull historical bond prices via the API. I can find this information under the "Price History" tab when looking at the bond's Eikon page (for example, CUSIP 64966MHL6 shows Bid/Ask prices for March 2nd as 124.273 and 124.773).

I'd like to pull this data, but *historically* via the Python API. Using:
data, e = ek.get_data(["64966MHL6=MSRB"], ["TR.CLOSEPRICE.date", "TR.CLOSEPRICE.value"], parameters={"Sdate":'2020-01-01', "Edate":'2020-03-03'})

I can see most of the closing prices, however, there is not a value for every date.

Using:
data, e = ek.get_data(["837151KZ1=MSRB"], ["TR.FIPrice.date", "TR.FIPrice.value"], parameters={"Sdate":'2020-01-01', "Edate":'2020-03-03'})

I can get just the most recent date--it doesn't seem to ever return a series for all of the values.

Ideally, I'd be able to pull the FIPrice (or, another price value that exists for every day) as a series.

What is the best way to do that?

Best Answer

Answers

  • Hi @Reginald.Flores

    I am assuming that you are posting this question on the client's behalf.

    Please note that this is a content question in which the helpdesk handles them with content team.


    I can only give overview of the information:

    According to Data Item Browser, TR.FIPrice does not support timeseries. So client cannot retrieve it as timeseries.

    image


    But TR.CLOSEPRICE supports timeseries

    image


  • Hi @chavalit-jintamalit,


    Client is still unable to perform what he needs on this. Please see reply below and I will check this from time-to-time regarding the progress.


    I have spent a considerable amount of time trying things in the Data Item Browser and none of what I could find matches what is on the Price History page. Again, what I want is this table (specifically the Bid/Ask columns):


    image


    I can get the current values, but not the historical ones.


    Any advise no how can we replicate similar table above using Python API?