SwitchBotAPI
SwitchBotAPI copied to clipboard
PowLevel not operating as stated in the documentation on K10+
Analysis
Is PowLevel supported on the K10+ via the public API? It returns success, but has no effect. Is this possibly an unimplemented command stub?
Expected Behavior
Change the power level of the device
Steps To Reproduce
Sending valid JSON ✅
-
The API returns 200 OK with statusCode: 100 ✅
-
Have tested while cleaning / not cleaning ✅
-
tried all value formats ("1", 1) ✅
However nothing changes in the app or device behavior
Logs
API Response: {"statusCode":100, "body":{},"message":"success"}
Configuration
def send_k10_command(device_id, command, parameter="default"):
url = f"https://api.switch-bot.com/v1.1/devices/{device_id}/commands"
headers = get_auth_headers()
headers['Content-Type'] = 'application/json'
payload = {
"command": command,
"parameter": parameter,
"commandType": "command"
}
response = requests.post(url, headers=headers, json=payload)
print("API Response:", response.text}
print(f"Sent {command} to {device_id} with param {parameter} → {response.status_code}")
return response.status_code == 200
Environment
- OS:
- Software:
- Node:
- npm:
Additional Context
No response