View source: R/docsUserRoleAssignmentMethods.R
userRoleAssignmentMethods | R Documentation |
These methods enable the user to export the user-role assignments, add assignments, or modify existing assignments.
exportUserRoleAssignments(rcon, ...)
importUserRoleAssignments(rcon, data, ...)
## S3 method for class 'redcapApiConnection'
exportUserRoleAssignments(
rcon,
...,
error_handling = getOption("redcap_error_handling"),
config = list(),
api_param = list()
)
## S3 method for class 'redcapApiConnection'
importUserRoleAssignments(
rcon,
data,
...,
error_handling = getOption("redcap_error_handling"),
config = list(),
api_param = list()
)
rcon |
A |
data |
|
... |
Arguments to pass to other methods |
error_handling |
|
config |
A named |
api_param |
A named |
exportUserRoleAssignments
returns a data frame with the columns:
username | Username of a user in the project. |
unique_role_name | The unique role name to which the user is assigned. |
data_access_group | The Data Access Group to which the user is assigned. |
importUserRoleAssignments
invisibly returns the number of user roles
assignments added or modified.
exportUserRoleAssignments()
: Export user-role assignments from a project.
importUserRoleAssignments()
: Import user-role assignments to a project.
exportUsers()
,
importUsers()
,
deleteUsers()
,
exportUserRoles()
,
importUserRoles()
,
deleteUserRoles()
## Not run:
unlockREDCap(connections = c(rcon = "project_alias"),
url = "your_redcap_url",
keyring = "API_KEYs",
envir = globalenv())
# Export user-role assignments
exportUserRoleAssignments(rcon)
# Import/modify a user-role assignment
NewData <- data.frame(username = "desired_user_name",
unique_role_name = "KN3430U")
importUserRolesAssignments(rcon,
data = NewData)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.