Device Information (Read)
Static information about the connected Melody device.
These change only after a firmware update.
Device Status (Read)
Dynamic operational data from the Melody device.Device Settings (Read/Write)
Configurable parameters that control connectivity and naming.GET /device/settings returns the whole set.
POST /device/settings is a partial update: send only the fields you are changing and the rest keep their current value. false and "" are values, not omissions — {"wifi_enabled": false} turns WiFi off, while a body without wifi_enabled leaves it alone. null means the same as leaving the field out — to clear a string, send "". A field the request does not recognise is rejected with 400, so a misspelled name never passes as “leave this one alone”.
When updating settings, make sure your UI clearly reflects any changes that could disconnect the current control channel (for example, disabling WiFi while using WiFi).
Service Commands (Write)
Service commands trigger specific system-level actions on the device. Send them viaPOST /device/maintenance/command with a JSON body containing command and, where applicable, additional parameters.
Important: Calibration and OTA may move the stroker or restart the device. Always require explicit user confirmation before triggering these commands.
Two actions that are sometimes expected here are handled elsewhere: request an OTP with
POST /device/otp/generate (see OTP via WebSocket for the WebSocket
alternative), and power the device down through the BLE Device Status characteristic
0x1003 → 0x0007.
Example — navigate to WiFi screen:
Current Screen (Read)
Read the screen currently shown on the device display.IDs1(Intro),4(Playback),16(Battery Warning), and17(Overheat Warning) are intentionally omitted — these screens are shown automatically by the device and cannot be navigated to directly.
Firmware Update State
Firmware update state is read fromfirmware_status in the Device Information response (one of
up-to-date, update-available, update-required). Use it to show an update banner in your UI.
Debug Information (Read)
Debug data is exposed for diagnostics and should not normally be shown to end users.It is especially useful during development, QA, or support tooling. Returned by
GET /device/debug/info:
Debug Logging (Write)
You can instruct a connected device to start emitting real-time log messages over WebSocket. Melody captures and stores them for you — see Debug Logging.Usage Notes
- Put
START_CALIBRATIONandSTART_OTAbehind a confirmation dialog — both move the stroker or restart the device. - Changing
wifi_enabledorble_enabledcan drop the very connection carrying the request. - Debug logging lives in memory and is lost when the device restarts, so turn it on only while you need it.