File View Link for another application

Hello,

This is a very general question and I know that there might be a billion ways to answer this but here I go. I have an application that uploads files to an FTP server, and I would like to create a next cloud link that when the user clicks, takes them to the file view (whether its onlyoffice or an image ect).

The nc is connected to the ftp by the external storages plugin. I was wondering if there was an api endpoint that would allow me to simply pull the url directly. This will be used on a SOHO application running locally.

Any help would be appreciated as I am new to developing for nc.

Thanks in advance