Digital Sovereignty for everyone

Abilities

Get Lock

lh-post-locking/get-lock Read-only Idempotent

Returns the lock state of one post, and whether the calling account can edit it and can lock it. It gives whether the post type is lockable, whether the post is locked, and who locked it and when (GMT). Read-only. Requires read_post on the post. Pass site_id to act on another site you belong to.

Parameter Type Required Default Description
post_id integer Yes ID of the post on the current site.
site_id integer No Optional. ID of another site in the network to act on; list-my-sites gives the sites you belong to. Permissions are checked on that site. Omit for this site.

List Locked Posts

lh-post-locking/list-locked Read-only Idempotent

Lists the locked posts on the current site, most recently modified first, with paging. It covers every status except auto-draft, optionally only one lockable post type. Each item gives the post ID, type, status, title, who locked it and when (GMT). Read-only. Requires manage_options. Pass site_id to act on another site you belong to.

Parameter Type Required Default Description
post_type string No "" Only this post type. Must be lockable. Default: every lockable type.
page integer No 1 Page of results, from 1. Default 1.
per_page integer No 20 Posts per page, 1 to 100. Default 20.
site_id integer No Optional. ID of another site in the network to act on; list-my-sites gives the sites you belong to. Permissions are checked on that site. Omit for this site.

Set Lock

lh-post-locking/set-lock Idempotent

Locks or unlocks one post on the current site. A locked post cannot be edited, trashed or deleted by any account without the lock capability, by any route that goes through the WordPress APIs. Uses the same storage as the editor checkbox, so the post_locked and post_unlocked actions fire and the change is attributed to the calling account. Refuses post types that cannot be locked. Setting the state a post already has changes nothing and reports changed false. Requires manage_options. Pass site_id to act on another site you belong to.

Parameter Type Required Default Description
post_id integer Yes ID of the post on the current site.
locked boolean Yes true to lock, false to unlock.
task_id integer No Optional. The lh-tasks task this call is working on. Pass with claim_token: the call is refused unless you hold that claim, and a successful call renews it.
claim_token string No Optional. The claim_token from claim-next-task for task_id. Required when task_id is given.
site_id integer No Optional. ID of another site in the network to act on; list-my-sites gives the sites you belong to. Permissions are checked on that site. Omit for this site.

If you like this plugin please consider making a donation to further development

Install LHero.org

lhero.org

Open it straight from your home screen, full screen and quicker to load.

  1. Tap the Share button . If you cannot see it, tap ••• first.
  2. Scroll down and tap Add to Home Screen.
  3. Tap Add.
  1. Tap the browser menu â‹®.
  2. Tap Install app or Add to Home screen.
  1. In the menu bar, choose File, then Add to Dock.

Use your browser's menu to install this site or add it to your home screen.