I use the restclient to get the JWT token from powerserver web api since that is how the examples show how to do it.
From what i can tell however, all the GetJWTToken does is post to the url and put the response body in the 'ref string token' and deflate it if it is in gzip format. You still have to use jsonparser to get the token: GetItemString("/access_token")
is there any reason to use the restclient for this other than the auto-deflate? If the ExtractorObject supported in memory extraction rather than requiring output to files, then the http client would be the same?
It's weird that the examples for the JWT token processing use restclient. I don't think that the built in JWT service uses compression on the body, so there is zero reason to use it for powerserver JWT tokens.