List Menus and Locations
Lists every classic menu (with its item count and the theme locations it fills) and every menu location the active theme offers (with the menu shown there, if any). Read-only. Start here for any menu request: it also says whether the theme is a block theme, in which case the header and footer use Navigation menus instead and the next call should be mosmcp/navigation-list. Then use mosmcp/menu-get to see a menu's items.
Also known as: menus, navigation menu, nav menu, header menu, footer menu, main menu, menu locations, which menu is where.
| Property | Value |
|---|---|
| Ability slug | mosmcp/menu-list |
| Wire tool name | mosmcp__menu-list |
| Category | Menus & Navigation (mosmcp-menus) |
| Plan | Free |
Required access
| Requirement | Value |
|---|---|
| Capability | edit_theme_options |
| Minimum default role | Administrator (Shop manager too when WooCommerce is active) |
| Annotations | readOnly: true · destructive: false · idempotent: true · openWorld: false |
Input schema
Takes no input. Send "input": {} (or omit input).
Output schema
| Field | Type | Required | Description |
|---|---|---|---|
| is_block_theme | boolean | Yes | True when the active theme is a block theme, whose header and footer use Navigation menus rather than classic menus. |
| theme_supports_menus | boolean | ||
| menus | object[] | Yes | |
| menus[].menu_id | integer | Yes | Menu ID, accepted wherever a menu is asked for. |
| menus[].name | string | Yes | |
| menus[].slug | string | ||
| menus[].description | string | ||
| menus[].item_count | integer | Published items in the menu. | |
| menus[].locations | string[] | Theme locations this menu is assigned to. Empty means the theme does not display it anywhere. | |
| menus[].auto_add_pages | boolean | Whether WordPress adds every newly published top-level page to this menu automatically. | |
| locations | object[] | Yes | |
| locations[].location | string | Location slug, for example "primary". | |
| locations[].label | string | ||
| locations[].menu_id | integer | Menu shown there, 0 when none. | |
| locations[].menu_name | string | ||
| navigation_count | integer | Number of block-theme Navigation menus; see mosmcp/navigation-list. | |
| warnings | object[] | Non-fatal issues encountered while running. | |
| warnings[].code | string | ||
| warnings[].message | string | ||
| warnings[].context | string | ||
| notes | string[] |
| << Previous | Next >> |
|---|---|
| Get Navigation Menu | List Navigation Menus |
For more information about the Secure MCP Server for WordPress plugin, explore the following resources:
Product Overview | Pricing | Try for Free | Documentation
If you have any questions regarding plugin configuration, pricing plans or licensing, please contact us or mail us at aisupport@xecurify.com.