Validate token feature
Closed this issue · 3 comments
Xemdo commented
Tell us about your feature request
Right now twitch token
has the ability to revoke, such as:
twitch token --client-id CLIENT_ID --revoke OAUTH_TOKEN
In a similar fashion, we should have a way to validate tokens:
twitch token --validate OAUTH_TOKEN
This would return information similar to Barry's Token Checker, which uses the /oauth2/validate endpoint.
Disclaimer
- I agree
GStefanowich commented
Is the CLI capable of doing ||
s with if a CLI parameter is present?
Could you theoretically do
twitch token --validate OAUTH_TOKEN --revoke
twitch token --validate --revoke OAUTH_TOKEN
without having to do
twitch token --validate OAUTH_TOKEN --revoke OAUTH_TOKEN
Xemdo commented
Ideally, you would validate or revoke. Doing both doesn't provide much since revoke requires a valid token, and will fail if the token is not valid.