Manage WireGuard Interface
manage_wireguard_interfaceManage WireGuard interfaces on MikroTik RouterOS: add, remove, enable, or disable. Private key auto-generated on creation, public key returned.
Instructions
Add, remove, enable, or disable a WireGuard interface. Idempotent by name. RouterOS generates the private key on create — it is never passed in. The public key is returned after creation.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| routerId | No | Router ID; omit to use the default router. | |
| action | Yes | Action to perform | |
| name | Yes | Interface name — idempotency key (e.g. wg0) | |
| listenPort | No | UDP listen port (RouterOS picks one if omitted) | |
| mtu | No | MTU (default 1420) | |
| comment | No | Optional comment | |
| dryRun | No | Preview changes without applying. |