Set (and reset) global httr configuration.
Arguments
- config
Settings as generated by
add_headers(),set_cookies()orauthenticate().- override
if
TRUE, ignore existing settings, ifFALSE, combine new config with old.
See also
Other ways to set configuration:
config(),
with_config()
Examples
GET("http://google.com")
#> Response [http://www.google.com/]
#> Date: 2026-02-13 21:41
#> Status: 200
#> Content-Type: text/html; charset=ISO-8859-1
#> Size: 17.8 kB
#> <!doctype html><html itemscope="" itemtype="http://schema.org/WebPag...
#> var g=this||self;function k(){return window.google&&window.google.kO...
#> function r(a,b,d,c,h){var e="";b.search("&ei=")===-1&&(e="&ei="+n(c)...
#> document.documentElement.addEventListener("submit",function(b){var a...
#> </style><style>body,td,a,p,.h{font-family:sans-serif}body{margin:0;o...
#> var g=this||self;var k,l=(k=g.mei)!=null?k:1,m,p=(m=g.diel)!=null?m:...
#> "&bver="+b(w.bv);w.dpf&&(c+="&dpf="+b(w.dpf));var f=a.lineNumber;f!=...
#> if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document....
#> }
#> })();</script><div id="mngb"><div id=gbar><nobr><b class=gb1>Search<...
#> ...
set_config(verbose())
GET("http://google.com")
#> Response [http://www.google.com/]
#> Date: 2026-02-13 21:41
#> Status: 200
#> Content-Type: text/html; charset=ISO-8859-1
#> Size: 17.8 kB
#> <!doctype html><html itemscope="" itemtype="http://schema.org/WebPag...
#> var g=this||self;function k(){return window.google&&window.google.kO...
#> function r(a,b,d,c,h){var e="";b.search("&ei=")===-1&&(e="&ei="+n(c)...
#> document.documentElement.addEventListener("submit",function(b){var a...
#> </style><style>body,td,a,p,.h{font-family:sans-serif}body{margin:0;o...
#> var g=this||self;var k,l=(k=g.mei)!=null?k:1,m,p=(m=g.diel)!=null?m:...
#> "&bver="+b(w.bv);w.dpf&&(c+="&dpf="+b(w.dpf));var f=a.lineNumber;f!=...
#> if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document....
#> }
#> })();</script><div id="mngb"><div id=gbar><nobr><b class=gb1>Search<...
#> ...
reset_config()
GET("http://google.com")
#> Response [http://www.google.com/]
#> Date: 2026-02-13 21:41
#> Status: 200
#> Content-Type: text/html; charset=ISO-8859-1
#> Size: 17.8 kB
#> <!doctype html><html itemscope="" itemtype="http://schema.org/WebPag...
#> var g=this||self;function k(){return window.google&&window.google.kO...
#> function r(a,b,d,c,h){var e="";b.search("&ei=")===-1&&(e="&ei="+n(c)...
#> document.documentElement.addEventListener("submit",function(b){var a...
#> </style><style>body,td,a,p,.h{font-family:sans-serif}body{margin:0;o...
#> var g=this||self;var k,l=(k=g.mei)!=null?k:1,m,p=(m=g.diel)!=null?m:...
#> "&bver="+b(w.bv);w.dpf&&(c+="&dpf="+b(w.dpf));var f=a.lineNumber;f!=...
#> if (!iesg){document.f&&document.f.q.focus();document.gbqf&&document....
#> }
#> })();</script><div id="mngb"><div id=gbar><nobr><b class=gb1>Search<...
#> ...