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

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials

question

Upvotes
Accepted
45 4 14 12

Stocks "not found" in DSS API Terms and Conditions request answer

Hi

I am retrieving mostly bond data through the DSS REST API Terms and Conditions request, and it works fine. However, a user recently added 2 world known shares to the selection, the shares of the Swiss companies Nestlé and UBS. To my surprise, the answer to my request was "not found" for both shares.

However, the T&C request in the DSS GUI mentions that equities are supported. So why do I get no data for stocks ? Can it simply be a permission problem ?

Thanks for hints and help.

Regards

Bernard

dss-rest-apidssdatascope-selectequitiesterms-and-conditions
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.

18 Answers

Upvotes
Accepted
13.7k 26 8 12

@BTh,

using EJV as source for those 2 ISINs is therefore the cause of the issue you observe.

Those 2 instruments are not available on EJV. In the following screenshot (in the 3rd column "Source") you can see the available sources for ISIN CH0038863350:

EJV is not one of them. Using an invalid combination of ISIN and source will result in a "Not Found".


isin-instlist.png (76.9 KiB)
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
13.7k 26 8 12

@BTh,

I made a test, it worked. Here is the body of my request:

{
    "ExtractionRequest": {
        "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.TermsAndConditionsExtractionRequest",
        "ContentFieldNames": [
           "RIC", "CUSIP", "ISIN", "SEDOL", "Issuer OrgID", "Currency Code"
        ],
        "IdentifierList": {
            "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.InstrumentIdentifierList",
            "InstrumentIdentifiers": [
                { "Identifier": "UBSG.S", "IdentifierType": "Ric" },
                { "Identifier": "NESN.S", "IdentifierType": "Ric" }
            ]
        }
    }
}

And here is the response:

{
    "@odata.context": "https://hosted.datascopeapi.reuters.com/RestApi/v1/$metadata#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.ExtractionResult",
    "Contents": [
        {
            "IdentifierType": "Ric",
            "Identifier": "UBSG.S",
            "RIC": "UBSG.S",
            "CUSIP": null,
            "ISIN": "CH0244767585",
            "SEDOL": "BRJL176",
            "Issuer OrgID": "114375628",
            "Currency Code": "CHF"
        },
        {
            "IdentifierType": "Ric",
            "Identifier": "NESN.S",
            "RIC": "NESN.S",
            "CUSIP": null,
            "ISIN": "CH0038863350",
            "SEDOL": "7123870",
            "Issuer OrgID": "14219",
            "Currency Code": "CHF"
        }
    ],
    "Notes": [
        "Extraction Services Version 13.0.40472 (7104caacafda), Built Apr 10 2019 14:49:22\r\nUser has overridden estimates broker entitlements.\r\nProcessing started at 26042019 13:03:10.\r\nUser ID: 33314\r\nExtraction ID: 358771946\r\nSchedule: _OnD_0x069cbd44b68080ef (ID = 0x069cbd44bad080ef)\r\nInput List (2 items): _OnD_0x069cbd44b68080ef (ID = 069cbd44b74080ef) Created: 26042019 13:03:07 Last Modified: 26042019 13:03:07\r\nSchedule Time: 26042019 13:03:07\r\nReport Template (12 fields): _OnD_0x069cbd44b68080ef (ID = 0x069cbd44b6a080ef) Created: 26042019 13:03:07 Last Modified: 26042019 13:03:07\r\nProcessing completed successfully at 26042019 13:03:10, taking 0.308 Secs.\r\nExtraction finished at 26042019 11:03:10 UTC, with servers: x02A06, QSHC20 (0.1 secs), QSSHA1 (0.0 secs)\r\nUsage Summary for User 33314, Client 11122, Template Type Terms and Conditions\r\nBase Usage\r\n        Instrument                          Instrument                   Terms          Price\r\n  Count Type                                Subtype                      Source         Source\r\n------- ----------------------------------- ---------------------------- -------------- ----------------------------------------\r\n      2 Equities                                                         N/A            N/A\r\n-------\r\n      2 Total instruments charged.\r\n      0 Instruments with no reported data.\r\n=======\r\n      2 Instruments in the input list.\r\nWriting RIC maintenance report.\r\n",
        "Identifier,IdentType,Source,RIC,RecordDate,MaintType,OldValue,NewValue,Factor,FactorType\r\n"
    ]
}

Are you using the same RIC ?

If this answer does not help, could you please post the exact content of the request you are submitting, as well as the returned extraction notes ?

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
45 4 14 12

Hi Christiaan

Thanks for your superfast answer ! I'm not using the RIC, but the ISIN, like for all the bonds I get the data of. Here the 2 stocks ISIN:

  • CH0038863350 Nestlé share
  • CH0244767585 UBS share

If you can get data for them and I can't, surely it must mean that I don't have the permission for equities, no ?

I will run the thing in debug mode and get hold of the extraction notes.

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
45 4 14 12

Hi again Christiann

The request consisted of 254 instruments, of which 2 were the 2 stocks. The extractedRows.Count is also 254, but as 2 of the instruments are not found (the stocks), the note mentions only 252 rows. So basically the note just ignores the errors created by the 2 stocks.

Here is the note from the T&C extraction result:

Extraction Services Version 13.0.40472 (7104caacafda), Built Apr 10 2019 14:49:22

Processing started at 26/04/2019 13:44:17

User ID: 9020073

Extraction ID: 358780319

Schedule: _OnD_0x069cbb98af8080e5 (ID = 0x069cbb98b5b080e5

Input List (252 items): _OnD_0x069cbb98af8080e5 (ID = 069cbb98b18080e5) Created: 26/04/2019 13:44:15 Last Modified: 26/04/2019 13:44:16

Schedule Time: 26/04/2019 13:44:16

Report Template (54 fields): _OnD_0x069cbb98af8080e5 (ID = 0x069cbb98afb080e5) Created: 26/04/2019 13:44:15 Last Modified: 26/04/2019 13:44:15

(ISN,SGXZ64145782,EJV,SGML19104N=RRPS) is inactive

(ISN,XS0775280166,EJV,DEHLB3E7=RRPS) is inactive

Processing completed successfully at 26/04/2019 13:44:18, taking 0.983 Secs

Extraction finished at 26/04/2019 11:44:18 UTC, with servers: x07t02, QSHC12 (0.7 secs), QSSHA1 (0.0 secs

Usage Summary for User 9020073, Client 105054, Template Type Terms and Conditions

Base Usage

InstrumentInstrumentTermsPrice

Count TypeSubtypeSourceSource

------- ----------------------------------- ---------------------------- -------------- ----------------------------------------

13 Asset Backed SecuritiesN/AN/A

7 AgencyN/AN/A

1 CMO'sN/AN/A

140 CorporateInvestment GradeN/AN/A

2 CorporateInvestment GradeWertpapier FIN/A

43 Corporate

N/AN/A

28 Govt/Treasury/Central BankN/AN/A

1 Non-US MunisN/AN/A

17 Other Gov/SupraN/AN/A

252 Total instruments charged.

0 Instruments with no reported data.

252 Instruments in the input list.

And here the "data" that I generate for both stocks:

TRIdentifier TRIdentifierType TRFieldName TRFieldValue
CH0038863350 Isin ISIN ISIN not found
CH0244767585 Isin ISIN ISIN not found

"ISIN not found" is my translation of the extractedRows.row.Error content being equal to "Not found". I.e. I create an output row in my target table for these 2 stocks, although I get no data for them but just an error.

HTH

Bernard

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
13.7k 26 8 12

@BTh,

We can see from the notes that you get 252 instead of 254 not because of the 2 stocks, but because 2 instruments were inactive (SGML19104N=RRPS and DEHLB3E7=RRPS).

I made a test with the 2 ISINs, it found the instruments and delivered the data. Body of my request:

{ "ExtractionRequest": { "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.TermsAndConditionsExtractionRequest", "ContentFieldNames": [ "RIC", "CUSIP", "ISIN", "SEDOL", "Issuer OrgID", "Currency Code" ], "IdentifierList": { "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ExtractionRequests.InstrumentIdentifierList", "InstrumentIdentifiers": [ { "Identifier": "CH0244767585", "IdentifierType": "Isin" }, { "Identifier": "CH0038863350", "IdentifierType": "Isin" } ] } } }

May I suggest you try running the exact same request inside Postman ? To make this easy, after installing Postman, download the DSS Postman collection, install it (as well as its environment), set your account details in the environment variables, and run query Tuto-7b (after changing the instrument list contents). You might also want to change the field list. I suggest this to remove any outside influences from your code. If you are not familiar with Postman, this tutorial should get you started.

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
45 4 14 12

@Christiaan Meihsl

Strange enough, I have got all the fields with data for the 2 inactive instruments in the latest extraction results, so I don't think they are the reason for the 252 instead of 254.

Sorry, but I'm working in a sizable bank, I can neither download nor install any external software, such things are sternly blocked here :(

Would I discover the reason for my problem if I create a template using the DSS GUI and make a manual request for the data ?

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
13.7k 26 8 12

@BTh,

I fully understand, every company has its own restrictions, no worry :)

I just made a few more tests, by adding a typo to one of the ISINs, to ensure it is not found. If an instrument is not found:

1) It is not counted in the total found in the extraction notes under "Input List (N items)"

2) It generates an output record containing 3 items:

{ "IdentifierType": "Isin", "Identifier": "CH0038863350X", "Error": "Not found" }

I guess that is what your code is translating into:

TRIdentifier TRIdentifierType TRFieldName TRFieldValue
CH0038863350 Isin ISIN ISIN not found

I'm a bit at a loss here, I'm not familiar with the subtleties of DSS permissioning. I would like to test your request myself, just to be sure, assuming it would be possible for you to post the entire body of your request here.

I can also ask a colleague who knows the permissioning side of things better. He is on vacation but will be back next week.

Yes, I think it is a good idea if you make a manual request in the GUI, just for those 2 instruments, same template and field list. That should help tell us if this is a code issue or a permissioning issue.

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
45 4 14 12

@Christiaan Meihsl

I made a manual request over the DSS GUI, and I think I know where the problem is, although I don't understand why it is a problem: when I try to define my instrument list, I CANNOT select these 2 equities directly using their ISIN, it tells me it does NOT find them ! But if I use the search function, it finds them and uses their RIC, when adding them to my instrument list. And then that request, done as an immediate schedule, works...!

But I guess I cannot mix using ISIN and RIC as IdentifierType in the same instrument list, can I ?

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
45 4 14 12

@Christiaan Meihsl

Oh and even more interesting, just saw in the output csv file that it gives me, as requested, the ISIN... So there is a mistery here !

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
13.7k 26 8 12

@BTh,

When you manually add an instrument to an existing list, by default the GUI sets the preferred identifier to RIC. You can change that to ISIN, and that will deliver a list containing the input ISIN, and all exchanges where it is quoted:

Selecting one of those will add the ISIN to the list:

That makes me think: in your code using the API, when you try to add your ISINs, are you also specifying a source (i.e. exchange) ? If you are, and it is not a valid exchange for your ISIN, then the result will be not found.

And to answer your query: you can mix ISINs, Cusips and RICs inside an instrument list, that is no issue.


isin-instlist.png (76.9 KiB)
isin-instlist2.png (57.1 KiB)
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
45 4 14 12

@Christiaan Meihsl

>>That makes me think: in your code using the API, when you try to add your ISINs, are you also specifying a source (i.e. exchange) ?<<

No I don't, I used to, but I don't anymore. Here my code for the TermsAndConditions request:

            extractTandCondRequest = New TermsAndConditionsExtractionRequest With {.IdentifierList = instrumentList, .ContentFieldNames = fieldNames,

                .Condition = New TermsAndConditionsCondition With {

                    .IssuerAssetClassType = IssuerAssetClassType.AllSupportedAssets,

                    .ExcludeWarrants = False}}
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
13.7k 26 8 12

@BTh,

To help you further I really need to look at your code.

Would it be possible for you to post your code here, as well as any input files it might be using (in particular the instrument list that contains those 2 equities) ? Or, if you prefer, could you send it to me directly (christiaan.meihsl@refinitiv.com) ?

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
45 4 14 12

@Christiaan Meihsl

Sorry, I have to take back what I said earlier, I have to select a price source because of the same ISIN being given to 2 different securities, one being a bond, the other a preferred share, and using the price source eliminates the preferred share, which we don't want to select.

That must be the source of the problem with the equities, I guess ?

I discovered that while I was preparing the code for you to have. Do you still want to have the code ?

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
13.7k 26 8 12

@BTh, before you post your code: what sources do you have for the 2 equities that are not found ?

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
45 4 14 12

@Christiaan Meihsl

EJV is the source

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
45 4 14 12

@Christiaan Meihsl

YES ! I have changed my code to include the EJV source only for the relevant instruments which I can easily identify, and therefore not for the 2 equities, and I immediately get the equity data :)

Wow, am I glad we've found the reason ! I was starting to despair ! Thanks for your help and you putting me on the right track to spot the source of the problem :)

One big issue less :)

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
45 4 14 12

@Christiaan Meihsl

YES ! I have changed my code to include the EJV source only for the relevant instruments, and bingo, I get data for the 2 equities :)

Thanks a lot for your relentless search for the cause, and pointing me in the right direction to find the cause eventually :) That was great service, and I am sooo relieved to have solved that one ! Brilliant, thanks again.

Regards

Bernard

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
45 4 14 12

@Christiaan Meihsl

Ah, I could not see my "thanking" post, although I refreshed many times and even logged out and logged in again ! So I wrote it again, and now both are there...:(

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.

@BTh, glad the issue is solved at last, I was really curious to find out what it might be. And thank you for the "thanking" posts, appreciated :)