View source: R/api_to_dataframe.R
api_to_dataframe | R Documentation |
Given a url submit the request and return the results as a dataframe. If the response is paginated, the functions is called recursively until all of the pages have been loaded ($next is null). A maximum of 20 requests are made. If the maximum number of pages is reached, the function returns the data and issues a warning that there may be additional data and that the filters should be refined and multiple requests made and then combined to ensure that all of the records selected by the filter are returned. It is generally considered best practice to only request the data needed for your particular analysis by applying appropriate filters to the request than fetch everything and filtering on the client (e.g. R).
api_to_dataframe(
url,
data = NULL,
page = 0,
recursive = TRUE,
request_type = "GET",
request_body = NULL
)
url |
string |
data |
dataframe |
page |
number |
recursive |
boolean |
request_type |
string - http request type "GET"" or "POST" |
request_body |
list, dataframe, or character string to be sent to the server as the body of the POST request. Not used in GET requests. |
dataframe
Adam Cottrill adam.cottrill@ontario.ca
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.