# manage_wordpress_staging

> Manage a WordPress staging copy.

- Tier: D
- Required scope: write:hosting
- Annotations: destructiveHint
- Docs: https://api.inleed.com/tools/manage-wordpress-staging

## Description

Manage a WordPress staging copy. `action:create` clones `install_id` to a staging path (default `/staging` on the install's own domain) and returns immediately. `action:push` syncs a `staging_id` copy back over `install_id` (production): this overwrites production and cannot be undone, so it does not push on this call — it returns `{status:"confirmation_required", confirmationUrl, …}`; show the human the `confirmationUrl` to approve in the client area, do not approve it yourself, then poll `get_pending_action`. On a node without a licensed Installatron it returns `staged:false` with the reason.

## Input schema

- `input` — string (required). A domain, email address, website URL, numeric service id, or hosting-account username the customer actually owns. Resolved to the owning account automatically; the resolved target is echoed back in the response.
- `install_id` — string (required). The production install, from list_wordpress_installs (installs[].id) — the clone source for create, the overwrite destination for push.
- `action` — enum (required). create to clone production to a staging copy; push to sync a staging copy back over production (overwrites production — confirmation-tier). One of create, push.
- `staging_id` — string. Required for push: the staging install to sync from, from list_wordpress_installs.
- `target_domain` — string. Optional for create: the domain to stage on. Omit to use the install's own domain.
- `target_path` — string. Optional for create: the staging subfolder. Defaults to staging.
- `attempt_key` — string. An idempotency key you choose for a push. Reusing it within an hour returns the same held push.

## Example call

```json
{
  "name": "manage_wordpress_staging",
  "arguments": {
    "input": "example.se",
    "install_id": "res_01hx8n3k5p7q9r2s4t6v8w0y61",
    "action": "create"
  }
}
```

