All we really have to emulate is the following:
az account get-access-token -o json --resource https://management.core.windows.net/
We can probably set PATHEXT to go, or ensure we are the first az
on the PATH to prevent collisions with the actual Azure CLI