Method | HTTP request | Description ------------- | ------------- | ------------- all | GET /activity | Get the set of all activities. allByParticipant | GET /participant/{participant_id}/activity | Get all activities for a participant. allByResearcher | GET /researcher/{researcher_id}/activity | Get all activities for a researcher. allByStudy | GET /study/{study_id}/activity | Get all activities in a study. create | POST /study/{study_id}/activity | Create a new Activity under the given Study. delete | DELETE /activity/{activity_id} | Delete an Activity. update | PUT /activity/{activity_id} | Update an Activity's settings. view | GET /activity/{activity_id} | Get a single activity, by identifier.
array[object] all()
Get the set of all activities.
Get the set of all activities.
library(LAMP)
#Get the set of all activities.
result <- LAMP.Activity$all()
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- transform | character| | [optional]
array[object]
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
array[object] allByParticipant(participant.id)
Get all activities for a participant.
Get the set of all activities available to a participant, by participant identifier.
library(LAMP)
var.participant.id <- 'participant.id_example' # character |
#Get all activities for a participant.
result <- LAMP.Activity$allByParticipant(var.participant.id)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- participant.id | character| | transform | character| | [optional]
array[object]
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
array[object] allByResearcher(researcher.id)
Get all activities for a researcher.
Get the set of all activities available to participants of any study conducted by a researcher, by researcher identifier.
library(LAMP)
var.researcher.id <- 'researcher.id_example' # character |
#Get all activities for a researcher.
result <- LAMP.Activity$allByResearcher(var.researcher.id)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- researcher.id | character| | transform | character| | [optional]
array[object]
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
array[object] allByStudy(study.id)
Get all activities in a study.
Get the set of all activities available to participants of a single study, by study identifier.
library(LAMP)
var.study.id <- 'study.id_example' # character |
#Get all activities in a study.
result <- LAMP.Activity$allByStudy(var.study.id)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- study.id | character| | transform | character| | [optional]
array[object]
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
character create(study.id, activity)
Create a new Activity under the given Study.
Create a new Activity under the given Study.
library(LAMP)
var.study.id <- 'study.id_example' # character |
var.activity <- Activity$new("id_example", "spec_example", "name_example", DurationIntervalLegacy$new("repeat_type_example", 123, list(123)), 123) # Activity |
#Create a new Activity under the given Study.
result <- LAMP.Activity$create(var.study.id, var.activity)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- study.id | character| | activity | Activity| |
character
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
character delete(activity.id)
Delete an Activity.
Delete an Activity.
library(LAMP)
var.activity.id <- 'activity.id_example' # character |
#Delete an Activity.
result <- LAMP.Activity$delete(var.activity.id)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- activity.id | character| |
character
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
character update(activity.id, activity)
Update an Activity's settings.
Update an Activity's settings.
library(LAMP)
var.activity.id <- 'activity.id_example' # character |
var.activity <- Activity$new("id_example", "spec_example", "name_example", DurationIntervalLegacy$new("repeat_type_example", 123, list(123)), 123) # Activity |
#Update an Activity's settings.
result <- LAMP.Activity$update(var.activity.id, var.activity)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- activity.id | character| | activity | Activity| |
character
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
array[object] view(activity.id)
Get a single activity, by identifier.
Get a single activity, by identifier.
library(LAMP)
var.activity.id <- 'activity.id_example' # character |
#Get a single activity, by identifier.
result <- LAMP.Activity$view(var.activity.id)
dput(result)
Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- activity.id | character| | transform | character| | [optional]
array[object]
application/json
application/json
| Status code | Description | Response headers | |-------------|-------------|------------------| | 200 | 200 Success | - | | 400 | 400 Bad Request | - | | 403 | 403 Authorization Failed | - | | 404 | 404 Not Found | - | | 0 | 500 Internal Error | - |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.