Skip to content

These functions implement the OAuth device flow, as defined by rfc8628. It's designed for devices that don't have access to a web browser (if you've ever authenticated an app on your TV, this is probably the flow you've used), but it also works well from within R.

This specification allows also some subspecifications:

Usage

oauth_flow_device(
  client,
  auth_url,
  pkce = FALSE,
  scope = NULL,
  auth_params = list(),
  token_params = list()
)

Arguments

client

An oauth_client().

auth_url

Authorization url; you'll need to discover this by reading the documentation.

pkce

Use "Proof Key for Code Exchange"? This adds an extra layer of security and should always be used if supported by the server.

scope

Scopes to be requested from the resource owner.

auth_params

List containing additional parameters passed to oauth_flow_auth_code_url()

token_params

List containing additional parameters passed to the token_url.

Value

An oauth_token.