ig-dm
Write Instagram DMs that get replies - the keyword delivery (and the comment-to-DM automation that sends it through PostZen), the first message to someone who engaged, the collab pitch, and the two follow-ups. Use when the user says "DM this person", "what do I send them", "set up the keyword DM", "outreach message", "how do I follow up", "pitch this brand", or is reaching out to someone specific.
postzen-dev · Static checks on file
Installation
Read the source and dependencies before running a command. Copying does not install or execute anything.
npx skills add postzen-dev/instagram-agent-skill --skill ig-dmAbout this skill
name: ig-dm description: >- Write Instagram DMs that get replies - the keyword delivery (and the comment-to-DM automation that sends it through PostZen), the first message to someone who engaged, the collab pitch, and the two follow-ups. Use when the user says "DM this person", "what do I send them", "set up the keyword DM", "outreach message", "how do I follow up", "pitch this brand", or is reaching out to someone specific.
ig-dm
Instagram DMs are the only place on the platform where money actually changes hands, and they are also where most accounts burn the goodwill their content earned. The difference is entirely about who moved first.
The three kinds of DM, and only three are worth writing
1. The reply to a hand raised. They commented the keyword, answered the poll, replied to a story, or saved and asked. They moved first. This is 90% of the DMs worth sending and it converts because it is not outreach.
2. The warm approach. Someone whose posts the user has genuinely been commenting on for weeks. There is a shared thread of conversation already.
3. The collab or brand pitch. A specific proposal to a specific account, with a reason it is them.
Everything else is cold DMing strangers, which is what everybody else does, and it is why reply rates sit where they do. If the user is asking for a cold sequence, say plainly that it is the lowest-yield thing they could do with the same hour, and offer the alternative: comment on those ten accounts for two weeks first. Then write it if they still want it.
Before writing, get the specifics
Ask in one batched question:
- Who - handle, what they do, and what they posted or did that started this.
- The trigger - the actual reason to message today. A keyword they commented, a story they replied to, a post they published. Not "they fit the ICP".
- What the user wants - a conversation, a sale, a collab, a referral. Be honest internally, even if the message does not lead with it.
If there is no trigger, there is no message. Say so.
The keyword delivery
The most common DM in this pack and the easiest to ruin. They commented one word. They are expecting the thing. So:
{their name}, here it is: {the thing, or the link}.
{one line on how to use it}
{one question they can answer in four words}
Send the thing first, in message one, with no gate. A keyword post that delivers a "before I send it, can I ask what you do?" is a bait and switch and it is remembered. The question at the end is what starts the conversation, and it is optional for them.
Automated keyword replies are a supported feature for professional accounts, through Instagram's own tools or an approved partner. Using that is fine. Sending unsolicited bulk DMs is not, and it is the fastest route to a restricted account.
Making it an automation through PostZen
If the PostZen MCP tools are in this session, the keyword delivery does not
have to be sent by hand. createCommentAutomation watches the comments on a
post (or the whole account) and sends the DM for each matching comment, using
Meta's one private reply per comment. Write the message as above, then build
the call. The parts:
Where it listens.
accountIdfromlistAccounts({ platform: "instagram" }). Fixed after creation.name, 1 to 120 characters, for the user's own list.trigger:"comment"(default) or"story_reply".- Scope:
platformPostId(the Instagram media id) for one post, orpostId(a PostZen post id; it resolves when the post publishes, so you can set this up before/ig-publishsends the reel), or neither for the whole account. One active per-post automation per post; a second returnsduplicatePostAutomation. A per-post automation wins on its own post; otherwise account-wide ones are tried oldest first.
What it matches.
keywords: up to 50, each 1 to 100 characters. Case- and accent-insensitive. An empty list matches every comment, which is almost never what the user wants on a public post.matchMode:"contains"(default),"exact"or"word". For a one-word keyword like CONTRACT use"word", so "contractor" does not fire.typoTolerance: trueworks with"word"only, and forgives one edit on keywords of 4 to 7 characters, two on 8 or more. It cuts both ways: two edits turn "contract" back into "contractor", so leave it off when the keyword has a longer everyday form.excludeKeywords: up to 50, same mode, vetoes a match.
What it sends.
dmMessage: the delivery, written as above. At most 1,000 UTF-8 bytes, not characters: emoji and accents cost several bytes each. With buttons the cap is 640 characters.dmMessageVariations: up to 5 alternates, same limits, picked at random with the base message. Same warmth, different words, so forty people do not post identical screenshots.buttons: up to 3 of{ type: "url", title (1 to 20 chars), url }. A link as a button beats a link in the text. Cannot be combined withtemplate.template: an image card instead of buttons.{ type: "generic", imageAspectRatio: "horizontal" | "square", elements: [{ title (≤80), subtitle? (≤80), imageUrl, buttons? (≤3) }] }, 1 to 10 elements; several elements render as a swipeable carousel.imageUrlis a public HTTPS URL Meta can fetch. AcreateMediaPresignpublicUrlworks and PostZen keeps it for as long as an automation uses it, but upload the file to theuploadUrlbefore you create the automation, or the card has nothing to show. Any stable public image URL works too. If Meta rejects a card or buttons, PostZen falls back to plain text with the titles and URLs and the log showsbuttonsDropped: true.dmDelaySeconds: 0 to 86400, default 0. A short delay reads less like a bot. Thirty to ninety seconds is plenty.
The public reply.
commentReply: 1 to 1,000 characters, posted under their comment *after