API Reference

HTTP API

This device supports simple HTTP GET requests for remote power control. All commands are issued via:

http://192.168.1.100/cmd.cgi?cmd=$Ax $ARG1 ARG2
  • Replace 192.168.1.100 with your device IP
  • Replace $Ax with the command below
  • Replace $ARG1 and $ARG2 with the relevant argument values if the command requires arguments

Note that only netBooter DU models support HTTPS when configured


Authentication

The HTTP(S) GET API utilizes basic HTTP authentication, passed in via the header

Examples using cURL:

curl -u admin:password "http://192.168.1.100/cmd.cgi?$A3 1 0"

# Using base64
BASE64_AUTH=$(echo -n ${USERNAME}:${PASSWORD} | base64)
curl -s "http://192.168.1.100/cmd.cgi?$A3 1 0
	-H "Authorization: Basic $BASE64_AUTH"

Command List

CommandCodeArg1Arg2Example
Set Outlet ON/OFF$A3Outlet NumberState (0=OFF, 1=ON)http://192.168.1.100/cmd.cgi?$A3 1 1
Reboot Outlet$A4Outlet Numberhttp://192.168.1.100/cmd.cgi?$A4 2
Get Status (returns outlet states, current, and temp)$A5http://192.168.1.100/cmd.cgi?$A5
Set All Outlets$A7State (0=OFF, 1=ON)http://192.168.1.100/cmd.cgi?$A7 0


Return Codes


CodeDescription
$A0OK - Executed successfully
$AFAction failed or unknown

$A5 Status Return Code

$A5 returns the status of outlet states, current, and temperature. The response will look either like

xxxx,cccc,cccc,tt

or

xxxx,cccc,tt

where each "x" denotes an outlet state (1=ON, 0=OFF), with the right most "x" representing outlet 1.

"c" denotes the AC current draw (in amps), and "t" represents temperature (in Celsius). Note that only netBooter DU series PDUs support current draw and temperature measurement.