I tried connecting on both environments with visual studio (C#) and it works fine.
So I thought I missed some authentication code in power query...
Summary:
For sandbox -> Can't refresh
For primary -> Can't get an Azure AD token
Thank you for the response. I will post it in the Partner Center community.