Downloads attachment files from a specified field, returning them as either in-memory blobs or saved files.
Usage
air_read_attachments(
base_id,
table,
field,
record_ids = NULL,
dest = c("blob", "file"),
dir = NULL,
parallel = NULL,
.token = NULL
)Arguments
- base_id
Base ID (e.g.,
"appXXXXXX"). IfNULL, uses the session default set byair_set_base()or theAIRTABLE_BASE_IDenvironment variable.- table
Table name or ID.
- field
Name of the attachment field.
- record_ids
Optional character vector of specific record IDs to fetch. If
NULL, fetches all records.- dest
Either
"blob"(return raw content as list-column) or"file"(save to disk).- dir
Directory to save files to (required if
dest = "file").- parallel
Logical or
NULL. IfTRUE, attachment downloads usehttr2::req_perform_parallel()(up to 5 concurrent). IfNULL, uses optionairtable2.parallelor env varAIRTABLE2_PARALLEL(defaultTRUE).- .token
Personal access token (resolved via
air_token()ifNULL).