Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to CLI to re-generate oauth token #1579

Open
NeariX67 opened this issue Jul 26, 2024 · 7 comments
Open

Add option to CLI to re-generate oauth token #1579

NeariX67 opened this issue Jul 26, 2024 · 7 comments
Labels
bug Something isn't working

Comments

@NeariX67
Copy link

Describe the bug
My requests fail using the CLI, but are fine running in VSCode. I'm asuming this is because the CLI has an old OAuth Token with wrong permissions. It's easy to generate a new token in the UI (which is not shared with CLI) but there is no option to do the equivalent with the CLI.

To Reproduce

  • Create a request and configure oauth with insufficient permissions (scope)
  • Run request in CLI
  • Re-configure Oauth with sufficient permissions (scope)
  • Re-Run request in CLI (still fail because same token)

Expected behavior
Re-run token generation on configuration change or before collection is run

Platform:

  • OS: Windows 11
  • vscode version: 1.19.1
  • node version: 19.4.0
  • extension version: v2.24.13
  • cli version: 1.16.2

Are you using the free version/paid version/trial:
Trial

@NeariX67 NeariX67 added the bug Something isn't working label Jul 26, 2024
@rangav
Copy link
Collaborator

rangav commented Jul 26, 2024

@NeariX67

please generate token from OAuth tab first in the UI.

then run in CLI it will work.

@NeariX67
Copy link
Author

Auth code does not change in CLI when generating a new token using the UI.

@rangav
Copy link
Collaborator

rangav commented Jul 26, 2024

It will use the same code until expiry and generate a new token after expiration

@NeariX67
Copy link
Author

i don't want to wait until expiry.

@rangav
Copy link
Collaborator

rangav commented Jul 26, 2024

what Grant Type are you using?
Screenshot 2024-07-26 at 18 48 06

@NeariX67
Copy link
Author

Client Credentials

@rangav
Copy link
Collaborator

rangav commented Jul 26, 2024

currently not possible to generate new token on every request, only generate new on expiry

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants