import requests, json, time, sys # Auth token_r = requests.post('http://172.16.3.30:3001/api/auth/login', json={ 'email': 'claude-api@azcomputerguru.com', 'password': 'ClaudeAPI2026!@#' }) token = token_r.json()['token'] headers = {'Authorization': 'Bearer ' + token, 'Content-Type': 'application/json'} agent_id = 'd28a1c90-47d7-448f-a287-197bc8892234' # Send download command via PowerShell cmd = ( "New-Item -ItemType Directory -Path C:/Temp -Force | Out-Null; " "Invoke-WebRequest -Uri 'http://172.16.3.30/gururmm-agent-new.exe' " "-OutFile 'C:/Temp/gururmm-agent-new.exe' -UseBasicParsing; " "$f = Get-Item 'C:/Temp/gururmm-agent-new.exe'; " "Write-Output ('Downloaded: ' + $f.Length.ToString() + ' bytes')" ) r = requests.post( 'http://172.16.3.30:3001/api/agents/' + agent_id + '/command', headers=headers, json={'command_type': 'powershell', 'command': cmd, 'timeout_seconds': 120} ) print('Send:', r.json()) cmd_id = r.json()['command_id'] # Wait and check time.sleep(20) r2 = requests.get('http://172.16.3.30:3001/api/commands/' + cmd_id, headers=headers) d = r2.json() print('Status:', d['status']) print('stdout:', d.get('stdout', '')) print('stderr:', (d.get('stderr', '') or '')[:500])