question

Upvotes
Accepted
3 0 0 3

Python RDP: IPA Financial Contracts: Caps/Floors, how to add "firstRegularPaymentDate" argument

Hi, I am trying to add an argument for "firstRegularPaymentDate" to the definition of a CAP instrument. I can see on the API that this argument is permitted, however, I can't work out how to add this argument in Python RDP. I need to use the RDP not API to perform this calculation.

Documentation of available term in the Refinitiv guide:

1697827725343.png

In RDP, I do not see this argument? Does it go under "extended_params"? If so, what is the correct way to pass in this argument?

1697828262888.png


rdpipa
1697827725343.png (22.3 KiB)
1697828262888.png (225.1 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.

Upvote
Accepted
5.8k 21 2 6

Hi @Dan.Camp1,


Please note that the default use of IPA parameters is to pass them through the `extended_params` dict. as such:

response = rdf.cap_floor.Definition(
    extended_params={         "instrumentType": "CapFloor",         "instrumentDefinition": {             "buySell": "Sell",             "floorStrikePercent": 1,             "indexTenor": "1M",             "notionalCcy": "EUR",             "startDate": "2019-02-11T00:00:00Z",             "tenor": "5Y",         },         "pricingParameters": {},     } ).get_data()

You can find the variable names & details here.


However, for ease of use, we implemented the most commonly used parameters directly as argument in `rdf.cap_floor.Definition`:

response = rdf.cap_floor.Definition(
    notional_ccy="EUR",     start_date="2019-02-11",     tenor="5Y",     index_tenor="1M",     buy_sell="Sell",     floor_strike_percent=1,     pricing_parameters=rdf.cap_floor.PricingParameters(), ).get_data()


For what youy're after, I believe that you'd want something as such:

response = rdf.cap_floor.Definition(
    notional_ccy="EUR",
    start_date="2019-02-11",
    tenor="5Y",
    index_tenor="1M",
    buy_sell="Sell",
    floor_strike_percent=1,
    pricing_parameters=rdf.cap_floor.PricingParameters(),
    extended_params={
        "instrumentType": "CapFloor",
        "instrumentDefinition": {
            "firstRegularPaymentDate": "2019-02-11T00:00:00Z",
        },
        "pricingParameters": {},
    },
).get_data()


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.

Thanks, this was exactly what I was after. Thanks for the explanation!
Upvotes
19 1 1 6

Short related question: are you talking about RDP or RD here? As far as I understood the RDP shouldn't be used anymore. Sorry, but I always mix these up.

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 @Anufriyev, Yes it's very confusing, that's actually why we moved from the RDP (Refinitiv Data Platform) Libs. to the RD (Refinitiv Data) Libs.; but even though the former is deprecated, it does lead to confusion.

For clarity, the above relates to the RD Lib.

Also for clarity: note that as it stands today, RDP stads for the Refinitiv Data Platform, not the Libraries; the differnece between the two is that the Platform hosts many diferent API Families that are accessible via RESTfull Endpoints, and the RD Libs. are wrappers (in Python, .Net or TypeScript) that send data requests to the RDP via these Endpoints.

Thank you very much for clarification, @jonathan.legrand ! So earlier it was RDP SDK for RDP API and now it is RD SDK for RDP API :) . And also as far as I understand now RD SDK is for Eikon API :)

Hi @Anufriyev , Yes that's right. Very complicated indeed. It is true that you can access the old EDAPI (Eikon Data API) functions through the RD Libs. as you point out.
Upvotes
19 1 1 6

Hi again @jonathan.legrand It became even more stranger: now I get this "FutureWarning":111.png

So I shouldn't use RD for Eikon API?


111.png (8.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.

Hi @Anufriyev, Yes, it is true that we are phasing out Eikon and all its related tech, and replacing it with a new stack. You can find out more about this here. In truth, the best way to future proof one's code is to use the RD Lib., not the EDAPI, as per the warning.

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.