LSEG Data Library for TypeScript

About News

The News content object allows you to retrieve Headlines and Story data stored on the Delivery Platform.

Example of usage

The following example demonstrates how to retrieve the last five news headlines from Google:

const definitionStory = News.Story.Definition('urn:newsml:reuters.com:20190926:nNRA9sv8uz:1');
const definitionHeadlines = News.Headlines.Definition('LSEG');

const responseStory = await definitionStory.getData();
console.log(responseStory.data.story.title);
console.log(responseStory.data.story.content);

const responseHeadlines = await definitionHeadlines.getData();
console.log(responseHeadlines.data.table);
33 words (0:10 mins)