set_app_key handshake

Hello, after having set an app key, I am trying the python eikon package.
python 3.8.13
eikon 1.1.16
httpx 0.24.1 (putting it there as I saw that this package was of importance).
I am working behind a proxy, windows environment.
I tried to relog on / log off my eikon session and tried with a new app key but nothing happened.
I can access https://emea1.apps.cp.thomsonreuters.com/ via my web browser.
Code:
import eikon as ek
app_key = "my_app_key"
ek.set_app_key(api_key)
2023-06-12 13:11:36,517 P[26600] [MainThread 39472] Reset a Desktop session with new app_key
2023-06-12 13:11:36,561 P[26600] [MainThread 39472] Send GET request to http://127.0.0.1:9060/api/status to detect API Proxy...
2023-06-12 13:11:36,597 P[26600] [MainThread 39472] Request to http://127.0.0.1:9060/api/status
headers = {'x-tr-applicationid': 'my_app_key'}
params = None
2023-06-12 13:11:36,640 P[26600] [MainThread 39472] Checking proxy url http://127.0.0.1:9060/api/status response : 200 - {"statusCode":"ST_PROXY_READY","version":"3.3.11-eikon4"}
2023-06-12 13:11:36,673 P[26600] [MainThread 39472] Port 9060 was retrieved from .portInUse file
2023-06-12 13:11:36,706 P[26600] [MainThread 39472] Try to handshake on url http://127.0.0.1:9060/api/handshake...
2023-06-12 13:11:36,738 P[26600] [MainThread 39472] Request to http://127.0.0.1:9060/api/handshake
headers = {'Content-Type': 'application/json', 'x-tr-applicationid': 'my_app_key'}
params = None
2023-06-12 13:11:51,784 P[26600] [MainThread 39472] Error on handshake url http://127.0.0.1:9060/api/handshake : ReadTimeout('')
2023-06-12 13:11:51,821 P[26600] [MainThread 39472] Error on handshake url http://127.0.0.1:9060/api/handshake : ReadTimeout('')
2023-06-12 13:11:51,854 P[26600] [MainThread 39472] Port number was not identified, cannot send any request
2023-06-12 13:11:51,883 P[26600] [MainThread 39472] Init a Desktop session with new app_key
When I look at the URL http://127.0.0.1:9060/api/handshake it returns a json with code: 404
Best Answer
-
Thank you for reaching out to us.
You can test the request by running the following command in PowerShell.
(Invoke-WebRequest -Method POST -Body (@{"AppKey"="<app key>";"AppScope"="trapi";"ApiVersion"="1";"LibraryName"="RDP Python Library";"LibraryVersion"="1.1.7"}|ConvertTo-Json) -Uri http://127.0.0.1:9060/api/handshake -ContentType application/json)
Change "<app key>" to your application key.
The response looks like this:
0
Answers
-
Thank you very much for your prompt answer!
So the code returns a code error 500 that seems to indicate I don't have access.
PS G:\> (Invoke-WebRequest -Method POST -Body (@{"AppKey"="my_app_key";"AppScope"="trapi";"ApiVersion"="1";"LibraryName"="RDP Python Library";"LibraryVersion"="1.1.7"}|ConvertTo-Json) -Uri http://127.0.0.1:9060/api/handshake -ContentType application/json)
Invoke-WebRequest : {"code":500,"message":"connect ETIMEDOUT 159.220.1.19:443","statusMessage":"Internal Server Error"}
At line:1 char:2
+ (Invoke-WebRequest -Method POST -Body (@{"AppKey"="my_app_key ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebException
+ FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand0
Categories
- All Categories
- 6 AHS
- 36 Alpha
- 166 App Studio
- 6 Block Chain
- 4 Bot Platform
- 18 Connected Risk APIs
- 47 Data Fusion
- 33 Data Model Discovery
- 682 Datastream
- 1.4K DSS
- 613 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
- 248 ETA
- 552 WebSocket API
- 37 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
- 275 Open PermID
- 44 Entity Search
- 2 Org ID
- 1 PAM
- PAM - Logging
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 22 RDMS
- 1.8K Refinitiv Data Platform
- 625 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
- 26 DACS Station
- 121 Open DACS
- 1.1K RFA
- 104 UPA
- 191 TREP Infrastructure
- 228 TRKD
- 915 TRTH
- 5 Velocity Analytics
- 9 Wealth Management Web Services
- 83 Workspace SDK
- 11 Element Framework
- 5 Grid
- 18 World-Check Data File
- 1 Yield Book Analytics
- 46 中文论坛