Method | HTTP request | Description |
---|---|---|
all | GET /participant | Get the set of all participants. |
allByResearcher | GET /researcher/{researcher_id}/participant | Get the set of all participants under a single researcher. |
allByStudy | GET /study/{study_id}/participant | Get the set of all participants in a single study. |
create | POST /study/{study_id}/participant | Create a new Participant for the given Study. |
delete | DELETE /participant/{participant_id} | Delete a participant AND all owned data or event streams. |
update | PUT /participant/{participant_id} | Update a Participant's settings. |
view | GET /participant/{participant_id} | Get a single participant, by identifier. |
array[object] all()
Get the set of all participants.
Get the set of all participants.
import LAMP from 'lamp-core'
// Get the set of all participants.
const result = LAMP.Participant.all()
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
transform | string | [optional] |
array[object]
- Content-Type:
application/json
- Accept:
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 the set of all participants under a single researcher.
Get the set of all participants under a single researcher.
import LAMP from 'lamp-core'
let researcher_id = 'researcher_id_example' // string
// Get the set of all participants under a single researcher.
const result = LAMP.Participant.allByResearcher(researcher_id)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
researcher_id | string | ||
transform | string | [optional] |
array[object]
- Content-Type:
application/json
- Accept:
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 the set of all participants in a single study.
Get the set of all participants in a single study.
import LAMP from 'lamp-core'
let study_id = 'study_id_example' // string
// Get the set of all participants in a single study.
const result = LAMP.Participant.allByStudy(study_id)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
study_id | string | ||
transform | string | [optional] |
array[object]
- Content-Type:
application/json
- Accept:
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, participant)
Create a new Participant for the given Study.
Create a new Participant for the given Study.
import LAMP from 'lamp-core'
let study_id = 'study_id_example' // string
let participant = Participant.new("id_example", "study_code_example", "language_example", "theme_example", "emergency_contact_example", "helpline_example") // Participant
// Create a new Participant for the given Study.
const result = LAMP.Participant.create(study_id, participant)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
study_id | string | ||
participant | Participant |
string
- Content-Type:
application/json
- Accept:
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(participant_id)
Delete a participant AND all owned data or event streams.
Delete a participant AND all owned data or event streams.
import LAMP from 'lamp-core'
let participant_id = 'participant_id_example' // string
// Delete a participant AND all owned data or event streams.
const result = LAMP.Participant.delete(participant_id)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
participant_id | string |
string
- Content-Type:
application/json
- Accept:
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(participant_id, participant)
Update a Participant's settings.
Update a Participant's settings.
import LAMP from 'lamp-core'
let participant_id = 'participant_id_example' // string
let participant = Participant.new("id_example", "study_code_example", "language_example", "theme_example", "emergency_contact_example", "helpline_example") // Participant
// Update a Participant's settings.
const result = LAMP.Participant.update(participant_id, participant)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
participant_id | string | ||
participant | Participant |
string
- Content-Type:
application/json
- Accept:
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(participant_id)
Get a single participant, by identifier.
Get a single participant, by identifier.
import LAMP from 'lamp-core'
let participant_id = 'participant_id_example' // string
// Get a single participant, by identifier.
const result = LAMP.Participant.view(participant_id)
console.dir(result)
Name | Type | Description | Notes |
---|---|---|---|
participant_id | string | ||
transform | string | [optional] |
array[object]
- Content-Type:
application/json
- Accept:
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 | - |