# Instagram MCP

> Instagram (Social Media & Business) MCP Server lets your AI client manage your entire Instagram presence. You can publish photos and Reels, run deep analytics on post performance, manage comments, and audit your profile—all through natural conversation. Stop jumping between apps; get full control of your content and audience engagement right from your workspace.

## Overview
- **Category:** industry-titans
- **Price:** Free
- **Tags:** social-media-management, content-publishing, audience-insights, reels, engagement-tracking, business-analytics

## Description

Your AI client lets you manage your entire Instagram presence. You can publish photos and Reels, deep-dive into post performance metrics, handle comments, and audit your profile—all just by talking to your agent. You stop jumping between apps and get full control of your content and audience engagement right from your workspace.

### Posting Content

*   **Publishing Media:** You'll post a single photo using a public HTTPS URL and a caption with `publish_photo`. You can also drop a Reel video using a public HTTPS URL (MP4 format) and a caption via `publish_reel`.

### Analytics and Auditing

*   **Post Performance:** The agent pulls detailed data for specific posts, giving you reach, impressions, saves, shares, likes, and comments using `get_insights`. You can check your recent media list, getting basic like and comment counts for images, videos, and carousels with `get_media`. For carousels, the agent pulls out every individual photo or video inside the album using `get_media_children`.
*   **Profile Check:** You get your account's public data, including the follower count, bio, and username, with `get_profile`.

### Managing Engagement

*   **Comment Handling:** The agent fetches all comments on a post—including the text, user, timestamp, and like/reply counts—using `get_comments`. You can then reply to a specific comment with `reply_comment`, or remove a comment entirely by giving the comment ID to `delete_comment`.
*   **Connection Status:** You keep the service running by refreshing the access token; the agent extends the service's validity for another 60 days using `refresh_token`.

## Tools

### delete_comment
Removes a specific Instagram comment when given the comment ID.

### get_comments
Fetches all comments on a post, including the text, user, timestamp, and like/reply counts.

### get_insights
Retrieves detailed performance data (reach, impressions, saves, shares) for a specific post.

### get_media
Gets a list of your recent posts (images, videos, carousels) along with basic like and comment counts.

### get_media_children
Retrieves all individual photos or videos contained within an Instagram carousel album.

### get_profile
Gets your Instagram account's public data, including follower count, bio, and username.

### publish_photo
Posts a single photo to Instagram using a public HTTPS URL and a provided caption.

### publish_reel
Posts a Reel video to Instagram using a public HTTPS URL (MP4 format) and a caption.

### refresh_token
Extends the service's access token validity for another 60 days.

### reply_comment
Posts a reply to a specific comment on Instagram.

## Prompt Examples

**Prompt:** 
```
Publish this photo to Instagram with caption 'Enjoying the sunset! #vibes': https://example.com/photo.jpg
```

**Response:** 
```
Publishing photo… Container created successfully. Media ID: 178412345. Your photo is now live on Instagram! Would you like the permalink to share it elsewhere?
```

**Prompt:** 
```
Show me the insights for my last 3 posts
```

**Response:** 
```
I've retrieved insights for your last 3 posts. Post 1 ('New Collection'): 1,240 reach, 45 saves. Post 2 ('Sale Event'): 3,500 reach, 120 saves. Post 3 ('Behind the Scenes'): 890 reach, 15 saves. Post 2 is performing exceptionally well with a 4.5% engagement rate.
```

**Prompt:** 
```
Are there any new comments on the 'Product Launch' Reel?
```

**Response:** 
```
Yes, I found 5 new comments on your 'Product Launch' Reel. Highlights include: 'Love this!', 'When will it be available?', and 'Great color options'. Would you like me to draft replies for these?
```

## Capabilities

### Analyze post performance metrics
The agent retrieves reach, impressions, likes, comments, shares, and saves for specific posts.

### Publish visual content
The agent posts photos or Reels to your account using a provided public URL and caption.

### Manage comments and replies
The agent lists, fetches, and drafts replies to customer comments on your posts.

### Audit account and media data
The agent gets your profile details, lists all past media, and fetches the contents of carousels.

### Maintain API connection
The agent refreshes your access token, preventing service downtime.

## Use Cases

### The Brand Launch Follow-Up
A marketing manager launches a new product Reel. They ask their agent to run `get_insights` on that Reel and also use `get_comments` to pull all immediate customer feedback. They then ask the agent to use `reply_comment` to draft responses to the top three questions, solving the immediate need for customer service.

### Content Library Audit
An operations specialist needs to check every piece of content ever posted. They use `get_media` to get the list of all media IDs, then loop through those IDs using `get_media_children` to ensure no assets (like old carousels) were missed. This solves the problem of an unindexed content library.

### Weekly Performance Report
A business owner wants a summary of the last week's content. They ask the agent to run `get_media` to list the posts, and then run `get_insights` for each one, compiling a single report on total reach and best-performing content.

### Emergency Comment Management
A PR crisis hits, and comments are piling up. The team uses `get_comments` to list all recent negative feedback, then uses `delete_comment` to remove spam or inappropriate comments, and finally uses `reply_comment` to issue a single, unified apology.

## Benefits

- Analyze deep post performance with `get_insights`. You get metrics like reach, impressions, and saves, not just likes. This lets you know if your content is actually reaching unique accounts.
- Keep your audience engaged by listing and replying to comments. Use `get_comments` and `reply_comment` to manage customer questions and maintain a high-touch brand presence instantly.
- Publish content without switching apps. Use `publish_photo` or `publish_reel` to dispatch media and captions directly from your agent, confirming the post before it goes live.
- Keep track of everything you've posted. `get_media` gives you a list of all recent media, while `get_media_children` pulls out all assets from a carousel.
- Audit your account status with `get_profile`. You instantly see follower counts, bio details, and your total post count without navigating to the profile tab.
- Prevent service downtime by running `refresh_token`. This tool extends your access token validity for another 60 days, keeping your workflow running.

## How It Works

The bottom line is, your agent becomes a single point of access to all your Instagram data and publishing functions.

1. First, you subscribe to the server and provide your Instagram Access Token and Business Account ID.
2. Next, your AI client (Claude, Cursor, etc.) connects to the Vinkius platform using the MCP standard.
3. Finally, you ask your agent to perform a task, like 'What was the reach of my last post?' The agent uses the correct tool to get the data and presents it to you.

## Frequently Asked Questions

**How do I use the `get_insights` tool to find a post's reach?**
You need to provide the `media_id` first. Once you have that ID (from `get_media`), the agent runs `get_insights`. This tool returns specific metrics like reach (unique accounts) and impressions (total views), which are key for measuring actual impact.

**Can I use `publish_reel` to post a photo instead?**
No. `publish_reel` requires the video URL and is designed specifically for Reels. Use `publish_photo` if you are posting a static image. Both tools require the URL to be publicly accessible HTTPS.

**How do I reply to a comment using the `reply_comment` tool?**
You must provide the specific `comment_id` you want to respond to. The agent then handles the API call, posting your reply directly to the comment thread.

**Does `get_media` give me all the performance data?**
No. `get_media` gives you basic counts (likes, comments). For detailed performance data, you have to use `get_insights` and supply the media ID.

**What is the difference between `get_comments` and `get_media_children`?**
These tools handle different things. `get_comments` pulls user comments from a post. `get_media_children` only retrieves the individual assets inside a carousel album.

**What do I need to use the `refresh_token` tool to keep my connection active?**
You must call `refresh_token` after the current access token has been active for at least 24 hours. The process extends the token's validity by another 60 days, and you'll need to update your credentials in Vinkius with the new token.

**If I use `publish_photo` or `publish_reel`, does it require specific credentials?**
Yes, both publishing tools require your account to be a Business or Creator account. Furthermore, the image or video URL must be publicly accessible via HTTPS. Remember that publishing is irreversible, so always confirm with your agent before running these tools.

**What information can I pull about my account using the `get_profile` tool?**
The `get_profile` tool retrieves core account details like your username, display name, biography, follower count, following count, post count, and website. It's useful for quick audits without needing to analyze specific media items.

**Can I publish a Reel using my AI agent?**
Yes. Use the `publish_reel` tool. You just need to provide a public URL for the video and your caption. Your agent will handle the container creation and final publishing to your Instagram Business profile instantly.

**How do I see performance metrics for a specific post?**
Ask your agent to `get_media_insights` for a specific Media ID. You'll receive deep metrics like reach, impressions, saved counts, and engagement rate directly in your chat interface.

**Can my agent help me respond to comments?**
Absolutely. Use the `get_media_comments` tool to list recent feedback, and then use `reply_to_comment` to send your response. This allows you to manage community interaction without opening the Instagram app.