Streetlights API
1.0.0

The Smartylighting Streetlights API allows you to remotely manage the city lights.

Check out its awesome features:
  • Turn a specific streetlight on/off 🌃
  • Dim a specific streetlight 😎
  • Receive real-time information about environmental lighting conditions 📈

This is the documentation for version 1.0.0 of the API. Last update on Feb 25, 2021.

This API is provided under license Apache 2.0.

Protocol: mqtt
test.mosquitto.org:{port}

Turn on

SUB smartylighting/streetlights/1/0/action/{streetlightId}/turn/on
SUBSCRIBE smartylighting/streetlights/1/0/action/{streetlightId}/turn/on

Turn on/off

Command a particular streetlight to turn the lights on or off.

Headers

Payload

  • command string

    Whether to turn on or off the light.

    Values are true or false.

  • sentAt string(date-time)

    Date and time when the message was sent.

Headers example
{
  "my-app-header": 42
}
Payload example
{
  "command": true,
  "sentAt": "2023-05-04T09:42:00+00:00"
}