security-set-item-lock
Lock or unlock a Sitecore item to manage editing access. Use force to take a lock held by another user; this is separate from delete protection.
Instructions
Locks or unlocks a Sitecore item for editing. Independent of delete protection — use security-set-item-protection for that.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | No | The ID of the item. Supply this or path. | |
| full | No | Return the unprojected .NET object graph. Very large (100,000+ chars/item); diagnostics only. | |
| path | No | The path of the item (e.g. /sitecore/content/Home). Supply this or id. | |
| force | No | action 'lock' only: take the lock even if another user holds it. | |
| action | Yes | Whether to lock the item or release its lock. | |
| fields | No | Extra Sitecore field names to include, e.g. ['Title']. Ignored when full is true. | |
| database | No | Database to resolve an id against (default master). | |
| passThru | No | Return the item, projected to its identity. |