Attached is an example. DSS REST On Demand Extraction does not takes a Report Template Id as param; thus the work around is:
DSS REST doesn't provide Java Wrapper library like the REST C# library. However, there are Java examples demonstrate how to use HTTP requests. You can download the DSS Rest Java Code examples from DSS Rest Download tag and modify the extraction fields in the LegalEntityDetailReport examples.
.
Thanks @steven.peng, but that also did not answer my question. Consider I have report template (lets say T&C with fields ISIN, CUSIP etc) ready on my DSS or created using Java in the past. Now this report I want use in ON DEMAND EXTRACTION for the any given instruments.
Hi All,
Does anyone have solution for my question, this request came from client. If no solution then I can update back client accordingly.
Thanks, Nityanand
This sample was added to the Java code sample package today (available under the downloads tab).
Note: to create a schedule you need the instrumentListId and reportTemplateId. Code referring to manually created instrument list & report template can retrieve their respective IDs by name. See separate response for the coding details.
Additional details to Susana's answer:
To create a schedule you need the instrumentListId and reportTemplateId. Code referring to manually created instrument list "myInstrumentListName" & report template "myReportTemplateName" can easily retrieve the respective IDs by name. See how to below (Java, HTTP REST and C#).
Java: see attached code (it is Susana's code with 2 added methods).
HTTP REST:
HTTP GET request by Instrument List name:
https://hosted.datascopeapi.reuters.com/RestApi/v1/Extractions/InstrumentListGetByName(ListName='myInstrumentListName')
HTTP response:
Location: https://hosted.datascopeapi.reuters.com/RestApi/v1/Extractions/InstrumentLists(''){ "@odata.context": "https://hosted.datascopeapi.reuters.com/RestApi/v1/$metadata#InstrumentLists/$entity", "ListId": "0x054a3d8c310afc5b", "Name": "myInstrumentListName", ... (etc.)}
HTTP GET request by Report Template name:
https://hosted.datascopeapi.reuters.com/RestApi/v1/Extractions/ReportTemplateGetByName(Name='myReportTemplateName')
{ "@odata.context": "https://hosted.datascopeapi.reuters.com/RestApi/v1/$metadata#ReportTemplates/ThomsonReuters.Dss.Api.Extractions.ReportTemplates.EndOfDayPricingReportTemplate/$entity", "@odata.type": "#ThomsonReuters.Dss.Api.Extractions.ReportTemplates.EndOfDayPricingReportTemplate", "ReportTemplateId": "0x054a3dc609e52703", ... (etc.)}<br>
C# using the .Net SDK:
myInstrumentList = extractionsContext.InstrumentListOperations.GetByName("myInstrumentListName");myInstrumentListId = myInstrumentList.ListId;myReportTemplate = extractionsContext.ReportTemplateOperations.GetByName("myReportTemplateName");myReportTemplateId = myReportTemplate.ReportTemplateId;<br>