air_get_records | R Documentation |
Downloads an Airtable table into a list of records
air_get_records(
table,
base_id,
api_key = Sys.getenv("AIRTABLE_KEY"),
query = list()
)
table |
name of the table (string) |
base_id |
id of the Airtable base where the table is located |
api_key |
API key for Airtable. By default it looks at the
|
query |
additional parameters for the airtable query like for example fields, view, pageSize, maxRecords, sort, filterByFormula, cellFormat, timeZone, userLocale, etc... See the airtable documentation for more details. |
Airtable API returns one page of records at a time. Each page will contain
pageSize
(a query parameter) records, which is 100 by default. Internally,
this function will automatically download all records until maxRecords
has
been reached.
a list with a results field containing all records
air_records_to_tibble
## Not run:
# Get all records for the table boats
air_get_records(table = "boats", base_id = "appjEVaN8kBNXAWak")
# Get records only in a specified view
air_get_records("boats", "appjEVaN8kBNXAWak",
query = list(view = "Boats with wrong registration")
)
# Get only the first 5 records
air_get_records("boats", "appjEVaN8kBNXAWak", query = list(maxRecords = 5))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.