Skip to content

httr 0.6

Compare
Choose a tag to compare
@hadley hadley released this 14 Dec 13:51

New features

  • New write_stream() allows you to process the response from a server as
    a stream of raw vectors (#143).
  • Suport for Google OAuth2 service accounts. (#119, thanks to help from @siddharthab).
  • VERB() allows to you use custom http verbs (#169).
  • New handle_reset() to allow you to reset the handle if you get the error
    "easy handle already used in multi handle" (#112).
  • Uses R6 instead of RC. This makes it possible to extend the OAuth
    classes from outside of httr (#113).
  • Now only set capath on Windows - system defaults on linux and mac ox
    seem to be adequate (and in some cases better). I've added a couple of tests
    to ensure that this continues to work in the future.

Minor improvements and bug fixes

  • vignette("api-packages") gains more detailed instructions on
    setting environment variables, thanks to @jennybc.
  • Add revoke_all() to revoke all stored tokens (if possible) (#77).
  • Fix for OAuth 2 process when using options(httr_oob_default = TRUE)
    (#126, @WillemPaling).
  • New brew_dr() checks for common problems. Currently checks if your libCurl
    uses NSS. This is unlikely to work so it gives you some advice on how to
    fix the problem (thanks to @eddelbuettel for debugging this problem).
  • Content-Type set to title case to avoid errors in servers which do not
    correctly implement case insensitivity in header names. (#142, #146) thanks
    to Håkon Malmedal (@hmalmedal) and Jim Hester (@jimhester).
  • Correctly parse http status when it only contains two components (#162).
  • Correctly parse http headers when field name is followed by any amount
    (including none) of white space.
  • Default "Accepts" header set to
    application/json, text/xml, application/xml, */*: this should slightly
    increase the likelihood of getting xml back. application/xml is correctly
    converted to text before being parsed to XML::xmlParse() (#160).
  • Make it again possible to override the content type set up by POST()
    when sending data (#140).
  • New safe_callback() function operator that makes R functions safe for
    use as RCurl callbacks (#144).
  • Added support for passing oauth1 tokens in URL instead of the headers
    (#145, @Bogstag).
  • Default to out-of-band credential exchange when httpuv isn't installed.
    (#168)

Deprecated and deleted functions

  • new_token() has been removed - this was always an internal function
    so you should never have been using it. If you were, switch to creating
    the tokens directly.
  • Deprecate guess_media(), and instead use mime::guess_type() (#148).