forms/{post}/{form} REST endpoint
Submit a published form or read and save its private action settings.
Endpoint#
Submit a published form or read and save its private action settings.
/wp-json/cantata-edit/v1/forms/(?P<post>\d+)/(?P<form>[a-z0-9-]{1,40})
Named regular-expression groups in this registered route are path parameters. Replace them with an actual matching value when constructing a request.
POST#
This route is publicly callable. Its callback still validates the submitted data, target, and any feature-specific abuse checks. Public access is not unrestricted mutation of site content.
Permission function: __return_true.
Registered argument schema#
[]
An empty schema means the route did not declare arguments in its registration. It does not mean that the callback accepts arbitrary data or has no required body fields. Callback-level validation remains authoritative.
Callback input keys#
files, form, label, name, post, shown, value. This literal-key inventory supplements the registered schema; nested objects and downstream validators can define additional structure.
Implementation#
- cantata_edit_form_submit
- cantata_edit_form_check
- cantata_edit_form_files
- cantata_edit_form_fill
- cantata_edit_form_schema
- cantata_edit_form_settings
Client handling#
Use HTTPS on production sites. Treat authentication failures, validation errors, missing records, and stale-revision conflicts as different outcomes. Read the returned WordPress error code and message. Before retrying a timed-out mutation, determine whether the first request succeeded. Prefer the documented higher-level editor or Ability workflow when an endpoint coordinates several metadata owners.