Royal MCP’s ACF Tools — Reference
Four free tools that let Claude, ChatGPT, or Perplexity read and write Advanced Custom Fields data through Royal MCP. Type-aware writes for text, numbers, repeaters, flexible content, relationships, and images; hydrated reads that flatten WP_Post, WP_User, and WP_Term objects to compact JSON.
How ACF + Royal MCP works
When Advanced Custom Fields (free or Pro) is active, Royal MCP registers 4 additional tools for reading and writing ACF fields. Added in v1.4.24.
You might wonder why a dedicated integration exists when wp_get_post_meta already returns custom-field data. The answer is Return Format. WordPress’s meta API returns raw stored values: serialized arrays for repeaters, raw IDs for relationships, raw attachment IDs for image fields. ACF’s get_field() and update_field() respect each field’s Return Format and hydrate values per field type, matching the view a human editor sees in the ACF UI. An AI agent interacting with ACF wants that formatted view, not the raw serialized one.
The four free ACF tools
Return-Format hydration
For relationship, post_object, user, and taxonomy fields configured with Return Format “Object”, Royal MCP flattens WordPress objects to small JSON-friendly arrays so an AI client gets useful structure instead of raw WP_Post, WP_User, or WP_Term objects in the response.
Post: id, title, post_type, status, permalink. User: id, display_name, user_email. Term: id, name, slug, taxonomy. Repeaters and flexible content pass through as arrays with each row hydrated the same way.
Example queries
Ask Claude, ChatGPT, or Perplexity questions like these once ACF + Royal MCP are connected:
- “List the ACF field groups on this site and the fields in each one.”
- “Read all ACF fields for post ID 142 and show me their values.”
- “Get the
subtitlefield value for the post titled ‘Launch Announcement’.” - “Update the
featured_quotefield on post 142 to a new value.” - “Which ACF field groups apply to the Product post type?”
- “Read the
related_postsfield on post 88 and give me the titles and permalinks.”
Pro ACF toolkit — programmatic field-group authoring
The free four tools cover reading and writing existing fields. Authoring new field groups programmatically (the ACF “setup” side, rather than the runtime read/write side) lives in Royal MCP Pro. Use it to define custom fields for a new post type in a single MCP call, migrate field-group configs between environments, or let Claude scaffold a bespoke field set from a brief.
Permissions & safety
ACF read operations require read_post on the target, and write operations require edit_post. Royal MCP enforces WordPress’s standard capability checks on every ACF tool call, so an AI client can only read or write the fields the connecting user has permission to touch.
ACF supports both stable field keys (like field_5f8a2b) and human-readable names (like featured_quote). Prefer keys in scripted workflows because they survive field renames, but names are fine for one-off reads and writes an AI agent constructs on the fly.
When writing a repeater or flexible-content field, pass the full array of rows, not a partial update. ACF replaces the entire field value on write. To edit one row, read the current value, modify the row in memory, and write the whole array back.