pt_host_command
Executes commands in a Packet Tracer host's Command Prompt and returns the output, including interactive responses for ping, ipconfig, telnet, SSH, and FTP tasks.
Instructions
Runs a command in a PC/Laptop/Server's Desktop > Command Prompt (ping, ipconfig, ipconfig /all, ipconfig /renew, tracert, arp -a, nslookup, netstat, telnet, ssh -l user ip, ftp...) and returns the output.
Parameters:
device: the host's name.
command: the line to run (e.g. "ping 192.168.1.1").
inputs: answers to whatever the command asks afterwards, in order (e.g. a telnet/ssh password, then commands for the remote device).
timeout: maximum seconds per line, up to 300 (a failing ping takes ~15 s).
show / capture / output_dir: as in pt_cli; opens Desktop > Command Prompt.
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": {
"device": "<device>",
"command": "<command>"
},
"name": "pt_host_command"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| show | No | ||
| device | Yes | ||
| inputs | No | ||
| capture | No | ||
| command | Yes | ||
| timeout | No | ||
| output_dir | No | screenshots |