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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
1 0 0 0

DSS RESTAPI throwing error

curl -X POST \
-H "Authorization: Token $token" \
-d '{ {"ExtractionRequest": {"@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.IntradayPricingExtractionRequest",\
"ContentFieldNames": [ "RIC", "Ask Price", "Bid Price", "Trade Date" ],"IdentifierList": {"@odata.type": \
"#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList", "InstrumentIdentifiers": \
[{ "Identifier": "FN3015TB1=FINR", "IdentifierType": "Ric" },{ "Identifier": "FN3020TB1=FINR", "IdentifierType": "Ric" }},\
"Condition": { "ScalableCurrency": true }}}' \
https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/Extract

Response:

% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 599 100 80 100 519 254 1648 --:--:-- --:--:-- --:--:-- 1926{"error":{"message":"Value cannot be null.\r\nParameterName=ExtractionRequest"}}


#technologydss-rest-api
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.

Hi @subray.shetty ,

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?

If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,
AHS

@subray.shetty

Hi,

Please be informed that a reply has been verified as correct in answering the question, and marked as such.

Thanks,

AHS

1 Answer

· Write an Answer
Upvote
Accepted
22.1k 59 14 21

The request as shown in your question is incorrect and not a proper JSON message - its missing a few brackets.

You will also need to include headers to indicate what type of payload it is. Please use Postman or Python examples to try out the API samples.

curl -X POST -H "Authorization: Token ***" -H "Content-Type: application/json" -d @requestBody.txt "https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/Extract"
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.