Hello,
can you please help us to update this code snippet we used to play with rdp but not working anymore with rd.
if (response.status["http_status_code"] == 202):
#getting the status of the calculation ('not started', 'running', 'succeeded')
status_url = "https://api.refinitiv.com" + response.headers["location"]
status_endpoint = rdp.Endpoint(session, status_url)
status = "not_started"
while(status != "succeeded" and status != "failed"):
status_response = status_endpoint.send_request(method = rdp.Endpoint.RequestMethod.GET)
status = status_response.data.raw["status"]
time.sleep(1)
#when the status changes to 'succeeded', use the 'resourcelocation' url to retrieve the response
response_url = "https://api.refinitiv.com" + status_response.data.raw["resourceLocation"]
print(response_url)
respone_endpoint = rdp.Endpoint(session, response_url)
response = respone_endpoint.send_request(method = rdp.Endpoint.RequestMethod.GET)
print(response.data.raw)
import pandas as pd
headers_name = [h['name'] for h in response.data.raw['headers']]
df = pd.DataFrame(data=response.data.raw['data'], columns=headers_name)
df