Instagram DM Auto-Reply for Openclaw

A high-efficiency automation system for monitoring, reading, and securely replying to Instagram Direct Messages using direct API calls.

mupengi-bot
v1.0.0
Feb 15, 2026
1
1.8k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install auto-reply

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install auto-reply using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Instagram DM Auto-Reply?

The Instagram DM Auto-Reply skill is a sophisticated automation framework designed for Openclaw Skills to manage social interactions with surgical precision. Unlike legacy automation that relies on resource-heavy browser snapshots, this skill utilizes v2.js to perform direct REST API calls through CDP cookie extraction. This technical approach ensures maximum token efficiency and speed while providing a reliable interface for AI agents to interact with the Instagram platform.

This skill is built for developers who need a production-grade solution for social media engagement. It bridges the gap between raw browser automation and intelligent conversation management, offering a seamless way to integrate Instagram into a broader automated ecosystem powered by Openclaw Skills.

Instagram DM Auto-Reply Use Cases

  • Automating customer service responses for high-volume Instagram accounts.
  • Real-time monitoring of unread messages with instant notification triggers.
  • Building secure AI-powered chatbots that filter out malicious prompt injection attempts.
  • Implementing cron-based scheduled checks for new business inquiries.
  • Creating a centralized dashboard for social media interactions using Openclaw Skills.

How Instagram DM Auto-Reply Works

  1. The system establishes a connection to a running OpenClaw browser instance (port 18800) to utilize the existing login session.
  2. The dm-watcher.js daemon or check-notify.js script polls the Instagram inbox at configurable intervals.
  3. Detected messages are compared against dm-state.json to ensure each interaction is unique and avoid duplicate processing.
  4. The auto-reply.js script executes a multi-layered security scan to detect jailbreak attempts, prompt injections, or sensitive data requests.
  5. Validated messages are passed to the AI agent for response generation, which is then dispatched via the v2.js direct API wrapper.

Instagram DM Auto-Reply Setup

To deploy this tool within your Openclaw Skills environment, follow these steps:

  1. Ensure an OpenClaw browser is running on port 18800 with an active Instagram login.
  2. Install the WebSocket dependency:
npm i -g ws
  1. Verify the connection by checking your unread message count:
node scripts/v2.js check
  1. (Optional) Configure a cron job for periodic checks:
- schedule: "*/5 * * * *"
  command: "node /path/to/scripts/check-notify.js"

Instagram DM Auto-Reply Data Schema & Taxonomy

The skill manages its state and communication through the following structured data files:

File Role Purpose
dm-state.json Persistence Layer Prevents duplicate replies by tracking processed message IDs.
dm-alert.json Buffer Stores metadata for newly detected DMs pending AI processing.
v2.js Output API Payload Returns clean JSON including thread URLs, user handles, and message text.

Instagram DM Auto-Reply Advanced Features

  • Injection Rejection: Advanced SECURITY_PATTERNS detection to block prompt injection, DAN mode, and social engineering attempts.
  • Smart Fallback: Automatically reverts to a browser-based tool if direct API calls fail, ensuring 100% uptime for Openclaw Skills operations.
  • Token Optimization: Achieves significant cost savings by using direct API calls (~200 tokens) instead of visual browser analysis.
  • Real-time Daemon: A dedicated watcher script that polls every 15 seconds for near-instant response times.
  • Multi-Channel Alerts: Integrated support for Discord notifications to alert administrators of new DMs or security threats.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*