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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
3 0 1 1

In DSS REST API, how can I specify the source for a CUSIP?

{
  "ExtractionRequest": {
    "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.TimeSeriesExtractionRequest",
    "ContentFieldNames": [
      "File Code",
      "RIC",
      "Close Price",
      "High Price",
      "Low Price",
      "Open Price",
      "Bid Price",
      "Ask Price",
      "Universal Close Price"
    ],
    "IdentifierList": {
      "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.InstrumentIdentifierList", 
      "InstrumentIdentifiers": [{
        "Identifier": "36729W509",
        "IdentifierType": "Cusip"
      }]
    },
    "Condition": {
      "LastPriceOnly": false,
      "StartDate": "2018-10-01T00:00:00.000Z",
      "EndDate": "2018-10-18T00:00:00.000Z"
    }
  }
}

When my identifier in REST API/JSON is a cusip, how do I specify a source? My settings are set to default to EJV for hybrids, but there are times when I need to override that. For example, in the attached, I need to default this cusip to the .PK source. What do I need to add to my code to make this work?

dss-rest-apidssdatascope-selectrest-apijson
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
13.7k 26 8 12

@Max.McDonough,

You can filter on a source, using this syntax when defining the identifier:

{ "Identifier": "36729W509", "IdentifierType": "Cusip", "Source": "OTC" }

But note that the source must be an exchange code, not a RIC extension. For this particular Cusip I discovered the source is OTC, not PNK.

Does this help ?

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
3 0 1 1

Thanks very much. So in this case, the API field name is "Source" - is there a full list of field names that I can reference for the future when building out these calls?

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.

@Max.McDonough, you are welcome.

When you define an instrument identifiers list, there are no other fields (apart from the user defined ones, but they do not serve to select of filter things, they are only tags you can add in case you have your own internal references).

The API reference tree describes all API call fields, it is very useful. To discover what parameters can be used in API calls, I suggest you also look at this section of the Programming without SDK tutorial.