Skip to content

Conversation

@cristiand391
Copy link
Member

@cristiand391 cristiand391 commented Mar 31, 2025

What does this PR do?

Adds a --no-auth flag for api request rest to skip adding the Authorization: Bearer <token> header to requests.

Use cases:

revoke oauth tokens:

https://help.salesforce.com/s/articleView?id=xcloud.remoteaccess_revoke_token.htm&type=5

Get the token from sf org display and:

sf api request rest services/oauth2/revoke --body "@token.txt" --header 'Content-Type: application/x-www-form-urlencoded' --include -X POST --no-auth

other oauth endpoints

when playing with other oauth endpoints (requesting the initial access token, no need to auth)

What issues does this PR fix or reference?

@W-18293634@

@cristiand391 cristiand391 requested a review from a team as a code owner March 31, 2025 13:23
Co-authored-by: Juliet Shackell <[email protected]>
@cristiand391 cristiand391 added the bug Something isn't working label Apr 16, 2025
@git2gus
Copy link

git2gus bot commented Apr 16, 2025

This issue has been linked to a new work item: W-18293634

@cristiand391 cristiand391 changed the title feat: add no-auth flag feat: add no-auth flag W-18293634 Apr 16, 2025
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

Successfully merging this pull request may close these issues.

3 participants