A 'safe' wrapper for redcapAPI::redcapConnection(). Will return diagnostic error codes in case incorrect URL or token are provided instead of failing outright.
REDCap API Security
It is good practice to ensure that SSL certs are validated when utilizing the REDCap API. To ensure this happens, set the CURLOPT_SSL_VERIFYPEER' option to TRUE to avoid potential man in the middle attacks.
The redcapAPI package utilizes the httr package to perform operations using the REDCap API. Configuration options can be passed directly to httr via the config option in the redcapAPI::redcapConnection function. Here, we set 'ssl_verifypeer = 1L' to ensure cert checking is enabled.