What types of fund codes does the Eikon API support

There are many types of fund code, refer to the screenshot, what types of fund codes be supported when I using the Eikon get_data api? If I can use China Code CE as instruments param or not?

df, err = ek.get_data(instruments=[fund code], fields=[
"TR.RICCode",
"CF_NAME",
"CF_CURR",
"CF_DATE",
"CF_TIME",
"TR.FundLaunchDate"
])

1686202393566.png


Tagged:

Best Answer

  • m.bunkowski
    Answer ✓

    Hi @anchu
    If you want to convert China Code as an input code you may want to use this approach. Here the output is ANY but you can define to the one of your choice.

    import refinitiv.data as rd
    rd.open_session()
    url = 'https://api.refinitiv.com/discovery/symbology/v1/lookup';
    body={
    "from": [
    {
    "identifierTypes": [
    "ChinaCode"
    ],
    "values": [
    "001751"
    ]
    }
    ],
    "to": [
    {
    "identifierTypes": [
    "ANY"
    ]
    }
    ],
    "reference": [
    "name",
    "status",
    "classification"
    ],
    "type": "strict"
    }

    request = rd.delivery.endpoint_request.Definition(
    method = rd.delivery.endpoint_request.RequestMethod.POST,
    url = url,
    body_parameters = body
    )
    response = request.get_data()
    data = response.data.raw['data']
    data

Answers

  • @anchu , If possible use Lipper ID or the RIC that is just have the "LP" followed by the Lipper ID. The China code is too short so it usually not working as that part of the code can be part of other codes in other coding schemes. Longer code such as ISIN work pretty well.

    I am not sure if the Eikon API can specify the coding scheme to do the matching, as I never saw any code can do that.

  • @bob.lee Thanks for your information. I want to know if there is any Ekion or RD API can query the Lipper ID/RIC/ISIN code via China code? I only know it's able to query the fund via China code in Eikon application.

  • Hi @anchu , I only know the RDP Funds API have this ability, I am not sure if Eikon API or other API can do that or not. The sample query for the RDP Funds API to check cross-reference codes is:

    https://api.refinitiv.com/data/funds/v1/assets?symbols=001751&properties=codes

    You should get the JSON response as shown at the bottom of this message. That means you got the reference codes for your sample code "001751" as below. Notes, I think you need to check the JSON response to see if more than 1 records is returned and use the China Code to check to make sure you get the correct record just in case another coding scheme also got the same ID for another fund.

    001751  RIC / Triarch Code      LP68331664
    001751 RIC LP68331664
    001751 China Code FE 001751
    001751 Perm ID 180683316
    001751 RIC / Triarch Code LP68331664
    001751 LipperId 68331664

    Sample JSON reponse:

    {
    "assets": [
    {
    "id": "001751",
    "codes": [
    {
    "code": "RICTRIARCH",
    "type": {
    "id": "1425",
    "name": "RIC / Triarch Code"
    },
    "values": [
    {
    "value": "LP68331664"
    }
    ]
    },
    {
    "code": "RIC",
    "type": {
    "id": "26",
    "name": "RIC"
    },
    "values": [
    {
    "value": "LP68331664",
    "date": "2015-09-15"
    }
    ]
    },
    {
    "code": "CHINA",
    "type": {
    "id": "5422",
    "name": "China Code FE"
    },
    "values": [
    {
    "value": "001751"
    }
    ]
    },
    {
    "code": "OAID",
    "type": {
    "id": "36941",
    "name": "Perm ID"
    },
    "values": [
    {
    "value": "18068331664"
    }
    ]
    },
    {
    "code": "CHINA_HLD",
    "type": {
    "id": "5422",
    "name": "China Code FE"
    },
    "values": [
    {
    "value": "001751"
    }
    ]
    },
    {
    "code": "RIC_HLD",
    "type": {
    "id": "1425",
    "name": "RIC / Triarch Code"
    },
    "values": [
    {
    "value": "LP68331664"
    }
    ]
    },
    {
    "code": "LIPPERID",
    "type": {
    "id": "4002",
    "code": "LIPPERID",
    "name": "LipperId"
    },
    "values": [
    {
    "value": "68331664"
    }
    ]
    }
    ]
    }
    ],
    "totalRecords": 1,
    "fromIndex": 0,
    "toIndex": 0,
    "pageNumber": 0
    }