If I understand correctly, your code example is simulating a service receiving a request with a token, and that is why you can't use application credentials directly.
It should be possible to instantiate a client in python directly with a token and endpoint, though I haven't tried it.
Bo,
If I understand correctly, your code example is simulating a service receiving a request with a token, and that is why you can't use application credentials directly.
It should be possible to instantiate a client in python directly with a token and endpoint, though I haven't tried it.