How do i change the
"Condition": {
"MessageTimeStampIn": "GmtUtc", to UTC+9 , and how do i show the timestamp to be Tokyo/Osaka?
Posting the answer from the case for future reference:
All currency pairs and currency update in GMT/UTC only. In Tick History Report, the output settings can only be set to “Gmt/Utc” or “LocalExchangeTime”. For currencies / forex, local “Exchange” time is also Gmt/Utc as source is from Refinitv.
Hi @jolin.majmin
If the question about LSEG Tick History, According to the documentation, MessageTimeStampIn can accept either GmtUtc or LocalExchangeTime.
Hope this helps.
Best regards,
Haykaz
I understand this, however I am not certain what the LocalExhangeTime would be for each currency pair? for some I would guess JPY would be TOKYO, but what if I chose AUDZAR? what is the LocalExchageTime for this pair, for example? So, it would be better for me, if i could choose my timezone reference.
I don't think it is possible to add timezone reference, my colleagues (@Jirapongse I would appreciate your input here) may correct if I am wrong. As for the LocalExhangeTime for different pairs, I would advice raising a content query via my.refinitiv.com.
I have tried
"MessageTimeStampIn": "LocalExchangeTime", ....the Date-Time column is still of the form, ISO 8601, "YYYY-MM-DDTHH:MM:SS.sssZ". I do not see any difference to using GmtUtc. Please advise as to how i can obtain UTC+9 for example, WITHOUT changing the timestamp after the extraction
Hi @jolin.majmin ,
Please add "DateRangeTimeZone": "Local Exchange Time Zone" into your conditions, that should return in local time zone:
"conditions": { "MessageTimeStampIn": "LocalExchangeTime", "DateRangeTimeZone": "Local Exchange Time Zone", "ReportDateRangeType": "Range" }
I have tried this. Unfortunately, it yields no different values to using "GmtUtc"
Please also add "Trade - Exchange Time" to the ContentFieldNames and would you mind posting your code here, so I investigate further in case of further questions?
Bes regards,
requestUrl='https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/ExtractRaw';requestHeaders={"Prefer":"respond-async","Content-Type":"application/json","Authorization": "token " + token}requestBody={ "ExtractionRequest": { "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.TickHistoryIntradaySummariesExtractionRequest", "ContentFieldNames": ["Close Ask","Close Bid","High Ask","High Bid","Low Ask","Low Bid","No. Asks","No. Bids", "Open Ask","Open Bid", "Trade - Exchange Time"], "IdentifierList": { "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList", "InstrumentIdentifiers": [{"Identifier": ticker1,"IdentifierType": "Ric"}, #{"Identifier": ticker2,"IdentifierType": "Ric"} ], "UseUserPreferencesForValidationOptions": "false" }, "Condition": { "MessageTimeStampIn": "LocalExchangeTime", #"GmtUtc", "DateRangeTimeZone": "Local Exchange Time Zone", "ReportDateRangeType": "Range", "QueryStartDate":QueryStartDate , "QueryEndDate": QueryEndDate, "SummaryInterval": "OneMinute", "TimebarPersistence": "false", "DisplaySourceRIC": "true" } }}r2 = requests.post(requestUrl, json=requestBody,headers=requestHeaders)#Display the HTTP status of the response#Initial response status (after approximately 30 seconds wait) is usually 202status_code = r2.status_codeprint ("HTTP status of the response: " + str(status_code))if status_code == 200 : r2Json = json.loads(r2.text.encode('ascii', 'ignore')) jobId = r2Json["JobId"] print ('\njobId: ' + jobId + '\n') notes = r2Json["Notes"] print ('Extrraction notes:\n' + notes[0])
if i add "Trade - Exchange Time" as suggested, there is an error. You suggestion does not work.
HTTP status of the response: 400
Thanks for sharing the code, indeed if you are using TickHistoryIntradaySummariesExtractionRequest "Trade - Exchange Time" will not be available. I have checked the available fields and didn't seem to find an equivalent for it. I have created a content query (case id: 13483218) on your behalf and the team may better assist you with your question.