ustfd_request {ustfd} | R Documentation |
Retrieve Data From the U.S. Bureau Of the Fiscal Service API
Description
ustfd_request()
will execute queries against the Fiscal Data API. Queries
can generated using ustfd_query()
.
Usage
ustfd_request(
query,
user_agent = "http://github.com/groditi/ustfd",
process_response = ustfd_json_response,
...
)
Arguments
query |
list generated by one of the query generating functions |
user_agent |
string, optional |
process_response |
function, optional. processes the |
... |
further arguments will be passed to |
Value
a httr response object
See Also
Other ustfd_low_level:
ustfd_json_response()
,
ustfd_response_meta_object()
,
ustfd_response_payload()
,
ustfd_url()
Examples
## Not run:
library(ustfd)
query <- ustfd_query('v1/accounting/dts/dts_table_2', sort =c('-record_date'))
response <- ustfd_request(query)
payload_table <- ustfd_response_payload(response)
payload_meta <- ustfd_response_meta_object(response)
## End(Not run)
[Package ustfd version 0.4.4 Index]