req_oauth_solid_dpop: OAuth authentication with authorization code

View source: R/fetch.R

req_oauth_solid_dpopR Documentation

OAuth authentication with authorization code

Description

Uses oauth_flow_auth_code to generate an access token, used to authenticate the request with oauth_client_req_auth_dpop. The token is automatically cached to minimise the number of times login/consent is performed.

Usage

req_oauth_solid_dpop(req, client)

Arguments

req

httr2 req object

client

client object, as returned by solid_client_register_dyn or solid_client_register_clientid

Value

httr2 req object with authorization headers

Examples

## Not run: 
url <- "https://MY_PRIVATE_URL"
request(url) %>%
 req_oauth_solid_dpop(client) %>%
 req_perform() %>%
 resp_body_string()

## End(Not run)

josephguillaume/solidR documentation built on Jan. 3, 2023, 1:55 a.m.