From 09bf0a09b760678ee6c26d99014641d21feb1863 Mon Sep 17 00:00:00 2001 From: Will Beasley Date: Mon, 12 Aug 2024 13:20:48 -0500 Subject: [PATCH] improve doc for survey-link-export written by @jrob95 for #526 --- NEWS.md | 1 + man/redcap_survey_link_export_oneshot.Rd | 19 +++++++++++-------- 2 files changed, 12 insertions(+), 8 deletions(-) diff --git a/NEWS.md b/NEWS.md index dd43ec7e..cf3b6bc6 100644 --- a/NEWS.md +++ b/NEWS.md @@ -152,6 +152,7 @@ The package has been stable for years and should be reflected in the major versi * Accepts more than one `config_option` element. (Proposed by @BastienRance, #307) * Fixed calculation of `success` value returned by `redcap_read()` and `redcap_write()` when the parameter `continue_on_error` is true. (Bug found by @llrs, #317) +* [`redcap_survey_link_export_oneshot()`](https://ouhscbbmc.github.io/REDCapR/reference/redcap_survey_link_export_oneshot.html) documentation corrected & improved (@jrob95, #526) Version 0.11.0 (Released 2020-04-20) ========================================================== diff --git a/man/redcap_survey_link_export_oneshot.Rd b/man/redcap_survey_link_export_oneshot.Rd index b4d36f66..17eef526 100644 --- a/man/redcap_survey_link_export_oneshot.Rd +++ b/man/redcap_survey_link_export_oneshot.Rd @@ -2,7 +2,7 @@ % Please edit documentation in R/redcap-survey-link-export-oneshot.R \name{redcap_survey_link_export_oneshot} \alias{redcap_survey_link_export_oneshot} -\title{Download a file from a REDCap project record} +\title{Get survey link from REDCap} \usage{ redcap_survey_link_export_oneshot( redcap_uri, @@ -25,12 +25,14 @@ Required.} \item{token}{The user-specific string that serves as the password for a project. Required.} -\item{record}{The record ID where the file is to be imported. Required} +\item{record}{The record ID associated with the +survey link. Required} \item{instrument}{The name of the instrument associated with the survey link. Required} -\item{event}{The name of the event where the file is saved in REDCap. +\item{event}{The name of the event associated with the +survey link. Optional} \item{verbose}{A boolean value indicating if \code{message}s should be printed @@ -47,6 +49,7 @@ should be \code{NULL} for most institutions. Optional.} \value{ Currently, a list is returned with the following elements, \itemize{ +\item \code{survey_link}: a character string containing the URL for the survey. \item \code{success}: A boolean value indicating if the operation was apparently successful. \item \code{status_code}: The @@ -54,18 +57,18 @@ successful. of the operation. \item \code{outcome_message}: A human readable string indicating the operation's outcome. -\item \code{records_affected_count}: The number of records inserted or updated. -\item \code{affected_ids}: The subject IDs of the inserted or updated records. +\item \code{instrument}: The instrument associated with the survey link. +\item \code{records_affected_count}: The number of records associated with +the survey link. +\item \code{affected_ids}: The subject IDs associated with the survey link. \item \code{elapsed_seconds}: The duration of the function. \item \code{raw_text}: If an operation is NOT successful, the text returned by REDCap. If an operation is successful, the \code{raw_text} is returned as an empty string to save RAM. -\item \code{file_name}: The name of the file persisted to disk. This is useful if -the name stored in REDCap is used (which is the default). } } \description{ -This function uses REDCap's API to download a file. +This function uses REDCap's API to get the link for a survey. } \details{ Currently, the function doesn't modify any variable types to conform to