Websocket API didn't receive response after Service Discovery Call

Hello!
We succesfully received token via https://api.refinitiv.com:443/auth/oauth2/v1/token
and then we are trying to call https://api.refinitiv.com/streaming/pricing/v1/?transport=websocket.
But this https://api.refinitiv.com/streaming/pricing/v1/?transport=websocket does not return anything.
One day ago, the request https://api.refinitiv.com/streaming/pricing/v1/?transport=websocket correctly returned a list of endpoints.
If i try to call https://api.refinitiv.com/streaming/pricing/v1/?transport=websocket via browser it return
code"401"message"Authorization header is missing"status"Unauthorized"
so we has an network access.
What it can be?
Best Answer
-
Hi @elektron
Are you using C#?
If so, there is an issue due to the increase in the number of services added over the weekend, the response has started being chunked.
As a result of this, if you are using the C# example or another scenario where you are checking the service discovery response content length - this would now return -1 and something like the following would now fail:
if (webResponse.ContentLength > 0)
so the above should be replaced with something like:
if (webResponse.GetResponseHeader("Transfer-Encoding").Equals("chunked") || webResponse.ContentLength > 0)
Hope this helps.
If you were using our C# service discovery example on Github, these will be updated shortly.
0
Answers
-
Hi @elektron
When making a request to the discovery URL you have to provide an Authorisation bearer token as demonstrated in our examples:
Java - websocket-api/MarketPriceRdpGwServiceDiscovery.java at master · Refinitiv/websocket-api (github.com)
Also, please refer to the Websocket RTO Quickstart - QuickStart | Refinitiv Developers for details on how to run the Python example
0 -
Hello @elektron
Could you please try the Service Discovery request with the following curl command? Please replace the <access_token> with your Access Token from the RDP Auth Token service (Note: please notice a space between text 'Bearer' and the access token).
curl --location --request GET 'https://api.refinitiv.com/streaming/pricing/v1/'; \
--header 'Accept: application/json' \
--header 'Authorization: Bearer <access token>'If you still encounter errors from the curl command, I suggest you contact the RDP support team via https://my.refinitiv.com/ website to help you verify the issue.
Please select the "Pricing - Refinitiv Data Platform" product on the my.refinitiv.com website, and give them the following information:
- The machine-id that encounters the problem
- The URL endpoint ('https://api.refinitiv.com/streaming/pricing/v1/')
- The error response message
- Date and time that encounters the problem
Hope this helps.
0 -
Hi @elektron
If you are using the github example, please note that as well as the above fix, there was another minor fix applied to the code - so recommend you download the latest version.
0 -
Thank you for infromation.
Yes, we are using C # and will try to fix it with the provided examples.
0 -
Hello!
Which product do I need to subscribe to at https://my.refinitiv.com/ in order to receive similar notifications?
0 -
@elektron - sorry don't understand your question - what kind of notifications do you require?Hi
Thanks.
0 -
Hi @umer.nalla, i want to receive notifications about changes in API web socket.
i've alredy subscribed to "Refinitiv Real-Time - Optimized" alerts. What alerts do I need to subscribe to? please tell me is that enough?
0 -
Hi @elektron
You could watch the GitHub repo for Websocket API to be made aware of any changes.
We hope to add a 'Watch API' functionality on the Developer Portal - but I don't have a timescale for this.
0
Categories
- All Categories
- 3 Polls
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 34 Data Model Discovery
- 687 Datastream
- 1.4K DSS
- 623 Eikon COM
- 5.2K Eikon Data APIs
- 10 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- 3 Trading API
- 2.9K Elektron
- 1.4K EMA
- 255 ETA
- 557 WebSocket API
- 38 FX Venues
- 14 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 23 Messenger Bot
- 3 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 60 Open Calais
- 276 Open PermID
- 44 Entity Search
- 2 Org ID
- 1 PAM
- PAM - Logging
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 22 RDMS
- 1.9K Refinitiv Data Platform
- 687 Refinitiv Data Platform Libraries
- 4 LSEG Due Diligence
- LSEG Due Diligence Portal API
- 4 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.2K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 12 World-Check Customer Risk Screener
- 1K World-Check One
- 46 World-Check One Zero Footprint
- 45 Side by Side Integration API
- 2 Test Space
- 3 Thomson One Smart
- 10 TR Knowledge Graph
- 151 Transactions
- 143 REDI API
- 1.8K TREP APIs
- 4 CAT
- 27 DACS Station
- 121 Open DACS
- 1.1K RFA
- 105 UPA
- 194 TREP Infrastructure
- 229 TRKD
- 918 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 91 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 48 中文论坛