• STATUS
  • CONTROL
  • AUDIT
  • HUMAN

How to monitor IoT device activity with your AI

Connect PubNub to your AI client to watch device status in real time. Once connected, your agent can act on heartbeat data immediately.

Ask AI about this page

Short answer

How can I use AI to track my IoT devices?

Your AI uses PubNub channels to check if devices are online and sends commands back to them. You get a live view of device presence and the ability to trigger hardware actions through chat.

The outcomes.

What your AI manages.

The AI handles the real-time data stream so you don't have to watch a dashboard.

STATUS

Live presence tracking

The AI monitors heartbeats to see which devices are active. You get instant updates on device connectivity.

CONTROL

Remote command execution

Your agent sends messages to specific channels to trigger hardware functions. This turns chat into a remote control.

AUDIT

Presence history

The AI checks the current state of all connected users or devices. You can ask for a summary of who is online right now.

HUMAN

Manual intervention

The AI flags anomalies but leaves final critical decisions to you. You decide if a command is safe to send.

The workflow

What your AI does when <the thing arrives>.

The AI acts as a bridge between your chat interface and the PubNub messaging layer.

  1. Check device status

    The AI looks at the current presence state to see which devices are currently connected to the network.

    presence_get_state
  2. Watch for heartbeats

    The AI monitors the presence stream to detect when a device stops sending its regular signal.

    presence_heartbeat
  3. Locate active devices

    The AI identifies exactly where devices are currently active within the channel structure.

    presence_where_now
  4. Send instructions

    The AI pushes a command to a specific channel to change the behavior of a device.

    publish_message

Try it

Copy these to start.

Use these prompts to begin interacting with your hardware.

Starting points

Replace the channel names and device IDs with your actual PubNub credentials.

PubNub Connector

You're all set. Choose your MCP client and follow the setup instructions.

Connector linkhttps://edge.vinkius.com/vk_preview_RCnBsSkUGMNTFGRb3L5phSfqwmHtbHFrYEYF7Aui/mcp

Claude Desktop

Follow the steps below to connect in seconds.

  1. 1In Claude Desktop, open Settings → Connectors.
  2. 2Click “Add custom connector” and paste the connector link above as the remote MCP server URL.
  3. 3Click Add and start a new chat — PubNub capabilities are ready to use.
Configuration · claude_desktop_config.jsonCopy
{
  "mcpServers": {
    "pubnub-real-time-messaging-mcp": {
      "url": "https://edge.vinkius.com/vk_preview_RCnBsSkUGMNTFGRb3L5phSfqwmHtbHFrYEYF7Aui/mcp"
    }
  }
}
Copy into chat04
  • Check the current presence state for the 'sensor_array_01' channel.

  • Which devices are currently active in the 'factory_floor' channel?

  • Send a command to the 'thermostat_main' channel to set temperature to 72.

  • Monitor the 'security_gate' channel for any heartbeat changes.

  • Claude
  • ChatGPT
  • Cursor
  • VS Code
  • Windsurf
  • Claude Code
  • JetBrains
  • Cline

Start here

Connect PubNub once, then ask.

Just link your PubNub account to Vinkius. Your credentials stay encrypted, and you can start talking to your devices immediately.

Connect PubNub to your AI

FAQ

How this task behaves.

  • 01

    Can the AI automatically reboot my hardware?

    Only if you have a channel set up to receive reboot commands and you tell the AI to send that specific message.

  • 02

    Does the AI delete my PubNub channels?

    No. The AI can only publish messages or read presence data. It cannot delete or modify your channel configurations.

  • 03

    Can the AI decide to shut down a system on its own?

    No. The AI only acts when you give it a prompt. It does not run autonomous loops without your input.

  • 04

    How does the AI know if a device went offline?

    It uses presence tools to check the heartbeat and state of the channels your devices are using.

  • 05

    Can the AI see my private message history?

    No. The AI only interacts with the specific channels and presence data you instruct it to use.

  • More questions about PubNub? See everything the PubNub Connector can do

Connect PubNub to Claude, Cursor, ChatGPT & more