Set curl options.

Generally you should only need to use this function to set CURL options directly if there isn't already a helpful wrapper function, like set_cookies, add_headers or authenticate.

named Curl options.

To use this function effectively requires some knowledge of CURL, and CURL options. A complete set of options can be found at

Within R, the options have slightly different names: the initial CURLOPT_ is removed, all underscores are converted to periods and the option is given in lower case. Thus "CURLOPT_SSLENGINE_DEFAULT" becomes "sslengine.default". See listCurlOptions for a complete list of the R name equivalents.

Unlike Curl (and RCurl), all configuration options are per request, not per handle.

See Also

set_config to set global config defaults, and with_config to temporarily run code with set options.

Other config: accept_json, accept_xml, add_headers; authenticate; set_cookies; timeout; use_proxy; user_agent; verbose

Other ways to set configuration: reset_config, set_config; with_config

  • config
Documentation reproduced from package httr, version 0.3, License: MIT + file LICENSE

Community examples

Looks like there are no examples yet.