Is there a way to play back a media objects for a specified period using nodejs actions sdk ?
For example in the code below in the code below the file is for 1 minutes and 42 seconds. But suppose I had a file that was 60 minutes long, I want to be able to pass a parameter to the object that will specify the duration of the play back, which would be less than the total duration .
function yourFunctionHandler(agent) {
let conv = agent.conv();
conv.ask(new SimpleResponse("Here is a funky Jazz tune"));
conv.ask(new Suggestions(['suggestion 1', 'suggestion 2']));
conv.close(new MediaObject({
name: 'Jazz in Paris',
url: 'https://storage.googleapis.com/automotive-media/Jazz_In_Paris.mp3',
description: 'A funky Jazz tune',
icon: new Image({
url: 'https://storage.googleapis.com/automotive-media/album_art.jpg',
alt: 'Media icon',
}),
})); }