Luke Stevens, Murdoch Children's Research Institute https://www.mcri.edu.au
Read lock status, lock and unlock entire records or their data entry forms via API calls.
Post api token and record[,event][,instrument][,instance][,arm]
to your regular system API endpoint, using the following query string:
?NOAUTH&type=module&prefix=locking_api&page=<action page>
<action page>
must be one of:
- status: Obtain current lock state of the
record[,event][,instrument][,instance][,arm]
- lock: Lock the
record[,event][,instrument][,instance][,arm]
- unlock: Unlock the
record[,event][,instrument][,instance][,arm]
Note it is not possible to lock a form on data level that has not yet had any data entry.
curl -d "token=ABCDEF0123456789ABCDEF0123456789&returnFormat=json&record=1001&event=event_1_arm_1&instrument=medication&instance=4"
"https://redcap.ourplace.edu/api/?NOAUTH&type=module&prefix=locking_api&page=status"
curl -d "token=ABCDEF0123456789ABCDEF0123456789&returnFormat=json&record=1001&arm=1&lock_record_level=true"
"https://redcap.ourplace.edu/api/?NOAUTH&type=module&prefix=locking_api&page=status"
Return Format options are the usual csv, json or xml (default).
Locks the entire record if set to true.
JSON format allows to submit multiple records at once. Currently only supported in lock on record level.