For a deeper look into our DataScope Select REST API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
3 0 2 2

How to get FX rates from DSS rest API using python? any prerequisites needs to be done from our application?

pythondss-rest-apidatascope-selectdssforex
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.

@prakash.balusamy,

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

If yes please click the 'Accept' text beneath the reply. This will guide all community members who have a similar question.

Otherwise please post again offering further insight into your question.

Thanks, AHS

Upvote
Accepted
13.7k 26 8 12

@prakash.balusamy,

Prerequisites

  • There are no specific ones for Python, as the API is a pure REST API.
  • As DSS is a commercial product, you need DSS specific credentials (username and password) which you should have received if you are a customer.

Python

As the API is a REST API, any language that can process HTTP communication and can decode JSON can be used. Python is fine, it is easy to access DSS using Python.

Next steps

I guess you would benefit most from reading the Programming without SDK tutorial, which explains how to interact with the API using Python and Java, and also explains how you can identify which API call to use depending on what data you need.

How to get FX rates

At this point we cannot tell you exactly which API calls to use, because your query is not specific enough: what FX rates do you need ? Do you want an intraday snapshot, End of Day data, something else ? If you can tell us exactly what data you are trying to get, we can give you more details on how to retrieve it.

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
3 0 2 2

@Christiaan Meihsl,

What is difference between Intraday snapshot and End of day FX rate? currently, we are getting the rate from market data server, when we query each time for same RIC, we get different rates. I thought it's real time data.

in this case, what FX rate work for us?

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
13.7k 26 8 12

@prakash.balusamy,

The choice of the price type you need to request depends on your use case. Different use cases require different data, and the difference is very important from a financial and functional perspective. If you are unsure, please check this point with your business stakeholders, they will know.

Intraday snapshot

This is a snapshot of the current price, in other words something similar to what you get from your real-time market data server. Please bear in mind:

  • DSS is not a "real-time" product, it will not respond as fast as a real-time data feed, which is built for an entirely different purpose.
  • Receiving a snapshot of the current price implies you are entitled for real-time data (that is a contractual aspect). If you are not entitled for real-time data you can request delayed data using a / in front of the RIC. A delayed price is the price of some minutes ago. The delay depends on the data provider. I don't know what the delay is for FX. For Xetra (the german exchange) the delay is 15 minutes.

End of Day

This is the price at the end of the previous trading day.

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.

Hello, Christiaan,


could you elaborate on this a bit further? For example, if I have BMW in my identifier list and want to ask the Last Price from 15min ago, where would I put the slash / ?

"Identifier": "BMWG.DE",
"IdentifierType": "Ric"


Just before the B? Like this:

"Identifier": "/BMWG.DE",

"IdentifierType": "Ric"

That is not working on my end, I get "All identifiers were invalid".


Thank you very much

Upvotes
3 0 2 2

@Christiaan Meihsl, Thanks for your answers!

I have discussed with business stakeholders, they need Intraday snapshot data.

Below are few question I have for now,

  1. For testing, DSS have any testing host or Do I need to use the actual host which DSS provided for production?
  2. For Intraday snapshot extract, can I use "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.IntradayPricingExtractionRequest" ? or I need to check with DSS support team to get exact type
  3. Do I need to raise Firewall between our network and DSS network? because I am getting the below error:
    Error: Status Code:403 Message:{"error":{"message":"No permission for template \"IntradayPricingReportTemplate\"."}}


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
13.7k 26 8 12

@prakash.balusamy,

To your 3 queries:

  1. You must use the production host.
  2. Yes, that is the right type. See the DSS tutorial on intraday requests for details.
  3. The 403 error means you are not allowed to request intraday data. For permission issues, you need to contact your Refinitiv account manager. For explanations on the HTTP return codes, see the HTTP status help page.
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.

@Christiaan Meihsl, Thanks for your answers!

What's the port number for DSS production host (159.43.0.2) ? Is't 443?

@prakash.balusamy, yes, it is standard HTTPS, i.e. TCP 443.

As a side note, please post new queries in separate threads, that will ensure they get attention from the moderators.

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.