Enables you to freeze/unfreeze and lock/unlock data at the subject, visit, eForm or question level.
You must include an authorization token in these requests which is generated from the /token call.
https://localhost/webapi/api/lockFreeze/[ActionName] [parameters]
POST
Parameter |
Type |
Description |
LFAction |
integer |
Type of lock/freeze operation to apply: Unfreeze = 0 Freeze = 1 Lock = 2 Unlock= 3 Rollback = 4 |
studyName |
string |
Study name |
siteId |
string |
Site code |
subjectId |
integer |
Subject ID (use 0 if specifying subject label instead) |
labelId |
string |
Subject label (use empty string if specifying subject ID instead) |
visitId |
string |
Visit code (omit if target is subject) |
vcycleNo |
integer |
Visit cycle if a repeating visit (omit if target is subject) |
eformId |
string |
eForm code (omit if target is subject or visit) |
fcycleNo |
integer |
eForm cycle if a repeating eForm (omit if target is subject or visit) |
questionId |
string |
Question code (omit if target is subject, visit or eForm) |
qcycleNo |
integer |
Question cycle if in a repeating question group (omit if target is subject, visit or eForm) |
Lock a subject:
POST /api/lockFreeze/subject?actionType=2&studyName=demostudy40&siteId=London&subjectId=1&labelId=test Host: localhost/webapi Content-Type: application/x-www-form-urlencoded Authorization: Bearer [Token] |
Freeze a visit:
POST /api/lockFreeze/visit?actionType=1&studyName=demostudy40&siteId=London&subjectId=34&labelId=test&visitId=1&vcycleNo=1 Host: localhost/webapi Content-Type: application/x-www-form-urlencoded Authorization: Bearer [Token] |
Unlock an eForm:
POST /api/LockFreeze/eForm?actionType=3&studyName=demostudy40&siteId=London&subjectId=34&labelId=test&visitId=1&vcycleNo=1&eformId=1&fcycleNo=2 Host: localhost/webapi Content-Type: application/x-www-form-urlencoded Authorization: Bearer [Token] |
Unfreeze a question:
POST /api/lockFreeze/question?actionType=0&studyName=demostudy40&siteId=London&subjectId=34&labelId=test&visitId=1&vcycleNo=1&eformId=1&fcycleNo=2&questionId=adc&qcycleNo=1 Host: localhost/webapi Content-Type: application/x-www-form-urlencoded Authorization: Bearer [Token] |
Value |
Description |
Success |
The operation was successful |
NoSubjectLock |
The subject is currently open for editing in DE |
InvalidOperation |
The operation was invalid, e.g. trying to Lock an object which is already Locked |
NotFound |
Specified object was not found |
NoPermission |
User does not have permission to carry out this operation |
StudySuspended |
The study has the status Suspended |
UnknownError |
An unknown error occurred |