Create Navigation Menu
wp_create_menuCreate an empty WordPress navigation menu and optionally assign it to theme locations, returning the new menu ID.
Instructions
Create an empty navigation menu, optionally assigning it to theme locations (e.g. ['primary']). Returns the new menu ID. Requires admin.
Args:
name (string): Menu name.
locations (string[]): Optional theme locations to assign.
response_format (enum): markdown | json.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Menu name, e.g. 'Primary Navigation'. | |
| locations | No | Theme menu locations to assign, e.g. ['primary']. Must be locations the active theme registers. | |
| response_format | No | Output format: 'markdown' for human-readable, 'json' for machine-readable. | markdown |