To lock or unlock data using the HTTP API, simply append the query strings "api" and "lock"/"unlock" to the target record’s URL and send the request using the POST method.
curl -X POST https://www.ragic.com/demo/ragicforms23/10004/102?api&lock
curl -X POST https://www.ragic.com/demo/ragicforms23/10004/102?api&unlock
The permissions for locking/unlocking are the same as when performing the action through the form interface.
You can find your API key in your Personal Settings page.