'How to get data from drives linked in a SharePoint list?

I'm wondering if there is a way to get the driveID from a drive that is linked in a SharePoint list using hyperlinks. I've looked around for similar questions/ ways to achieve this but have had no luck.

I've tried using the URL on MSGraph: '/sites/companyName.sharepoint.com:/mainSite/subsite/folder' but this doesn't work.

I've seen a product that does this but I'm unsure how. Any help is really appreciated.

Image shows an example of the SharePoint list



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source