openspecimen/rest/ng/collection-protocol-registrations/{cprId}/consents
Use this resource API to save participant consent responses. Use HTTP PUT method to call invoke this API by passing the below details in JSON format.
...
Given below is an example request/response exchanged to update participant consents:
URL | http[s]://<host>:<port>/openspecimen/rest/ng/collection-protocol-registrations/48878/consents |
Method | PUT |
Request | application/json |
json |
Code Block |
---|
| {
"consentSignatureDate": "2022-04-20",
"witness": {
"id": 1,
"emailAddress:": "admin@krishagni.com"
},
"comments": "Consent to collect specimens",
"responses": [
{
"code": "CS1",
"response": "Yes"
},
{
"code": "CS2",
"response": "No"
}
]
} |
|
Response |
Code Block |
---|
{
"cpShortTitle": "Lung Cancer",
"ppid": "PPID_KW_001",
"consentSignatureDate": 1650412800000,
"witness": {
"id": 1,
"type": "SUPER",
"firstName": "Admin",
"lastName": "Admin",
"loginName": "admin@krishagni.com",
"domain": "openspecimen",
"emailAddress": "admin@krishagni.com",
"instituteId": 1,
"instituteName": "A1 - For Demo Users",
"admin": true,
"instituteAdmin": false,
"phoneNumber": "",
"manageForms": true,
"manageWfs": true,
"cpCount": 0,
"activityStatus": "Locked"
},
"comments": "Consent to collect specimens",
"responses": [
{
"code": "CS1",
"response": "Yes"
},
{
"code": "CS2",
"response": "No"
}
]
}
|
|
...