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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
5 1 1 4

API issue - response has no data although client is getting 200 OK

I'm trying to download data for EURUSD, but I get no data my query are:

requestUrl = 'https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/ExtractRaw' requestBody = {  "ExtractionRequest": {    "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.TickHistoryTimeAndSalesExtractionRequest",    "ContentFieldNames": [      "Trade - Price",      "Trade - Volume",      "Trade - Exchange Time"    ],    "IdentifierList": {      "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",      "InstrumentIdentifiers": [        { "Identifier": "EUR=", "IdentifierType": "Ric" }      ]    },    "Condition": {      "MessageTimeStampIn": "GmtUtc",      "ApplyCorrectionsAndCancellations": False,      "ReportDateRangeType": "Range",      "QueryStartDate": "2015-09-29T00:00:00.000Z",      "QueryEndDate": "2015-09-29T12:00:00.000Z",      "DisplaySourceRIC": True    }  } }



after 200 at Location a do the get at:



Notes : ['Extraction Services Version 15.2.42847 (ee8959b2766d), Built Oct 19 2021 09:36:41\nUser ID: 9030218\nExtraction ID: 2000000330478217\nCorrelation ID: CiD/9030218/0x0000000000000000/REST API/EXT.2000000330478217\nSchedule: 0x07c9ecb299fd5056 (ID = 0x0000000000000000)\nInput List (1 items):  (ID = 0x07c9ecb299fd5056) Created: 17/11/2021 11:53:27 Last Modified: 17/11/2021 11:53:27\nReport Template (3 fields): _OnD_0x07c9ecb299fd5056 (ID = 0x07c9ecb29a0d5056) Created: 17/11/2021 11:51:52 Last Modified: 17/11/2021 11:51:52\nSchedule dispatched via message queue (0x07c9ecb299fd5056), Data source identifier (8C1E23A5258F473DB07CF29C114A4D54)\nSchedule Time: 17/11/2021 11:51:54\nProcessing started at 17/11/2021 11:51:54\nProcessing completed successfully at 17/11/2021 11:53:28\nExtraction finished at 17/11/2021 10:53:28 UTC, with servers: tm03n01, TRTH (84.844 secs)\nInstrument <RIC,EUR=> expanded to 1 RIC: EUR=.\nTotal instruments after instrument expansion = 1\n\nManifest: #RIC,Domain,Start,End,Status,Count\nManifest: EUR=,Market Price,,,Inactive,0\n']


requestUrl = f"https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/RawExtractionResults('{job_id}')/$value"

with job_id = JobId


but a get no row just header

#RIC,Alias Underlying RIC,Domain,Date-Time,GMT Offset,Type,Price,Volume,Exch Time




same thing when I do:


requestUrl = 'https://selectapi.datascope.refinitiv.com/RestApi/v1/Extractions/ExtractRaw' requestBody = {  "ExtractionRequest": {    "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.TickHistoryMarketDepthExtractionRequest",    "ContentFieldNames": [      "Ask Price",      "Ask Size",      "Bid Price",      "Bid Size",              "Number of Buyers",      "Number of Sellers",    ],    "IdentifierList": {      "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",      "InstrumentIdentifiers": [        { "Identifier": "EUR=", "IdentifierType": "Ric" }      ]    },    "Condition": {      "View": "NormalizedLL2",      "NumberOfLevels": 10,      "MessageTimeStampIn": "GmtUtc",      "ReportDateRangeType": "Range",      "QueryStartDate": "2016-09-29T09:00:00.000Z",      "QueryEndDate": "2016-09-29T12:00:00.000Z",      "DisplaySourceRIC": True    }  } }


what I'm doing wrong?

dss-rest-apiextraction
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

Upvote
Accepted
16.7k 42 12 19

Hello @f.cipriani ,

Your content field names are invalid for FX instruments - trade fields are not applicable to fx. Please use the DSS website or contact the Refinitiv helpdesk at my.refinitiv.com for relevant fields that are of interest to you. The following query extracts quotes data for your time range:

{
  "ExtractionRequest": {
    "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.TickHistoryTimeAndSalesExtractionRequest",
    "ContentFieldNames": ["Quote - Bid Price", "Quote - Ask Price", "Quote - Exchange Time"],
    "IdentifierList": {
      "@odata.type": "#DataScope.Select.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",
      "InstrumentIdentifiers": [{
          "Identifier": "EUR=",
          "IdentifierType": "Ric"
        }
      ]
    },
    "Condition": {
      "MessageTimeStampIn": "GmtUtc",
      "ApplyCorrectionsAndCancellations": False,
      "ReportDateRangeType": "Range",
      "QueryStartDate": "2015-09-29T00:00:00.000Z",
      "QueryEndDate": "2015-09-29T12:00:00.000Z",
      "DisplaySourceRIC": True
    }
  }
}
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.