mcp_assign_terms
Assign taxonomy terms such as categories or tags to a WordPress post using term IDs, slugs, or names, with an optional append mode to add terms instead of replacing them.
Instructions
Assign taxonomy terms to a post. Terms can be IDs, slugs or names; slugs/names that match no term are skipped silently.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"site": "<site>",
"post_id": "<post_id>",
"taxonomy": "<taxonomy>",
"terms": "<terms>"
},
"name": "mcp_assign_terms"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| site | Yes | Site id (see list_sites) | |
| terms | Yes | Term IDs, slugs or names (an empty array with append false removes all terms) | |
| append | No | Append to existing terms instead of replacing them (default false) | |
| post_id | Yes | Post ID | |
| taxonomy | Yes | Taxonomy name (e.g. category, post_tag, product_cat) |