Error: Max retries exceeded with url: /RestApi/v1/Authentication/RequestToken
I am getting the below error while trying to get token from DSS REST API, Even after using verify = False , I am getting the same error
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='hosted.datascopeapi.reuters.com', port=443): Max retries exceeded with url: /RestApi/v1/Authentication/RequestToken (Caused by NewConnectionError('<requests.packages.urllib3.connection.VerifiedHTTPSConnection object at 0x7f29d510f820>: Failed to establish a new connection: [Errno -2] Name or service not known'))
Code Used:
import requests, json
from requests import Request, Session
from collections import OrderedDict
urlGetToken = 'https://hosted.datascopeapi.reuters.com/RestApi/v1/Authentication/RequestToken'
header1 = {'Content-Type': 'application/json'}
tokenRequestBody = json.dumps({'Credentials': {'Password': '*****', 'Username': '*******'}})
response = requests.post(urlGetToken, tokenRequestBody, headers = header1, verify=False)
statusCode = response.status_code
if statusCode != 200:
print('ERROR: Get Token failed with HTTP status code: ' + str(statusCode))
else:
result = response.json()
token = result['value']
print(token)
Best Answer
-
Hello @prakash.balusamy,
Looks like you are not reaching DSS endpoint.
Usually, this happens when one is running from behind a firewall and requires to use a proxy to connect.
You may find this discussion to be relevant.
You may be using proxy settings in other applications connecting to external destinations from the same machine, allowing you to reuse the same settings. Or may need to find out the appropriate proxy settings from your organization's network admin/group.
Let us know how this suggestion works for you, if you are able to make progress.
0
Answers
-
@prakash.balusamy, are you able to reach the DSS website - https://hosted.datascopeapi.reuters.com/DatascopeApi in the browser. If yes, you can check the browser settings to see if it is configured to use proxy server.
0 -
Now I can able to get access the DSS URL, whom do I need to check to get permission for template as below?
10:19:30=== Exception occrued: Error: Status Code:403 Message:{"error":{"message":"No permission for template \"IntradayPricingReportTemplate\"."}}
0
Categories
- All Categories
- 6 AHS
- 39 Alpha
- 161 App Studio
- 4 Block Chain
- 4 Bot Platform
- 16 Connected Risk APIs
- 47 Data Fusion
- 30 Data Model Discovery
- 608 Datastream
- 1.3K DSS
- 577 Eikon COM
- 4.9K Eikon Data APIs
- 7 Electronic Trading
- Generic FIX
- 7 Local Bank Node API
- Trading API
- 2.7K Elektron
- 1.3K EMA
- 236 ETA
- 519 WebSocket API
- 33 FX Venues
- 10 FX Market Data
- 1 FX Post Trade
- 1 FX Trading - Matching
- 12 FX Trading – RFQ Maker
- 5 Intelligent Tagging
- 2 Legal One
- 20 Messenger Bot
- 2 Messenger Side by Side
- 9 ONESOURCE
- 7 Indirect Tax
- 59 Open Calais
- 264 Open PermID
- 39 Entity Search
- 2 Org ID
- PAM
- PAM - Logging
- 8.4K Private Comments
- 6 Product Insight
- Project Tracking
- ProView
- ProView Internal
- 20 RDMS
- 1.4K Refinitiv Data Platform
- 367 Refinitiv Data Platform Libraries
- 3 Refinitiv Due Diligence
- LSEG Due Diligence Portal API
- 3 Refinitiv Due Dilligence Centre
- Rose's Space
- 1.1K Screening
- 18 Qual-ID API
- 13 Screening Deployed
- 23 Screening Online
- 10 World-Check Customer Risk Screener
- 990 World-Check One
- 44 World-Check One Zero Footprint
- 45 Side by Side Integration API
- Test Space
- 3 Thomson One Smart
- 1.2K TR Internal
- Global Hackathon 2015
- 2 Specialists Who Code
- 10 TR Knowledge Graph
- 150 Transactions
- 142 REDI API
- 1.7K TREP APIs
- 4 CAT
- 21 DACS Station
- 117 Open DACS
- 1.1K RFA
- 103 UPA
- 172 TREP Infrastructure
- 224 TRKD
- 886 TRTH
- 5 Velocity Analytics
- 5 Wealth Management Web Services
- 60 Workspace SDK
- 9 Element Framework
- 5 Grid
- 13 World-Check Data File
- Yield Book Analytics
- 46 中文论坛