We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
This might belong in httr2 itself, but try it out here.
Add req_user_agent_append() (exact name/usage TBD), to append info to the default httr2 UA.
req_user_agent_append()
This is not the exact code to use, but it's the adjacent example I'm playing around with:
.httr2_ua <- function() { # Recreate the default httr2 string. versions <- c( httr2 = as.character(utils::packageVersion("httr2")), `r-curl` = as.character(utils::packageVersion("curl")), libcurl = curl::curl_version()$version ) paste0(names(versions), "/", versions, collapse = " ") } .req_ua <- function(req) { httr2_string <- .httr2_ua() me <- "Jon Harmon" url <- "https://wapir.io" email <- "[email protected]" string <- glue::glue( "{httr2_string} ({me}; {url}; mailto:{email})" ) httr2::req_user_agent(req, string = string) }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
This might belong in httr2 itself, but try it out here.
Add
req_user_agent_append()
(exact name/usage TBD), to append info to the default httr2 UA.This is not the exact code to use, but it's the adjacent example I'm playing around with:
The text was updated successfully, but these errors were encountered: