Spoiler Interface API¶
Spoiler Interface is an IoT platform built around a JSON HTTP API. Use it to register and manage devices (sensors, switches, GPS trackers, battery monitors, weather stations, workstations, network monitors and your own dynamic interfaces), push readings, read history, configure alarms and notifications, stream live data over MQTT, and manage your account.
-
Getting started
Authentication modes, the response envelope, sign-up and login.
-
Devices
Add devices, push updates and read history for every device type.
-
Live data
Device-linked MQTT topics, publishing and the WebSocket live stream.
-
Alarms & notifications
Threshold alarms and email / WhatsApp / SMS alerts per device.
-
Reports & sharing
PDF reports, shareable report links and time-limited device sharing.
-
Endpoint index
Every endpoint on one page, with method, path and auth.
API servers¶
| Server | Base URL |
|---|---|
| Spoiler Interface (hosted) | https://spoilerinterface.com/interface |
| Local / self-hosted (behind nginx) | http://localhost/interface |
Every endpoint in this documentation is relative to the base URL, e.g.
https://spoilerinterface.com/interface/test.
Quick start¶
- Sign up and verify your email address. Accounts must be verified before they can log in.
-
Log in to get an
api_key: -
Call any endpoint with
?api_key=..., for exampleGET https://spoilerinterface.com/interface/sensor/list?api_key=3b9e1f0c7a5d4e2f8a6b0c1d. - Add a device (e.g.
POST /add/sensor). Your device then pushes readings with its own id and token. It doesn't need yourapi_key.
All date and time values are epoch seconds (UTC). Devices belong to the account that created them.