You could just install the Azure PowerShell module and then authenticate to the tenant you'd like:
Install Azure PowerShell on Windows
Then with the Graph Explorer, just copy the commands you are trying to call with.
If this is helpful please accept answer.