wp_publish_swap
Promote a staged draft to the live post, then verify by purging cache, deleting draft, and probing the public URL. Requires allow_prod for production writes.
Instructions
Promote a staged draft onto the live post (WP keeps a revision), then verify.
Copies the draft's content onto live_id, purges cache (Divi), deletes the
draft, and probes the public URL. Prod writes require allow_prod=true.
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": {
"install": "<install>",
"live_id": "<live_id>",
"draft_id": "<draft_id>"
},
"name": "wp_publish_swap"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| install | Yes | ||
| live_id | Yes | ||
| draft_id | Yes | ||
| allow_prod | No |