Menu

Commands API

Fire device actions from outside the dashboard — wire OhioIoT into a CRM, a scheduler, a Slack bot, anything that needs to reach a device.

A dedicated, hosted Commands API — HTTPS endpoints that trigger your saved Commands and report feedback — is on the roadmap. Until it ships, you can already reach your devices from external code today; this page covers how.

What you can do today

A command, at bottom, is a message published to a topic your device listens on. Anything that can publish that message can fire the command — you don't have to wait for a wrapper endpoint:

  • Over HTTP — POST the command payload to the device's command topic through the Ingest API. Good for cron jobs, webhooks, and serverless functions.
  • Over MQTT — publish to the command topic from a connected client. Good for a long-running service that also wants to subscribe to live data. See Talk from Node.js.
# fire a command at a device over HTTP
curl -H "x-auth-key: YOUR_KEY" -H "Content-Type: text/plain" \
     -d "open" \
     https://ingest.ohioiot.com/garage01/command/door

What the hosted API will add

Publishing a command yourself reaches the device, but it doesn't give you the round-trip feedback the dashboard buttons get — received / success / failed tracking with timeouts. That tracking is the main thing a hosted Commands API will add: trigger a saved Command by name and get the same feedback lifecycle back over HTTP. When it lands, it'll live here.

Want this sooner rather than later? Tell us what you'd wire it into — the concrete use cases are what move a roadmap item up the list.