question

Upvotes
Accepted
6 3 7 11

How can I set the start end end date when requesting data via HistoricalPricingSummaries?

Setting the WithStart() and/or WithEnd() parameter will always cause an error. ("The request parameter validation failed. start is invalid format.")

For example modifying DotNet_Example 2.0.0:

response = HistoricalPricing.GetSummaries(new HistoricalPricingSummaries.Params().Universe(ric)

.WithInterval(HistoricalPricingSummaries.Interval.P1D)
.WithStart(new DateTime(1973, 4, 13))
.WithCount(2));

rdp-apiapirefinitiv-data-platform.netrefinitiv-data-platform-libraries
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.

1 Answer

Upvotes
Accepted
13.7k 61 39 63

Hi @martin.grunwald,

You must specify that the date is UTC, i.e.

new DateTime(1973,4,13,0,0,0,DateTimeKind.UTC)

You also have the option of passing in a simple string into the date specifiers, i.e.

.WithStart("1973-04-13")
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.