I have created a 1st Logic app : that allows a user to upload a .mp4 media file into a folder on OneDrive, and the logic app checks to see if there is new file on that OneDrive folder. If there is new file, it will trigger the logic app and Index the video onto https://www.videoindexer.ai/.
2nd - Logic App : After the video is indexed to https://www.videoindexer.ai/ , I want the user to pick language(s) from the custom web page that I have created, for caption translation. Once the user choose the language(s) they click on "submit" and this will send the data(languages) to my 2nd logic app URL end-point, and trigger my second logic app(shown below) and get the captions based on the user's selection of languages. Finally, it will then output those caption files on to a OneDrive folder.
Right now, the caption file names are in format of : videoID_language.vtt (Example: e0b3483dd1_en-US.vtt). The problem with this format is that, lets say we have multiple videos, the user will find it hard to match which caption file belongs to which video. So that is why I am looking to add video title name, so that they know which caption file are for which video.
My question is: How can I also add video Name to the file as well? So lets say I have video tile such as "AzureFunction". I want my VTT file name to look like this AzureFunction_e0b3483dd1_en-US.vtt
What I tried to do was change the file name query
From this:
concat(triggerOutputs()['body']['videoId'],'',item(),'.vtt')
TO this:
concat(triggerOutputs()['body']['name']['videoId'],'',item(),'.vtt')
But it gives an error because, it does't know the 'name'. How to include the video name as part of my title?
Here is the 2nd logic app workflow, that I am using to create the file: