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

Pass auth_url param through to oauth_flow_device #331

Merged
merged 4 commits into from
Oct 8, 2023

Conversation

taerwin
Copy link
Contributor

@taerwin taerwin commented Oct 6, 2023

auth_url is not passed through to oauth_device_flow see issue #120

@hadley
Copy link
Member

hadley commented Oct 7, 2023

Could you please explain why you want this?

@taerwin
Copy link
Contributor Author

taerwin commented Oct 8, 2023

There is currently no way to set auth_url in req_oath_device() directly or via auth_params. Ticket suggests it should be able to be set as follows:

req %>%
httr2::req_oauth_device(
client = cl,
auth_url = "http://xyz/oauth2/authorize",
cache_disk = TRUE
) %>%
httr2::req_perform()

This patch adds auth_url as a param and also sets this param to be passed through to oauth_flow_device

@hadley
Copy link
Member

hadley commented Oct 8, 2023

Ah, got it.

hadley added 3 commits October 8, 2023 13:27
* Add example
* Extract out repeated example GitHub client
* Fix `oauth_flow_abort()` buglet
@hadley hadley merged commit 696e4fe into r-lib:main Oct 8, 2023
12 checks passed
@taerwin taerwin deleted the device_auth_url branch October 10, 2023 23:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants