Learn R Programming

crunch (version 1.30.4)

handleAPIresponse: Do the right thing with the HTTP response

Description

Do the right thing with the HTTP response

Usage

handleAPIresponse(response, special.statuses = list(), progress.handler = NULL)

Value

The full HTTP response object, just the content, or any other status-specific action

Arguments

response

an httr response object

special.statuses

an optional named list of functions by status code.

progress.handler

an optional function to handle errors reported by a progress result. Default NULL prints the string message; other functions required to handle non-string messages in progress responses.