Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
Accepted
1 1 1 1

How to get the bond information by Eikon API

I am using Eikon API to get data of bonds.

I want to know how to get the "含息价" of bond "CN230004", refer to the attachment.

Which "数据项代码" I shoud use?

// Eikon Python API

import eikon as ek

ek.set_app_key('-------------key----------------')

data= ek.get_data( ['CN230004'],[数据项代码???])


20230517113334.png

eikon-data-api#contentpython apibonds
20230517113334.png (410.0 KiB)
20230517113334.png (410.0 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

<AHS>

raising content ticket via myrefinitiv

Hello @chujingnian

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?


If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,


AHS

Please be informed that a reply has been verified as correct in answering the question, and has been marked as such.

Thanks,


AHS

Upvotes
Accepted
1.4k 5 3 6

Hi @chujingnian

Try this:

import refinitiv.data as rd
from refinitiv.data.content.ipa.financial_contracts import bond
rd.open_session() 
response = bond.Definition(
    instrument_code="CND100063XD1",
    fields=['DirtyPrice'],
    pricing_parameters = bond.PricingParameters(
    market_data_date="2023-05-17")).get_data()
response.data.df
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvote
14.2k 30 5 10

Hi @chujingnian ,

The moderators on this forum do not have deep expertise in every type of content available through Refinitiv products. Such expertise is available through Refinitiv Helpdesk. If the Helpdesk can show you how to retrieve it using =@TR formula in Eikon Excel, then the moderators on this forum can help you translate it into get_data method in the Eikon Data API call. Refinitiv Helpdesk can be reached via MyRefinitiv.

To be of help, I have opened a support case on your behalf, case 12571405, please expect an Eikon support expert to reach out to you shortly, via the email address you registered on the developers portal.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.