Browse documentation +
Getting startedInstallationConnect a clientSafety profilesWordPress ChatPro licensingAntigravity CLIAntigravity IDETroubleshootingOAuth 2.1 setupApplication PasswordsPage builder workflowsLedger and rollbackApprovals and memoryAbility reference
Pro module9 abilities

Contact Form 7

These abilities register when Contact Form 7 is detected on the site and a Pro licence is active. If either is missing the module stays absent rather than failing at call time.

At a glance

Contact Form 7 registers 9 abilities: 5 that only read, 3 that write, and 1 marked destructive. That split is the practical answer to how much of this module can run unattended. Reads cost nothing and are safe to repeat, so discovery is the part to be generous with; the writes are where review belongs, and the destructive calls stop for an explicit confirmation every single time regardless of which profile is active.

What this module is for

Create, inspect, duplicate, edit, and delete Contact Form 7 forms with canonical form data and tag schema discovery.

Before you rely on it: Verify mail headers, spam protection, and a real delivery path after any form change.

Typical workflows

  • Inspect available tag syntax before drafting a form
  • Duplicate a working form as a safe starting point
  • Compare canonical data before and after an edit

The Contact Form 7 integration page covers the same module from the workflow side, with the capability map and the questions worth asking before a first write.

Availability on your site

The Contact Form 7 module needs three things at once: WPPilot Free as the MCP foundation, an active Pro licence, and the companion plugin detected on the site. Miss any one and the module does not register, which is deliberate: an ability that appears in the tool list but fails at call time is worse than an ability that was never offered. What the connected agent can actually call is then narrowed twice more: by the safety profile active on the site, and by the WordPress capabilities of the user behind the credential. A read that succeeds for an administrator can be absent entirely for an editor.

Every write these abilities perform is recorded in the change ledger, and destructive calls can be routed through the approval queue so a person signs off before anything is applied. A successful tool result means the operation returned, not that the front end, the cache, and every dependent template are correct: that still needs a look.

Reads

Available in every safety profile, including Read Only. Inspection costs nothing and is not rate limited.

AbilityWhat it does
wppilot/cf7-check-setupCheck Contact Form 7 SetupReturns a snapshot of the Contact Form 7 install: whether the plugin is active, its version, whether the minimum supported release is satisfied, the count of saved forms, the current user's CF7 capabilities (edit / read / delete), and whether the Flamingo companion plugin is active (Flamingo is the standard way to persist CF7 submissions — without it CF7 keeps no record of who submitted what, and reading submissions is not possible). Call this once at the start of any session that will read or write CF7 forms.
wppilot/cf7-get-formGet Contact Form 7 FormReads a single Contact Form 7 form by id, including the full template (form), both mail configurations (mail and mail_2, with mail_2.active=false when the secondary mail is disabled), all message strings (messages), the additional-settings blob, locale and hash. Large text fields (form, mail.body, mail_2.body, additional_settings) are truncated at max_field_bytes (default 8192) per field with a *_truncated flag and *_bytes (original byte length) so the agent can decide whether to re-read at a higher cap. Set max_field_bytes to 0 to disable truncation. Returns WP_Error cf7_form_not_found when the id does not exist or refers to a trashed / auto-draft / non-CF7 post.
wppilot/cf7-get-form-canonicalGet Contact Form 7 Form (Canonical)Reads a single Contact Form 7 form by id and returns it mapped to the plugin-agnostic form-model-schema vocabulary (17 canonical types: text/email/tel/url/number/textarea/date/time/datetime/select/radio/checkbox/file/hidden/submit/consent/group) used by the form-model-migration skill. CF7 natively covers 14 of those 17 — time/datetime/group have no CF7 form-tag and appear only on migration targets. Output keys: fields[] with canonical types, mail_config{} for the primary mail, notifications[] for mail_2 (when active), messages{} flat string map, meta{} (source plugin + version + optional cf7_additional_settings echo), plus warnings[] for everything that does not fit the canonical shape (CF7 [quiz] anti-spam, [recaptcha] site-global keys, [response] output area, non-empty additional_settings, special mail-tags, [acceptance optional]). Honours the same max_field_bytes truncation contract as cf7-get-form (default 8192 bytes for mail_config.body, notifications[].body, meta.cf7_additional_settings, with *_truncated flags); pass max_field_bytes: 0 to disable truncation when full-fidelity canonical is required before an execute-mode migration. Returns WP_Error cf7_form_not_found when the id does not exist or refers to a trashed / auto-draft / non-CF7 post. Use this ability inside the form-model-migration workflow (Phase 2 — read source schema); for ad-hoc inspection outside the migration pipeline, prefer cf7-get-form which returns the CF7-native shape.
wppilot/cf7-get-tags-schemaGet Contact Form 7 Tag SchemaReturns the Contact Form 7 form-tag vocabulary: every tag type CF7 accepts in a form template (text, email, tel, url, number, date, textarea, select, checkbox, radio, file, acceptance, quiz, submit, hidden, response, plus module tags recaptcha), what each one renders, which modifiers it accepts, and a short example. Pass type to receive only that single entry. Call this once before composing a form template so cf7-create-form and cf7-edit-form receive valid syntax on the first try. NOTE: the label / description / example strings are English-only (this is a static reference, not a translated catalogue) — translate them on the agent side if needed.
wppilot/cf7-list-formsList Contact Form 7 FormsLists Contact Form 7 forms with optional filters. Response is a compact summary per form — id, title, slug, status, locale, hash, tag_count, modified — WITHOUT the heavy properties (form template, mail, mail_2, messages, additional_settings) so listings stay small. Call cf7-get-form with a specific id to read the full body. Filters: status (publish|draft|pending|private|trash — defaults to publish+draft, trash must be requested explicitly), locale (e.g. "it" or "en_US"), search (case-insensitive substring against title and slug). Pagination: limit (default 50, hard cap 500 enforced by the schema — out-of-range values are rejected at the REST/MCP layer; direct PHP callers are clamped defensively), offset (default 0, must be ≥0). total in the response always reflects the unpaginated match count so the agent knows whether to keep paging. NOTE: under WPML or Polylang the query is scoped to the current admin language by the plugins' own pre_get_posts filters — call check-setup first to detect wpml_active/polylang_active if cross-language enumeration matters.

Writes

Gated by the active profile and your WordPress capabilities. Rate limited to 120 per minute per credential.

AbilityWhat it does
wppilot/cf7-create-formCreate Contact Form 7 FormCreates a new Contact Form 7 form. Required: title. Optional: slug (CPT post_name — defaults to a slugified title), status (publish|draft, default publish), locale (e.g. "it" or "en_US"), form (template body using CF7 form-tag syntax — call cf7-get-tags-schema for the vocabulary), mail (primary mail config), mail_2 (secondary mail config), messages (validation / mail / spam strings), additional_settings (newline-separated key:value pairs CF7 modules read — e.g. "demo_mode: on"). Properties left out fall back to the CF7 default template for the requested locale. WP-native aliases accepted: post_titletitle, post_nameslug, post_statusstatus. Returns the full form shape (same as cf7-get-form).
wppilot/cf7-duplicate-formDuplicate Contact Form 7 FormClones an existing Contact Form 7 form into a new row. Every canonical property (form, mail, mail_2, messages, additional_settings, locale) is copied verbatim; the new form receives a fresh hash and a new id. Optional title overrides the duplicate's post_title (defaults to the source title plus " (copy)"). Useful when an agent wants to A/B a contact form, localise an existing form for a new region, or stage edits without touching the live original.
wppilot/cf7-edit-formEdit Contact Form 7 FormMerges new field values into an existing Contact Form 7 form identified by id. Only the keys you pass are changed — omitted keys keep their current value. For nested objects (mail, mail_2, messages) the merge is shallow per-key so you can patch only mail.recipient without losing the rest of the mail config. Use cf7-get-form first to read the current state, then call this with only the keys to change. WP-native aliases accepted: post_titletitle, post_nameslug, post_statusstatus. Returns the full form shape after the merge.

Destructive

Marked destructive in the source, so each call needs an explicit confirmation flag, every time.

AbilityWhat it does
wppilot/cf7-delete-formDelete Contact Form 7 FormPermanently removes a Contact Form 7 form by id. Force-delete by default — the form does NOT go to trash, it is gone. There is no undo via the abilities. Any page or post that embeds the form's shortcode ([contact-form-7 id="<id>"]) will start rendering the CF7 "this contact form does not exist" message after the delete. Set force to false to trash the form instead (it can then be restored from wp-admin → Forms → Trash).