pp_query {ProPublicaR} | R Documentation |
Execute a query against the ProPublica API
Description
This function is primarily meant to be used by other functions in the package, but is made available in case a "raw query" is required.
Usage
pp_query(
query,
API = c("campaign-finance", "congress"),
version = "v1",
page = 1,
myAPI_Key
)
Arguments
query |
The query to be executed |
API |
Which API are you accessing |
version |
API version. Currently v1. |
page |
Results come in batches of 20. The page parameter specifies which one to retrieve. |
myAPI_Key |
API key from Propublica To use the congress API, you must sign up for an API key. |
Value
a list object with the return values.
Examples
## Not run:
pp_query('115/bills/hr21.json', API = 'congress', version='v1')
pp_query('2018/races/MI/house/11.json', API='campaign-finance',version='v1')
## End(Not run)
[Package ProPublicaR version 1.1.4 Index]