Skip to content

Use Menu Icons with AI Assistants ​

You can connect a compatible AI assistant to the WordPress Abilities API to search the icon catalogs enabled in Menu Icons and manage icons on navigation menu items.

In this article

Requirements ​

  • Menu Icons must be installed with its Abilities API integration.
  • Your WordPress environment or connector must provide the WordPress Abilities API and make its abilities available to your AI assistant. For example, the Easy MCP AI plugin can expose WordPress Abilities to connected AI clients. After connecting your client, go to Easy MCP AI > Abilities, enable the Menu Icons abilities, and click Save Ability Settings. Then refresh the tools list in your AI client. See Getting Started with Easy MCP AI for connection instructions.
  • The connected WordPress user must have the edit_theme_options capability. To change an icon, that user must also have permission to edit the target menu item.

If the Abilities API is unavailable, Menu Icons does not register these abilities, so your assistant cannot use them.

Available abilities ​

Use this read-only ability to list enabled icon types and their supported settings, or to search their icon catalogs. Its optional inputs are:

  • type — the ID of an enabled icon type to search.
  • query — text to match against icon IDs and names.
  • page — the results page to return. Each page contains up to 50 icons, and the first page is used by default.

Call the ability without type or query to list enabled icon types. The response includes each type's ID, whether it has a searchable catalog, its icon count, its ID format, and the settings fields it supports. To search, provide a type, a query, or both. Search results include each icon's type, ID, and label.

Use this ability to add or update an icon, restyle an existing icon, or remove an icon. It requires the numeric item_id of the navigation menu item.

To add or update an icon, provide an icon object with:

  • type — the enabled icon type ID. This field is required.
  • id — an icon ID returned by menu-icons/search-icons for catalog-based icon types.
  • attachment_id — the ID of an image in the WordPress Media Library for the Image or SVG type.
  • position — before or after, to place the icon relative to the menu label.
  • hide_label — true to hide the menu item's text label, or false to show it.
  • vertical_align — top, middle, baseline, or bottom.
  • font_size — the font icon size in em.
  • svg_width — the SVG width in em.
  • svg_padding — the SVG padding in pixels.
  • image_size — a registered image size name for the Image type.

The settings available depend on the selected icon type. Use the fields returned by menu-icons/search-icons for that type; settings you leave out keep their current values.

To remove an icon, provide the item_id and set remove to true. Do not include an icon object in the same request.

  1. Ask your assistant to call menu-icons/search-icons without a type or query. Review the enabled icon types and the settings fields available for each.
  2. Search for an icon using an enabled type and a descriptive query. Choose an icon ID from the returned results. For an Image or SVG icon, use the ID of the matching image in the WordPress Media Library instead.
  3. Confirm the numeric ID of the menu item you want to change. The search ability finds icons; it does not identify menu items.
  4. Ask your assistant to call menu-icons/set-item-icon with that item_id and the icon type, icon ID or attachment ID, and any supported settings you want to change.
  5. To remove an icon later, ask your assistant to call menu-icons/set-item-icon with the same item_id and remove set to true, without an icon object.

Menu Icons only accepts enabled icon types, valid icon IDs or matching Media Library images, and settings supported by the selected type. When setting an icon, it also checks that icons are enabled for the menu and that the connected user can edit the menu item.

Example prompts ​

  • “Show me the enabled icon types and the settings each type supports.”
  • “Find shopping cart icons and show me the available choices.”
  • “Put the shopping cart icon [icon ID] before the Shop menu item [menu item ID].”
  • “Remove the icon from the Contact menu item [menu item ID].”
Was this helpful?