AI agent Instagram DM automation
AI agents andInstagram DMs.What's allowed.
Yes, an AI agent can run Instagram DM automation, but only through Meta's official API: it can set up and manage comment-to-DM campaigns and read the results. It can't cold-DM people who never messaged you, and “AI DM bots” that log in with your password break Instagram's Terms.
Updated
Example: a creator asks an AI agent to DM everyone who liked a reel. The agent explains Instagram's API doesn't allow that, offers a comment keyword instead, finds the reel, asks about a follow gate and public reply, and creates the campaign.
Can AI send Instagram DMs?
What an agentcan do.
Everything here goes through Meta's official Instagram API, so it works the same whether a person or an agent sets it up.
Can01
Set up campaigns.
Pick a post, your next reel or every post, set the keywords, write the DM and add the link.Can02
Change and pause them.
Swap a link, add a keyword, pause a campaign when the offer ends, resume it later.Can03
Read the numbers.
DMs sent, skipped and failed, clicks and click rate, per campaign. Then tell you which one worked.Can04
Work in your language.
Ask in English, Hindi or Hinglish. Keywords work in any script, and the DM is the text you approve.
Can't01
Cold-DM strangers.
Meta's API only lets a business message people who messaged it first, or send one private reply to a comment.Can't02
Reply twice to a comment.
Instagram allows one private reply per comment, ever, within 7 days. No agent changes that.Shouldn't03
Log in as you.
"AI DM bots" that take your password and drive the app break Instagram's Terms of Use.Not DMpop04
Write live replies.
DMpop sends the message saved in the campaign. AI-written replies inside a DM conversation aren't a DMpop feature.
Instagram's rules for automated DMs
The rulesdon't bend for AI.
An agent is just another caller of Meta's API. These limits apply to it like anyone else.
Who an agent can message
Meta's Instagram messaging docs say conversations only begin when an Instagram user sends a message to the business. A comment allows a different thing: one private reply, sent within 7 days. After that, you can message the person again only once they respond, usually within 24 hours. The messaging window guide has the details.
So an “AI agent that DMs your leads” really means one of two things. Either it responds to people who reached out first, or it isn't using the official API.
Password-based AI DM bots
Some tools ask for your Instagram username and password, then drive the app to follow, like and DM. That's automated access Instagram's Terms don't allow, and it's what gets accounts limited. Is Instagram auto DM safe? explains how to tell the two kinds apart.
Two jobs called “AI DMs”
Managing the automation: an agent creates the campaign, picks the keyword, reads the stats. That's what DMpop's tools are for. Writing the replies: an AI reads each incoming DM and writes a personal answer. DMpop doesn't do that; every DM is the message you approved. Other tools offer AI chat replies; if you try one, check it connects through Meta's own login.
Limits that still apply
- One private reply per comment, across every tool. If two campaigns match one comment, the oldest campaign sends it.
- 750 private replies an hour per account, Meta's limit. DMpop queues and retries; see Instagram DM limits.
- Your DMpop plan's monthly DMs. On Free, 1,000 DMs a month and 5 live campaigns.
Agentic Instagram automation: three ways in
Same campaigns.Pick your door.
DMpop's MCP server and REST API do the same things. What changes is who calls them.
| Approach | Who it's for | Auth | Setup | Start here |
|---|---|---|---|---|
| MCP server in an assistant | ChatGPT, Claude, Claude Code, Codex, Cursor | Sign-in (ChatGPT, Claude) or an API key | Minutes. Add a URL, click Allow | Instagram MCP |
| MCP server in an agent workflow | n8n's AI Agent, any agent that speaks MCP | API key as a Bearer token | Minutes | n8n AI agent |
| REST API as your agent's tools | Your own code, any model with function calling | API key as a Bearer token | An hour. You write the tool wrappers | Example below |
| No AI, plain workflow | Zapier, Make, n8n HTTP Request | API key as a Bearer token | Minutes. Fixed fields, no surprises | Zapier, Make, n8n |
If your agent framework can connect to a remote MCP server, point it at https://app.dmpop.com/mcp with an API key in the Authorization: Bearer header and you get all seven tools with no wrapper code. Check your framework's own docs for how it adds MCP servers. If it can't, or you want tighter control over what the model can call, wrap the REST API as below.
Build your own Instagram AI agent
Your agent.Three tools.
A small TypeScript example: three DMpop REST calls exposed as function-calling tools. No SDK, just fetch.
// Three DMpop tools for your own agent. The shape (name, description,// JSON Schema parameters) is what most function-calling APIs accept;// wrap it in whatever your model provider expects.const API = "https://app.dmpop.com/api/v1";async function dmpop(path: string, init: RequestInit = {}) { const res = await fetch(API + path, { ...init, headers: { Authorization: `Bearer ${process.env.DMPOP_API_KEY}`, "Content-Type": "application/json", }, }); const body = await res.json(); // Hand errors back to the model so it can explain them. return res.ok ? body.data : { error: body.error };}export const tools = [ { name: "list_campaigns", description: "List comment-to-DM campaigns with sent, skipped, failed, clicks and ctr.", parameters: { type: "object", properties: {}, additionalProperties: false }, }, { name: "create_next_reel_campaign", description: "Create a campaign on the user's next reel. Confirm keyword, message and link with the user first.", parameters: { type: "object", properties: { name: { type: "string" }, keywords: { type: "array", items: { type: "string" }, maxItems: 10 }, message: { type: "string", description: "{username} becomes the commenter's handle" }, link: { type: "string" }, buttonLabel: { type: "string", maxLength: 20 }, }, required: ["name", "keywords", "message"], additionalProperties: false, }, }, { name: "pause_campaign", description: "Pause a campaign. Links in DMs it already sent keep working.", parameters: { type: "object", properties: { campaignId: { type: "string" } }, required: ["campaignId"], additionalProperties: false, }, },];// Run whichever tool the model asked for, then send the result back to it.export async function runTool(name: string, args: Record<string, unknown>) { switch (name) { case "list_campaigns": return dmpop("/campaigns"); case "create_next_reel_campaign": return dmpop("/campaigns", { method: "POST", body: JSON.stringify({ ...args, nextReel: true }), }); case "pause_campaign": return dmpop(`/campaigns/${encodeURIComponent(String(args.campaignId))}`, { method: "PATCH", body: JSON.stringify({ active: false }), }); default: return { error: `Unknown tool: ${name}` }; }}How the loop works
You send the model your messages and the tools list. When it asks for a tool, call runTool, send the result back, and repeat until it answers in words. Function-calling APIs generally follow this pattern, each with its own field names.
Why only three tools
There's no delete tool on purpose. Deleting a campaign breaks the links in DMs it already sent; pausing doesn't. Give the model the smallest set that does the job.
Details that bite
- DMpop rejects unknown fields with a 400, so a model that invents a field gets a clear error back.
- 60 requests a minute per key. Cap your loop.
nextReelattaches to the first reel posted after the campaign is created, within about five minutes of it going live.- Optional fields like
publicReplies,requireFollowandalsoOnDmsare in the developer docs. Keep the follow gate optional; see Instagram's rules.
Guardrails for any Instagram agent
Let it help.Keep the keys.
- Confirm before it creates. DMpop's MCP tools already tell assistants to ask about the follow gate and a public reply. In your own agent, put that in the system prompt.
- Pause, don't delete. A paused campaign keeps its links and stats. A deleted one takes both with it.
- Read-only for reports. An agent that summarises results needs
list_campaignsand nothing else. - One key per agent. Name each key, and revoke one in Settings → API keys and MCP without breaking the rest. Only workspace owners and admins can create keys or connect apps.
- Keep the human in the DM. The agent sets up what gets sent. Real conversations that follow are yours to answer.
Questions
AI agents and DMs,answered.
Can AI send Instagram DMs?
Yes, within Meta's rules. Through the official API, a business can send one private reply to a comment, and can message someone after they message it, usually within 24 hours. An AI agent can set that up for you. It can't message people who never commented or messaged you.
Can an AI agent cold-DM people on Instagram?
Not through Meta's official API. Conversations only begin when the Instagram user messages the business, or comments and gets one private reply. Tools that cold-DM do it by logging in with your password and automating the app, which breaks Instagram's Terms of Use.
Does DMpop write AI replies to DMs?
No. DMpop sends the exact message saved in the campaign, with your link. An AI assistant can help you write and set up that message, but it doesn't chat with your followers inside the DM.
Is it safe to connect an AI agent to my Instagram?
With DMpop, the agent never touches your Instagram login. Instagram connects to DMpop through Meta's own login, and the agent gets a DMpop key or token that can only manage campaigns. You can revoke it any time in Settings → API keys and MCP.
Which AI agents work with DMpop?
Any client that speaks MCP over Streamable HTTP, including ChatGPT, Claude, Claude Code, Codex, Cursor and n8n's AI Agent. Agents you build yourself can call the REST API as tools instead.
Is DMpop the only Instagram tool with an MCP server?
No. Several Instagram automation tools offer MCP servers. ManyChat doesn't have an official one as of November 2026. DMpop's is on every plan, Free included.
What does it cost?
The API and MCP server are on every DMpop plan. The Free plan sends 1,000 DMs a month; paid plans start at ₹99 a month, GST included. Your AI model's own costs are separate.
API and MCP on every plan
Let the agent set it up.Let the DM pop.
Connect Instagram through Meta's login, then connect your agent. The Free plan sends 1,000 DMs a month, and paid plans start at ₹99, GST included.