Open jentz opened 3 months ago
Another option for dealing with the output is to support something similar to kubectl
--output [ json | go-template ]
The json format could be the default while go-template would allow the user to select which piece of the response to show and we could also add support for decoding tokens and such.
See the Go template package and the kubectl output formatting options.
The result of the flows is a response from the Token endpoint. The JSON response is the default output but it would be useful to enable additional options to simply output one of the token values, like the refresh token or the access token. The idea is to reduce the requirement of having additional tools on the host computer.
A possible implementation could be to support: --output [access_token, refresh_token, id_token] : determine whether to restrict output to a particular token --outout-format [raw, json] : determine how the token should be printed: raw or as decoded JSON