The following abilities are registered with the WordPress abilities-api.
| Name | Label | Description |
|---|---|---|
ws-form/action-add | Add action | Add a form action such as a Send Email notification. Prefer this over form-update-json for adding notifications. For the person completing the form, set meta.to to #field(id) for their email field. Returns a stable row_id. |
ws-form/action-delete | Delete action | Delete an action by row_id (preferred), index, or unique label_match. Cannot delete the last email, message, or database action. |
ws-form/action-update | Update action | Update an action by row_id (preferred), index, or unique label_match. Use the actions tool first. Prefer this for editing email notifications. |
ws-form/actions | List actions | Returns form actions (including Send Email notifications) with row_id, index, type id, label, and meta_summary. Prefer row_id for action-update and action-delete. Form notifications are Send Email actions, not form settings. |
ws-form/conditional-add | Add conditional | Add a conditional logic rule. Use the same AI shape as form-create-json conditionals. Action targets use action row_id from the actions tool. |
ws-form/conditional-delete | Delete conditional | Delete a conditional by row_id (preferred), index, or unique label_match. Use the conditionals tool first. |
ws-form/conditional-update | Update conditional | Replace a conditional by row_id (preferred), index, or unique label_match. Pass the full conditional object in AI shape. |
ws-form/conditionals | List conditionals | Returns form conditionals with row_id, index, label, and a short IF/THEN summary. Prefer row_id for conditional-update and conditional-delete. |
ws-form/field-add | Add field | Use this tool to add or insert a new field into a form. Use the sections or fields tools (or form-get-json) to get section_id, and optionally field_id_before to insert before another field. |
ws-form/field-delete | Delete field | Use this tool to delete a field from a form. |
ws-form/field-update | Update field | Use this tool to update an existing field label and/or meta (required, placeholder, help, options, etc.). Prefer this over form-update-json for single-field changes. Field type cannot be changed. Use the fields tool to find field IDs, or form-get-json for full field meta. |
ws-form/fields | List fields | Returns all fields for a form with id, label, type, section_id, and group_id. Prefer this over form-get-json when you only need to find field IDs for field-update, field-delete, or field-add. |
ws-form/form-block | Get form block markup | Gets the block markup for a form in WS Form by form ID. This should only be used for pages edited by the block editor (Gutenberg). |
ws-form/form-clone | Clone form | Use this tool to clone/copy/duplicate a form. The cloned form will be in a draft state. |
ws-form/form-create-json | Create form from a description | Use this tool to create a new form from a description provided by the user. The tool generates the form using a JSON definition that must follow the required structure described in the json input property. Form email notifications are Send Email actions in the actions array, not form settings. |
ws-form/form-delete | Delete form | Trash or permanently delete a form by ID. |
ws-form/form-draft | Draft form | Set a published form back to draft by ID. Draft forms cannot be used on live web pages until they are published again. |
ws-form/form-get-json | Get form in JSON format | Returns the form in JSON format by ID, including fields, actions, and conditionals. Form email notifications are Send Email actions in the actions array (not form settings). Use with form-update-json to edit notifications. |
ws-form/form-publish | Publish form | When a form is created in WS Form it initially has a status of draft. Use this to publish a form by ID so that it can be used on a live web page. |
ws-form/form-restore | Restore form | Restore a form from the trash by ID. |
ws-form/form-shortcode | Get form shortcode | Gets a shortcode for a form in the WS Form form plugin for WordPress by form ID. |
ws-form/form-stats | Get statistical data about a form by ID | Returns statistical data about a form by ID including total views, saves, submissions, daily figures, as well as the total number of submission records and how many of those are unread. |
ws-form/form-update-json | Update a form from a JSON string | Use this tool to modify an existing form using JSON from form-get-json. Prefer field-update for single-field label or meta changes. Use this tool to add or edit form email notifications by updating the actions array (Send Email actions). Notifications are not in form settings. To email the person completing the form, set an email action meta.to to #field(id) for their email field. To add a new field, use field-add instead. Keep the same groups/sections/fields structure. When actions or conditionals are included, they replace the form actions or conditionals. |
ws-form/forms | List forms | Returns a list of all of the forms in WS Form. |
ws-form/section-add | Add section | Add a section to a tab. Use tabs to get group_id (tab id), and sections if inserting before another section. |
ws-form/section-delete | Delete section | Permanently delete a section and its fields. Cannot delete the last section on a tab. Use the sections tool to get section IDs. |
ws-form/section-update | Update section | Update a section label and/or meta (label_render). Use the sections tool to get section IDs. |
ws-form/sections | List sections | Returns all sections for a form with id, label, parent group_id (tab id), and index. Use with section-update, section-delete, and field-add. |
ws-form/submission-get | Get submission | Returns a single submission by ID including its field values. |
ws-form/submission-note-create | Create submission note | Creates a note on a submission. |
ws-form/submission-note-delete | Delete submission note | Deletes a submission note by ID. |
ws-form/submission-note-update | Update submission note | Updates a submission note by ID. |
ws-form/submission-notes | List submission notes | Returns notes for a submission by ID. |
ws-form/submissions | List submissions | Returns a list of submissions for a form by ID. Supports optional date range, status, keyword search, pagination, and ordering. |
ws-form/tab-add | Add tab | Add a tab (group) to a form. First use the tabs tool if you need existing tab IDs. When a form has multiple tabs, also add tab_next / tab_previous fields with field-add as needed. |
ws-form/tab-delete | Delete tab | Permanently delete a tab and its sections/fields. Cannot delete the last tab on a form. Use the tabs tool to get tab IDs. |
ws-form/tab-update | Update tab | Update a tab label by tab ID. Use the tabs tool to get tab IDs. |
ws-form/tabs | List tabs | Returns all tabs (groups) for a form with id, label, and 1-based index. Use tab IDs with tab-update, tab-delete, and section-add (group_id). |