For a deeper look into our DataScope Select SOAP API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
3 1 2 4

TickHistoryTimeAndSalesExtractionRequest" - Cannot parse request

Can you please tell me what's wrong with this message. I get a parsing error when I submit this.

{
"@odata.type":"#ThomsonReuters.Dss.Api.Extractions.ReportTemplates.TickHistoryTimeAndSalesExtractionRequest",
"ContentFieldNames":
[
"Correction - Ask Price",
"Correction - Bid Price"
],
"IdentifierList":{"@odata.type":"#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",
"InstrumentIdentifiers":[{"Identifier":"PSN.L","IdentifierType":"Ric"}],
"ValidationOptions":{"AllowOpenAccessInstruments":true,"AllowHistoricalInstruments":true},
"UseUserPreferencesForValidationOptions":true},
"Condition":{
"MessageTimeStampIn":"GmtUtc",
"ApplyCorrectionsAndCancellations":true,
"ReportDateRangeType":"Delta",
"QueryStartDate":"2018-01-29T00:00:00.000Z",
"QueryEndDate":"2018-01-29T00:01:00.000Z",
"Preview":"Content",
"ExtractBy":"Entity",
"DisplaySourceRIC":true}
}


dss-rest-apidatascope-selectdss
icon clock
10 |1500

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

1 Answer

Upvotes
Accepted
426 2 4 4

Hi @william.a.maguire

There are two errors in the request body:

  1. "ValidationOptions" and "UseUserPreferencesForValidationOptions" cannot not be used in the same time. Remove the later one should work.
  2. If "QueryStartDate" and QueryStopDate" are set, the ReportDateRangeTypeshould be "Range", not "Delta". If you must use "delta" as the range type then don't use QueryStartDate and QueryStoDate, use "DatesAgo" parameter instead.

Here is THE MODIFIED request body I tested and worked. Please note I used onDemand extraction instead of report template extraction as in your original request :

{ 
"ExtractionRequest": {
	"@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.TickHistoryTimeAndSalesExtractionRequest",
	"ContentFieldNames": [
		"Correction - Ask Price",
		"Correction - Bid Price" ],
	"IdentifierList":{
		"@odata.type":"#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",
	"InstrumentIdentifiers":[{
		"Identifier":"PSN.L","IdentifierType":"Ric"
	}],
	"ValidationOptions":{
		"AllowOpenAccessInstruments":true,
		"AllowHistoricalInstruments":true}
	},
	"Condition":{
		"MessageTimeStampIn":"GmtUtc",
		"ApplyCorrectionsAndCancellations":true,
		"ReportDateRangeType":"Range",
		"QueryStartDate":"2018-01-29T00:00:00.000Z",
		"QueryEndDate":"2018-01-29T00:01:00.000Z",
		"Preview":"Content",
		"ExtractBy":"Entity",
		"DisplaySourceRIC":true
	}
    }
}
icon clock
10 |1500

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

Click below to post an Idea Post Idea