Use m365 CLI! this is genious for all kinds of stuff with sharepoint, Teams etc. from PAD! 🙂
1. install nodejs https://nodejs.org/en/
2. Install CLI via cmd
npm install -g @PnP/cli-microsoft365
3. Run command
set-ExecutionPolicy RemoteSigned -Scope CurrentUser
And then you are set to go!
Example:
Use a powershell action in PAD with command
m365 login --authType password --userName %Username% --password %Password%; m365 spo listitem list --title "%SharepointListName%" --webUrl https://%Tenant%.sharepoint.com/sites/%site% --fields "%All the columns you want from your list, seperated with comma%" --output json; m365 logout
Or wait a little longer... Microsoft has announced future connections to sharepoint from PAD. 😉