get_all_documents: Get Document Metadata for Given Documents or Docket

View source: R/get-all-documents.R

get_all_documentsR Documentation

Get Document Metadata for Given Documents or Docket

Description

Get Document Metadata for Given Documents or Docket

Usage

get_all_documents(endpoint = "document", ..., quiet = TRUE, key = NULL)

Arguments

endpoint

string that represents which endpoint you want the url to be based on. The options are "document" and "docket". Note that this will be the endpoint your parameters will be applied to (e.g. the posted date of the document versus the posted date of the docket). The default value is "document."

...

arguments passed to construct_document_url() or construct_docket_url(), whichever function corresponds to the endpoint provided.

quiet

logical; FALSE if you want to see the progress of the function as it acquires detailed information for each comment.

key

the API key passed in the function call; this may be NULL if the user has chosen to set up the key as an environmental variable instead with the function set_datagov_key. You can use "DEMO_KEY" for a very limited number of calls if needed.

Value

a data frame

Examples

## Not run: 
# get all document data for documents associated with docket FDA-2009-N-0501
result <- get_all_documents(docketId = "FDA-2009-N-0501")
# get all document data for document IDs
result <- get_all_documents(documentId = c(
  "FDA-2012-S-1144-0322",
  "NHTSA-2008-0060-0827", "DOT-OST-2018-0206-0008", "CMS-2018-0104-0001"
))

## End(Not run)

q-w-a/regulationsgov documentation built on May 3, 2022, 8:23 p.m.