drive_fields | R Documentation |
You may be able to improve the performance of your API calls by
requesting only the metadata that you actually need. This function is
primarily for internal use and is currently focused on the Files resource. Note
that high-level googledrive functions assume that the name
, id
, and
kind
fields are included, at a bare minimum. Assuming that resource = "files"
(the default), input provided via fields
is checked for validity
against the known field names and the validated fields are returned. To see
a tibble containing all possible fields and a short description of each,
call drive_fields(expose())
.
prep_fields()
prepares fields for inclusion as query
parameters.
drive_fields(fields = NULL, resource = "files")
prep_fields(fields, resource = "files")
fields |
Character vector of field names. If |
resource |
Character, naming the API resource of interest. Currently, only the Files resource is anticipated. |
drive_fields()
: Character vector of field names. prep_fields()
: a
string.
Improve performance, in the Drive API documentation.
# get a tibble of all fields for the Files resource + indicator of defaults
drive_fields(expose())
# invalid fields are removed and throw warning
drive_fields(c("name", "parents", "ownedByMe", "pancakes!"))
# prepare fields for query
prep_fields(c("name", "parents", "kind"))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.