Records via the API

Reading and writing REDCap records, and files within a record.

redcap_read()

Read records from a REDCap project in subsets, and stacks them together before returning a dataset

redcap_read_oneshot()

Read/Export records from a REDCap project

redcap_read_oneshot_eav()

Read/Export records from a REDCap project --still in development

redcap_read_eav_oneshot()

Read/Export records from a REDCap project, returned as eav

redcap_write()

Write/Import records to a REDCap project

redcap_write_oneshot()

Write/Import records to a REDCap project

redcap_delete()

Delete records in a REDCap project

redcap_report()

Read/Export records that populate a REDCap report

redcap_file_download_oneshot()

Download a file from a REDCap project record

redcap_file_upload_oneshot()

Upload a file into to a REDCap project record

Additional API Methods

Accessing other information from the REDCap project or server.

redcap_arm_export()

Export Arms

redcap_dag_read()

Read data access groups from a REDCap project

redcap_event_instruments()

Enumerate the instruments to event mappings

redcap_event_read()

Export Events

redcap_instrument_download()

Download REDCap Instruments

redcap_instruments()

Enumerate the instruments (forms)

redcap_log_read()

Get the logging of a project.

redcap_metadata_coltypes()

Suggests a col_type for each field in a REDCap project

redcap_metadata_read()

Export the metadata of a REDCap project

redcap_metadata_write()

Import metadata of a REDCap project

redcap_next_free_record_name()

Determine free available record ID

redcap_project_info_read()

Export project information.

redcap_survey_link_export_oneshot()

Download a file from a REDCap project record

redcap_users_export()

List authorized users

redcap_variables()

Enumerate the exported variables

redcap_version()

Determine version of REDCap instance

Internals

Functions and classes used by the methods above.

REDCapR-package REDCapR

R utilities for interacting with a REDCap data system https://www.project-redcap.org/

redcap_project

A Reference Class to make later calls to REDCap more convenient

to_api_array()

Convert a vector to the array format expected by the REDCap API

kernel_api()

REDCapR internal function for calling the REDCap API

Security

Responsibly store and retrieve a user’s project-specific token.

retrieve_credential_local() retrieve_credential_mssql() create_credential_local()

Read a token and other credentials from a (non-REDCap) database or file

Utilities

Functions to help the methods above.

collapse_vector()

Collapse a vector of values into a single string when necessary

constant()

Collection of REDCap-specific constants

create_batch_glossary()

Creates a dataset that help batching long-running read and writes

regex_named_captures() checkbox_choices()

Manipulate and interpret the metadata of a REDCap project

redcap_column_sanitize()

Sanitize to adhere to REDCap character encoding requirements

replace_nas_with_explicit()

Create explicit factor level for missing values

sanitize_token()

Validate and sanitize the user's REDCap token

validate_for_write() validate_data_frame_inherits() validate_no_logical() validate_field_names() validate_record_id_name() validate_repeat_instance() validate_uniqueness()

Inspect a dataset to anticipate problems before writing to a REDCap project

Soft Deprecated

Functions that have been renamed and will be removed in future REDCapR versions.

redcap_file_download_oneshot()

Download a file from a REDCap project record

redcap_file_upload_oneshot()

Upload a file into to a REDCap project record

redcap_instrument_download()

Download REDCap Instruments