Importing PowerShell modules

I have a couple of workflows that I would love to be able to pull extra data from Entra ID and other Azure resources. Instead of re-inventing the wheel I would like to just be able to use pre-built modules, e.g. Microsoft.Online.SharePoint.PowerShell and Microsoft.Entra to name two. Two items I want to pull would be additional user information, e.g. registered devices for authentication methods, and yank files from SharePoint (because Teams is just email and SharePoint with different paint on).

I thought about using Python but then I run into the same issue as I would need to use the MSAL library, which has to be imported as well.

I found a couple of discussion from 2021 about this and the solution 4 years ago was to either bring up a windows server for SSH or use CredSSP.

After 4 years, I really hope that there a better solution than what others were doing.

Thanks!
Sean