question

Upvotes
Accepted
23 0 0 1

timebar persistence

I did ask this question earlier, however the response received did not solve the problem.

in the code below, when i use, "TimebarPersistence": "false", i still receive carried over values (i would not expect to see quotes on Saturday and Sunday). note: ticker1 is defined as "JPY="

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"],
    "IdentifierList": {
      "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",  
      "InstrumentIdentifiers": [{"Identifier": ticker1,"IdentifierType": "Ric"},
                                #{"Identifier": ticker2,"IdentifierType": "Ric"}
                               ],
      "UseUserPreferencesForValidationOptions": "false"
    },    
    "Condition": {
      "MessageTimeStampIn": "GmtUtc",
      "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 202
status_code = r2.status_code
print ("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 ('Extraction notes:\n' + notes[0])
#technologydatascope-selecttimestamp
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
80.3k 259 52 75

@jolin.majmin

Thank you for reaching out to us.

I checked with the following request.

{
  "ExtractionRequest": {
    "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.TickHistoryIntradaySummariesExtractionRequest",
    "ContentFieldNames": [
      "Close Ask",
      "Close Bid",
      "High",
      "High Ask",
      "High Bid",
      "Last",
      "Low",
      "Low Ask",
      "Low Bid",
      "No. Asks",
      "No. Bids",
      "No. Trades",
      "Open",
      "Open Ask",
      "Open Bid",
      "Volume"
    ],
    "IdentifierList": {
      "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",  
      "InstrumentIdentifiers": [{
        "Identifier": "JPY=",
        "IdentifierType": "Ric"
      }],
      "ValidationOptions": null,
      "UseUserPreferencesForValidationOptions": false
    },
    "Condition": {
      "MessageTimeStampIn": "GmtUtc",
      "ReportDateRangeType": "Range",
      "QueryStartDate": "2024-04-04T00:00:00.000Z",
      "QueryEndDate": "2024-04-10T00:00:00.000Z",
      "SummaryInterval": "OneMinute",
      "TimebarPersistence": false,
      "DisplaySourceRIC": true
    }
  }
}

The output is:

1713338670137.png

To verify the retrieved content, please contact the Tick History support team directly via MyRefinitiv. The support can check the request message and verify the retrieved content.


1713338670137.png (46.7 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
23 0 0 1

Thank you, I see ""ValidationOptions": null, was added...what does this field do?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

@jolin.majmin

The request is used in Postman. It could be None in Python. This is a property to validate instruments.

Upvotes
23 0 0 1

Also, note "ValidationOptions": "null", results in

HTTP status of the response: 400
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.