You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14 lines
755 B
Batchfile

curl -s -X GET "http://localhost:32000/Server/DeviceManager/Connected" | jq.exe -r ".data[0].uniqueKey" > id.txt
for /f "delims=" %%x in (id.txt) do set UID=%%x
IF [%UID%] == [null] GOTO NoDevice
curl -X OPTIONS "http://localhost:32000/Driver/PPBAdvance/Start?DriverUniqueKey=%UID%"
curl -X PUT "http://localhost:32000/Driver/PPBAdvance/Power/Hub/Off?DriverUniqueKey=%UID%"
curl -X PUT "http://localhost:32000/Driver/PPBAdvance/Power/Variable/Off?DriverUniqueKey=%UID%"
curl -X PUT "http://localhost:32000/Driver/PPBAdvance/Dew/1/Off?DriverUniqueKey=%UID%"
curl -X PUT "http://localhost:32000/Driver/PPBAdvance/Dew/2/Off?DriverUniqueKey=%UID%"
curl -X POST "http://localhost:32000/Driver/PPBAdvance/Dew/Auto/Off?DriverUniqueKey=%UID%"
:NoDevice
exit /b