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

Identifier conversion to RIC

Hello,

I am trying to get the RIC of a list of banks I got through S&P Capital IQ. For each bank, I have their name, their primary industry, and sometimes their SNL, CIQ, CUSIP, ISIN and LEI identifiers. I converted the ISIN codes to RIC by using the code: ek.get_symbology( symbol = ISIN , from_symbol_type = "ISIN", to_symbol_type = "RIC"). However, I only have a limited number of ISIN identifiers available (only for one third of my sample). The problem is similar for the CUSIP identifier. I have much more SNL, CIQ and LEI identifiers, but they does not seem to be supported as inputs for the function ek.get_symbology. Do you know if there is a function where we could use either the CIQ, the LEI identifiers or even the name of the banks to get their RIC?

Thanks a lot in advance.

eikoneikon-data-apiisinric
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.

Hi @eikon114,

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
17.2k 82 39 63

Hi @eikon114

There is an RDP service (symbology) that will support the conversions you are after. For example, converting the following LEI to a RIC:

import refinitiv.data as rd
...
# Symbology
request_definition = rd.delivery.endpoint_request.Definition(
    method = rd.delivery.endpoint_request.RequestMethod.POST,
    url = 'https://api.refinitiv.com/discovery/symbology/v1/lookup',
    body_parameters = {         # Specify body parameters
        "from": [
            {
                "identifierTypes": ["LEI"],
                "values": ["549300561UZND4C7B569"]
            }
        ],
        "to": [
            {
                "identifierTypes": ["RIC"]
            }
        ],
        "path": [
            {
                "relationshipTypes": ["InverseIsPrimarySecurityOf"],
                "objectTypes": [
                    {
                        "from": "Organization",
                        "to": "AnyInstrument"
                    }
                ]
            },
            {
                "relationshipTypes": ["InverseIsValuationQuoteOf"],
                "objectTypes": [
                    {
                        "from": "AnyInstrument",
                        "to": "AnyQuote"
                    }
                ]
            }
        ],
        "reference": ["name","status","classification"],
        "type": "strict"
    }
)
response = request_definition.get_data()
# Dump the json response from the platform containing the results
response.data.raw
{'data': [
   {
      'input': [
      {
         'value': '549300561UZND4C7B569',     
         'identifierType': 'LEI'
      }],   
      'output': [
      {
         'value': 'TRI.TO',     
         'identifierType': 'RIC',     
         'name': 'THOMSON REUTERS ORD',     
         'status': 'Active',     
         'classification': 'Ordinary Shares'
      }]
   }], 
 'requestId': 'cae84148-61ce-4b1c-aac9-e2036035a519', 
 'effectiveAt': '2022-03-21T15:43:21.313Z', 
 'messages': []
}
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.

Upvotes
5.7k 21 2 6

Hi @eikon114,


Judging by the function `ek.get_symbology` mentioned in your question, I'm guessing that you're coding in Python?


Have you seen this answer (below) from my colleague? Does it answer your question?

https://community.developers.refinitiv.com/questions/72028/get-all-quotes-in-an-instrument-via-permid-api.html


If the above fails to help you, may I ask if searching the LEI, CIQ or name of the banks in the Eikon/Workspace search bar returns the correct RIC you're after? If so, I'd suggest using the Search API in Python. There's a great article on just that here:
https://developers.refinitiv.com/en/article-catalog/article/building-search-into-your-application-workflow

I also wrote a function that uses this API to output data in excel if that interests you. It is yet to be put into an article:

https://gist.github.com/johnukfr/241c2b360a30f96371f430005c8d7738

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.

Upvotes
25.3k 87 12 25

Hi @eikon114

The above suggestion requires access to the PermID API.

If you don't have access to PermID API, you can also take a look at a simple bulk symbology conversion example I put together for a client - using the RDP Library - which can connect to Eikon as well as the Refinitiv Data Platform.

GitHub - Refinitiv-API-Samples/Example.RDPLibrary.Python.ConvertSymbology: Simple notebook to convert ISINs (or other Symbology) to RICs using the Refinitiv Data Platform Symbology API

The above defaults to converting ISINs to RICS - but you can easily change the code to use others such as LEI.

You can run the above example against Eikon by creating a desktop session (rather than the platform session)

session = rdp.open_desktop_session(APP_KEY)

Note, however, that we will be replacing the RDP Library with the newer RD library - which also offers similar as well as additional features to the RDP library.

See the Symbology Tutorial for the RD Library

Symbology Tutorial | Refinitiv Developers

as well as the Endpoint tutorial - which is the interface used by my example above.

Endpoint Tutorial | Refinitiv Developers


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.

Upvotes
78.8k 250 52 74

@eikon114

You can use LEIs with the get_data method to get RICs. For example:

df, err = ek.get_data(
    instruments = ['549300561UZND4C7B569@LEI','WFLLPEPC7FZXENRZV188@LEI'],
    fields = ['TR.RIC']
)
df

The output is:

1647923887049.png

With the get_symbology method, you can set best_match=False to get all mapped symbols.

ek.get_symbology( symbol = ISIN , from_symbol_type = "ISIN", to_symbol_type = "RIC", best_match=False)

1647923887049.png (5.4 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.

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.