instagram-account-mcp
v0.1.0MCP server to run and grow an Instagram professional account from Claude, Hermes, Cursor, Codex and any MCP client: reels, carousels, stories, scheduling…
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
auth_status Connection status
Show whether the Meta app is configured, which Instagram accounts are connected (and whether their sign-in is healthy), the default account, the login type, the media host, AI providers and Meta API usage. Call this first in a new conversation.
connect_account Connect an Instagram account
Start the Meta sign-in to connect (or reconnect) Instagram professional accounts. Opens the browser on this computer and returns the sign-in link. With Facebook Login the user selects the Facebook Page(s) their Instagram account is linked to; every linked account is connected. Waits up to wait_seconds for them to finish. If the browser lands on a page that does not load, ask the user to copy that page's full address and call complete_connect with it.
| Parameter | Type | Description |
|---|---|---|
open_browser | boolean | |
wait_seconds | integer | How long to wait for the sign-in to finish before returning. |
complete_connect Finish a sign-in with the callback URL
Finish a connect_account sign-in by giving the full URL the browser landed on after approving (it contains ?code=...&state=...). Use when the callback page did not load or the sign-in was done on another device.
| Parameter | Type | Description |
|---|---|---|
callback_url * | string | The full address-bar URL after approving, starting with http. |
list_accounts List connected accounts
List the Instagram accounts connected to this server.
get_profile Account profile
Live profile of a connected account: username, name, biography, website, followers, following, media count, profile picture.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
set_default_account Set the default account
Choose which connected account is used when a tool call does not name one.
| Parameter | Type | Description |
|---|---|---|
account * | string | @username or Instagram user ID. |
disconnect_account Disconnect an account
Remove a connected account from this server and delete its stored token. With revoke=true (Facebook Login) it also removes this app's permissions from the Facebook user. Scheduled posts for it stop. Needs the user's confirmation.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
revoke | boolean |
publish_photo Publish a photo post
Publish (or schedule) a single-image feed post. Images are converted to JPEG and fitted into Instagram's 4:5 to 1.91:1 range automatically. Needs the user's confirmation. Runs in the background; follow get_publish_status.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
alt_text | string | Accessibility description (max 1,000 characters). |
caption | string | Caption (max 2,200 characters, 30 hashtags, 20 @mentions). The first ~125 characters show before 'more'. Captions can't be edited through the API after publishing. |
collaborators | array | Up to 3 usernames invited as collaborators (they must accept in the app). |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
file_path | string | Path to the file on this computer, e.g. ~/Pictures/launch.jpg. |
first_comment | string | Posted as the first comment right after publishing (hashtags, credits, links). |
fit | string | Reframing when converting: keep (only clamp into the allowed range), crop (fill the frame from the centre) or blur (whole frame over a blurred fill). Reels/stories target 9:16. |
is_ai_generated | boolean | Self-disclose that the content was made or edited with AI (shows an AI label). |
location_id | string | Facebook Page ID of a place (see find_location). |
prepare | boolean | Convert to Instagram's specs with ffmpeg first (JPEG, H.264/AAC MP4, allowed aspect ratio and length). Default true. |
publish_at | string | Schedule: ISO 8601 date-time with timezone, at least 10 minutes and at most 75 days ahead. Instagram has no API scheduling, so this computer (or the background service) publishes it then; if the compu… |
template | string | Template from list_templates: adds header/footer, hashtags, first comment, collaborators. |
url | string | Public http(s) URL of the file instead of a local path. |
user_tags | array | People to tag in the media. |
wait_seconds | integer | Wait this long for publishing before returning; then follow get_publish_status. |
publish_reel Publish a reel
Publish (or schedule) a reel: 3 seconds to 15 minutes, up to 300 MB, 9:16 fills the screen (fit: crop or blur reframes other shapes). Converted to H.264/AAC MP4 when needed. Licensed music can't be added through the API. Needs the user's confirmation; runs in the background.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
audio_name | string | Name for the reel's original audio. |
caption | string | Caption (max 2,200 characters, 30 hashtags, 20 @mentions). The first ~125 characters show before 'more'. Captions can't be edited through the API after publishing. |
collaborators | array | Up to 3 usernames invited as collaborators (they must accept in the app). |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
cover_file | string | Custom cover image for the reels tab and grid (9:16 looks best). |
cover_url | string | Cover image URL instead of cover_file. |
file_path | string | Path to the file on this computer, e.g. ~/Pictures/launch.jpg. |
first_comment | string | Posted as the first comment right after publishing (hashtags, credits, links). |
fit | string | Reframing when converting: keep (only clamp into the allowed range), crop (fill the frame from the centre) or blur (whole frame over a blurred fill). Reels/stories target 9:16. |
is_ai_generated | boolean | Self-disclose that the content was made or edited with AI (shows an AI label). |
location_id | string | Facebook Page ID of a place (see find_location). |
prepare | boolean | Convert to Instagram's specs with ffmpeg first (JPEG, H.264/AAC MP4, allowed aspect ratio and length). Default true. |
publish_at | string | Schedule: ISO 8601 date-time with timezone, at least 10 minutes and at most 75 days ahead. Instagram has no API scheduling, so this computer (or the background service) publishes it then; if the compu… |
share_to_feed | boolean | Also show the reel in the profile grid and feed (Instagram's default is yes). |
template | string | Template from list_templates: adds header/footer, hashtags, first comment, collaborators. |
thumb_offset_ms | integer | Use the frame at this time (ms) as the cover when no cover image is given. |
url | string | Public http(s) URL of the file instead of a local path. |
user_tags | array | People to tag in the reel. |
wait_seconds | integer | Wait this long for publishing before returning; then follow get_publish_status. |
publish_trial_reel Publish a trial reel
Publish a trial reel: Instagram shows it to non-followers first, so you can test an idea without your followers seeing it. graduation SS_PERFORMANCE lets Instagram share it with followers automatically if it performs well; MANUAL keeps it trial-only until you share it yourself in the Instagram app (the API has no call to graduate a trial reel). For comparing several versions, use create_ab_test. Needs confirmation.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
audio_name | string | Name for the reel's original audio. |
caption | string | Caption (max 2,200 characters, 30 hashtags, 20 @mentions). The first ~125 characters show before 'more'. Captions can't be edited through the API after publishing. |
collaborators | array | Up to 3 usernames invited as collaborators (they must accept in the app). |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
cover_file | string | Custom cover image for the reels tab and grid (9:16 looks best). |
cover_url | string | Cover image URL instead of cover_file. |
file_path | string | Path to the file on this computer, e.g. ~/Pictures/launch.jpg. |
first_comment | string | Posted as the first comment right after publishing (hashtags, credits, links). |
fit | string | Reframing when converting: keep (only clamp into the allowed range), crop (fill the frame from the centre) or blur (whole frame over a blurred fill). Reels/stories target 9:16. |
graduation | string | MANUAL: you decide in the app. SS_PERFORMANCE: Instagram shares it to followers if it does well. |
is_ai_generated | boolean | Self-disclose that the content was made or edited with AI (shows an AI label). |
location_id | string | Facebook Page ID of a place (see find_location). |
prepare | boolean | Convert to Instagram's specs with ffmpeg first (JPEG, H.264/AAC MP4, allowed aspect ratio and length). Default true. |
publish_at | string | Schedule: ISO 8601 date-time with timezone, at least 10 minutes and at most 75 days ahead. Instagram has no API scheduling, so this computer (or the background service) publishes it then; if the compu… |
share_to_feed | boolean | Also show the reel in the profile grid and feed (Instagram's default is yes). |
template | string | Template from list_templates: adds header/footer, hashtags, first comment, collaborators. |
thumb_offset_ms | integer | Use the frame at this time (ms) as the cover when no cover image is given. |
url | string | Public http(s) URL of the file instead of a local path. |
user_tags | array | People to tag in the reel. |
wait_seconds | integer | Wait this long for publishing before returning; then follow get_publish_status. |
publish_carousel Publish a carousel
Publish (or schedule) a carousel of 2 to 20 images and/or videos (videos 3-60 s). Instagram crops every item to the first item's shape; use fit to control reframing. Alt text and user tags per image. Needs the user's confirmation; runs in the background.
| Parameter | Type | Description |
|---|---|---|
items * | array | The slides, in order. |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
caption | string | Caption (max 2,200 characters, 30 hashtags, 20 @mentions). The first ~125 characters show before 'more'. Captions can't be edited through the API after publishing. |
collaborators | array | Up to 3 usernames invited as collaborators (they must accept in the app). |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
first_comment | string | Posted as the first comment right after publishing (hashtags, credits, links). |
fit | string | Reframing when converting: keep (only clamp into the allowed range), crop (fill the frame from the centre) or blur (whole frame over a blurred fill). Reels/stories target 9:16. |
is_ai_generated | boolean | Self-disclose that the content was made or edited with AI (shows an AI label). |
location_id | string | Facebook Page ID of a place (see find_location). |
prepare | boolean | Convert to Instagram's specs with ffmpeg first (JPEG, H.264/AAC MP4, allowed aspect ratio and length). Default true. |
publish_at | string | Schedule: ISO 8601 date-time with timezone, at least 10 minutes and at most 75 days ahead. Instagram has no API scheduling, so this computer (or the background service) publishes it then; if the compu… |
template | string | Template from list_templates: adds header/footer, hashtags, first comment, collaborators. |
wait_seconds | integer | Wait this long for publishing before returning; then follow get_publish_status. |
publish_story Publish a story
Publish (or schedule) a story from an image or a video (3-60 s, up to 100 MB). Stories last 24 hours. Stickers, links, polls and music can't be added through the API. Needs the user's confirmation.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
file_path | string | Path to the file on this computer, e.g. ~/Pictures/launch.jpg. |
fit | string | Reframing when converting: keep (only clamp into the allowed range), crop (fill the frame from the centre) or blur (whole frame over a blurred fill). Reels/stories target 9:16. |
prepare | boolean | Convert to Instagram's specs with ffmpeg first (JPEG, H.264/AAC MP4, allowed aspect ratio and length). Default true. |
publish_at | string | Schedule: ISO 8601 date-time with timezone, at least 10 minutes and at most 75 days ahead. Instagram has no API scheduling, so this computer (or the background service) publishes it then; if the compu… |
type | string | Only needed when the file name does not tell. |
url | string | Public http(s) URL of the file instead of a local path. |
user_tags | array | People to tag in the media. |
wait_seconds | integer | Wait this long for publishing before returning; then follow get_publish_status. |
get_publish_status Publishing status
Status of a publishing job: each item's progress (preparing, uploading %, processing), errors with fixes, and the permalink once published. Can wait for changes.
| Parameter | Type | Description |
|---|---|---|
job_id * | string | |
wait_seconds | integer | Wait up to this long for it to finish. |
list_scheduled Scheduled and recent posts
Upcoming scheduled posts (soonest first), posts being published or waiting, and recent results from this computer.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
recent | integer | How many finished jobs to include. |
reschedule Reschedule a post
Move a scheduled, waiting or missed (computer was off) post to a new time. Needs the user's confirmation.
| Parameter | Type | Description |
|---|---|---|
job_id * | string | |
publish_at * | string | New ISO 8601 date-time with timezone (10 minutes to 75 days ahead). |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
cancel_scheduled Cancel a scheduled or unfinished post
Stop a post that has not been published yet (scheduled, waiting or in progress). Hosted copies are removed. Can be undone with resume_publish. Needs the user's confirmation.
| Parameter | Type | Description |
|---|---|---|
job_id * | string | |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
resume_publish Retry or resume a post
Retry a failed post, continue one paused on an expired sign-in, re-check one waiting for the publishing limit, restore a cancelled one, or publish one that missed its scheduled time (computer was off) right now. Cancelled and missed posts need the user's confirmation again. If a publish may already have gone through, it checks Instagram first and never publishes twice.
| Parameter | Type | Description |
|---|---|---|
job_id * | string | |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
wait_seconds | integer |
prepare_media Check (and convert) media for Instagram
Inspect an image or video and list what Instagram would reject for a placement (format, codec, aspect ratio, length, size). With convert=true, writes a fixed copy (JPEG / H.264+AAC MP4, reframed with fit) and returns its path. Publishing tools do this automatically. Needs ffmpeg.
| Parameter | Type | Description |
|---|---|---|
file_path * | string | Image or video on this computer. |
kind * | string | Where it will be posted. |
convert | boolean | Write a converted copy when needed. |
fit | string |
publish_budget Publishing limit
How many API posts are left in Instagram's rolling 24-hour window (Meta's limit; carousels count once), plus posts scheduled for the next 24 hours.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
media_host_status Media host status
How local files reach Instagram, and whether it works: tunnel (Cloudflare quick tunnel from this computer), s3 (S3/R2/B2 bucket) or azure (Blob Storage). Facebook-Login accounts upload videos straight to Meta; images always go through the host.
| Parameter | Type | Description |
|---|---|---|
host | string | Check a specific host instead of the active one. |
find_location Find a location ID
Instagram location tags use the Facebook Page ID of a place. Pass a Facebook Page URL or ID to check it (Facebook Login accounts), or a search query (needs Meta's Page Public Metadata Access, which most apps don't have; then look the place up on facebook.com and pass its Page URL).
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
page | string | Facebook Page URL, username or numeric ID of the place. |
query | string | Place name to search for. |
list_media List posts and reels
The account's published posts, reels and carousels, newest first: id, type, caption (shortened), link, time, likes and comments. Use get_media for one post in full and get_media_insights for its numbers.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
limit | integer | |
since | string | Only posts on or after this date (YYYY-MM-DD or ISO). |
type | string | FEED = photos and carousels, REELS = reels; or a media type. |
until | string | Only posts on or before this date. |
get_media Get one post
Full details of one post, reel or carousel: caption, media and thumbnail URLs, link, counts, whether comments are on, and carousel items.
| Parameter | Type | Description |
|---|---|---|
media_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
list_stories List live stories
Stories currently live (the last 24 hours). Story insights also disappear after 24 hours.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
list_tagged Posts that tagged you
Media where other accounts tagged this account (photo tags), newest first.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
limit | integer |
toggle_comments Turn comments on or off
Enable or disable comments on one of your posts. Visible to everyone, so the user confirms first. (Captions cannot be edited through Meta's API.)
| Parameter | Type | Description |
|---|---|---|
enabled * | boolean | |
media_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
delete_media Delete a post
Permanently delete a post, reel, story or whole carousel (single carousel items cannot be deleted). Only for accounts connected with Facebook Login (Meta's rule). Cannot be undone; the user confirms first.
| Parameter | Type | Description |
|---|---|---|
media_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
list_comments List comments
Comments with their replies, for one post (media_id) or across the most recent posts. Each comment says whether you already answered. Use unanswered: true to build a reply queue; triage_comments sorts them by priority.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
hidden | boolean | true = only hidden comments, false = only visible ones. |
media_id | string | One post. Omit to scan recent posts. |
per_post | integer | |
posts | integer | How many recent posts to scan (no media_id). |
since | string | Only comments on or after this date. |
unanswered | boolean | Only comments you have not replied to. |
reply_to_comment Reply to a comment
Public reply under a top-level comment (Meta does not allow replying to replies or to hidden comments). The user confirms first.
| Parameter | Type | Description |
|---|---|---|
comment_id * | string | |
message * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
comment_on_media Comment on a post
Add a new top-level comment on one of your posts (e.g. a pinned-style note or first comment). Public; the user confirms first.
| Parameter | Type | Description |
|---|---|---|
media_id * | string | |
message * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
hide_comment Hide or unhide a comment
Hide a comment from everyone except its author (or show it again with hide: false). The user confirms first.
| Parameter | Type | Description |
|---|---|---|
comment_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
hide | boolean |
delete_comment Delete a comment
Permanently delete a comment on your post (yours or someone else's). Prefer hide_comment unless it must go. Cannot be undone; the user confirms first.
| Parameter | Type | Description |
|---|---|---|
comment_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
private_reply DM someone who commented
Send one private Direct message to the person who wrote a comment (e.g. the link they asked for). One message per comment, within 7 days of it. The user confirms first.
| Parameter | Type | Description |
|---|---|---|
comment_id * | string | |
message * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
list_mentions Mentions and tags
Where others mention this account: posts that tagged it, newest first. With comment_id or media_id (from a mention notification) it returns that specific @mention.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
comment_id | string | A comment that @mentioned you. |
limit | integer | |
media_id | string | A post whose caption @mentioned you. |
list_conversations List Direct conversations
Recent Instagram Direct conversations: who, their last message, and whether you can still reply (Instagram allows replies for 24 hours after their last message).
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
limit | integer | |
user_id | string | Only the conversation with this Instagram-scoped user ID. |
get_conversation Read a conversation
Messages in one Direct conversation, newest first (Meta returns details for the 20 most recent).
| Parameter | Type | Description |
|---|---|---|
conversation_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
limit | integer |
send_dm Send a Direct message
Reply in Instagram Direct to someone who messaged this account. Allowed only within 24 hours of their last message (7 days with human_agent if your Meta app has the Human Agent feature). Text up to 1000 bytes. The user confirms first.
| Parameter | Type | Description |
|---|---|---|
message * | string | |
recipient_id * | string | Their Instagram-scoped ID (with_id from list_conversations). |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
human_agent | boolean | Use the HUMAN_AGENT tag (needs Meta approval of the Human Agent feature). |
get_media_insights Post insights
Lifetime numbers for posts, reels or stories: views, reach, likes, comments, saves, shares, total interactions, follows, profile visits; reels add average watch time (ms), total watch time and skip rate; stories add navigation and replies. Give media_ids, or omit them for the latest posts. Story insights vanish after 24 hours and need 5+ viewers.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
latest | integer | Without media_ids: how many recent posts. |
media_ids | array |
get_account_insights Account insights
Account-level numbers. Presets: overview (last N days totals: reach, views, accounts engaged, interactions, likes, comments, saves, shares, follows/unfollows, link taps), daily (reach per day), reach_breakdown (by reels/posts/stories and followers vs non-followers), follows (follows vs unfollows). Or set metrics yourself (reach, views, accounts_engaged, total_interactions, likes, comments, saves, shares, replies, reposts, follows_and_unfollows, profile_links_taps) with period, metric_type, breakdown and since/until (max 30 days).
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
breakdown | string | e.g. media_product_type, follow_type, follower_type, contact_button_type |
days | integer | For presets: how many days back. |
metric_type | string | |
metrics | array | Custom metrics (ignored when preset is set). |
period | string | |
preset | string | |
since | string | YYYY-MM-DD |
until | string | YYYY-MM-DD |
get_audience Audience demographics
Who your followers (or the people who engaged) are: age, gender, country and city, with shares in %. Needs at least 100 followers; Meta returns the top 45 values per breakdown.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
breakdowns | array | |
timeframe | string | |
top | integer | |
who | string |
export_insights Export post insights to CSV
Writes a CSV (one row per post: date, type, link, caption, views, reach, likes, comments, saves, shares, interactions, follows, profile visits, reel watch time, skip rate) for spreadsheets. Saved in the data folder's exports/ (a bare file name goes there too). Writing anywhere else needs the user's approval. Never overwrites a file: a -1, -2... suffix is added.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
limit | integer | How many recent posts. |
path | string | File name (saved in exports/), or an absolute / ~/ path (needs approval). |
since | string | |
until | string |
analyze_post Analyze a post
How one post, reel or story did against your own recent posts of the same format: outlier score (views vs your median), engagement rate, saves+shares per viewer, reel watch time and skip rate, and plain-language notes. With an AI provider it adds a diagnosis and next steps; without one it returns a brief so you can write it.
| Parameter | Type | Description |
|---|---|---|
media_id * | string | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
baseline_posts | integer | |
diagnose | boolean | Ask the configured AI model for a diagnosis. |
find_outliers Find outlier posts
Your best and worst recent posts relative to your own median on one metric (views, reach, shares, saved, total_interactions, engagement_rate, save_share_rate, follows...). Shows what to repeat and what to drop.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
metric | string | |
posts | integer | |
top | integer | |
type | string | Compare within one format (recommended). |
best_publish_time Best time to publish
When your own posts performed best, by weekday and 3-hour block in your time zone (each post scored against your median, so one viral post does not decide), plus when followers are online if Meta provides it.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
metric | string | |
posts | integer | |
time_zone | string | IANA zone such as Asia/Kolkata. Default: this computer's zone. |
type | string |
hashtag_research Research hashtags
For each hashtag: top (or most recent) public posts, their median likes and comments, format mix, related hashtags people use with it, and example posts. Instagram allows 30 different hashtags per 7 days per account (repeats are free); the remaining budget is shown. Facebook Login accounts only.
| Parameter | Type | Description |
|---|---|---|
hashtags * | array | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
edge | string | |
limit | integer | Posts sampled per hashtag. |
hashtag_budget Hashtag search budget
How many of the 30 hashtag searches per rolling 7 days are left, and which hashtags can be repeated for free.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
benchmark_competitor Benchmark another account
Public stats of any Business or Creator account (Meta's Business Discovery): followers, posting frequency, format mix, median likes/comments/views, engagement per follower, top hashtags and top posts. Compare with your own using get_account_insights. Facebook Login accounts only.
| Parameter | Type | Description |
|---|---|---|
username * | string | Their @username. |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
posts | integer |
create_ab_test A/B test reels with trial reels
Publishes 2-4 versions of a reel (different hook, cut, caption or cover) as trial reels at the same time. Instagram shows trial reels to non-followers first, so each version gets a comparable audience without spamming followers. After decide_after_hours (default 48, 12-168) the background service compares them on the chosen metric with a significance test and reports a winner or "inconclusive". Meta's API cannot graduate trial reels: you share the winner to followers in the Instagram app; with share_winner: "republish" this server instead republishes the winning version as a normal reel. Versi…
| Parameter | Type | Description |
|---|---|---|
variants * | array | |
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
decide_after_hours | integer | |
graduation | string | MANUAL: you decide in the app. SS_PERFORMANCE: Instagram may share a well-performing version to followers by itself. |
hypothesis | string | |
metric | string | views or reach (Poisson test), shares / saves / engagement_rate (per reach, two-proportion test), avg_watch_time (directional only). |
publish_at | string | ISO 8601 date-time with timezone to publish all versions, 10 minutes to 75 days ahead (default now). |
share_winner | string | republish: post a clear winner again as a normal reel automatically. |
stagger_minutes | integer | |
template | string | Caption template applied to every version. |
get_ab_test A/B test status and results
Shows an A/B test: each version's publishing status, link and latest metrics, the decision time, and (when finished) the verdict with confidence and next step. refresh: true pulls current numbers from Instagram before the decision.
| Parameter | Type | Description |
|---|---|---|
test_id * | string | |
refresh | boolean |
list_ab_tests List A/B tests
All A/B tests, newest first, optionally filtered by status.
| Parameter | Type | Description |
|---|---|---|
status | string |
stop_ab_test Stop an A/B test
Stops a test: versions not yet published are cancelled and no decision is made. Trial reels already published stay up (delete them with delete_media or in the app).
| Parameter | Type | Description |
|---|---|---|
test_id * | string | |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |
ai_status AI providers and models
Which AI providers are connected (Claude, OpenAI, Azure OpenAI, Gemini, OpenRouter, Groq, Ollama, custom) and which model each job uses: text (captions, analysis), vision (covers, images), image, transcribe. Keys are never shown.
set_ai_models Choose AI models
Pick which connected provider and model handle each job, as "provider:model" (Azure: "azure:<deployment>"), e.g. text "anthropic:claude-opus-5-5", vision "openai:gpt-5.5", transcribe "groq:whisper-large-v3". Pass null to go back to the automatic choice.
| Parameter | Type | Description |
|---|---|---|
effort | string | Reasoning effort for Claude and OpenAI reasoning models (default medium). |
image | string | null | |
text | string | null | |
transcribe | string | null | |
vision | string | null |
generate_caption Write caption options
Drafts caption options (hook first line, short body, call to action, hashtags, and on-screen hook text for reels) from a description, a transcript file, or the media file itself (images are looked at; videos are transcribed when a transcription model is connected). Applies the template and checks Instagram's limits. Drafts only: nothing is published. Without an AI model it returns a brief so you write them.
| Parameter | Type | Description |
|---|---|---|
count | integer | |
description | string | What the post is about, key points, audience. |
file_path | string | The image or video to be posted. |
format | string | |
language | string | |
notes | string | |
template | string | |
transcript_path | string |
generate_hashtags Suggest hashtags
Suggests a hashtag set for a post: a mix of broad, niche, community, branded and location tags with reasons, the 5-10 to actually use, and tags to avoid. AI-based; for live data on how active a hashtag is use hashtag_research (Facebook Login only, 30 hashtags per 7 days).
| Parameter | Type | Description |
|---|---|---|
topic * | string | |
caption | string | |
count | integer | |
template | string |
suggest_carousel Plan a carousel
Turns text, an article, notes or a transcript into a carousel outline: slide-by-slide headline, body and visual (up to 20 slides), plus caption and hashtags. Design the slides from it, then publish with publish_carousel.
| Parameter | Type | Description |
|---|---|---|
audience | string | |
slides | integer | |
source_path | string | .txt, .md, .srt or .vtt file |
template | string | |
text | string |
critique_cover Judge and rank covers
Scores 1-4 cover images (or 4 frames taken from a video) the way people see them: full screen in the reels feed and as a small grid tile. Ranks them and lists fixes. Needs a vision model (Claude, OpenAI, Gemini, Azure).
| Parameter | Type | Description |
|---|---|---|
context * | string | What the post is about. |
image_paths | array | |
video_path | string | Take candidate frames from this video instead. |
translate_caption Translate a caption
Drafts the caption in other languages, keeping the hook, @mentions, #hashtags and links. Drafts only.
| Parameter | Type | Description |
|---|---|---|
caption * | string | |
languages * | array | BCP-47 codes, e.g. ["hi", "es"] |
caption_check Check a caption
Checks a caption against Instagram's limits (2,200 characters, 30 hashtags, 20 @mentions) and craft rules (hook length before "more", call to action, hashtag count, links, engagement bait), and previews it with a template applied exactly as it will be published.
| Parameter | Type | Description |
|---|---|---|
caption * | string | |
template | string |
repurpose_video Cut reels from a long video
Finds the best standalone moments in a long local video (transcribed, or from a transcript file) and cuts them into vertical 1080x1920 reels with a hook, on-screen text and caption for each. Or pass clips with start/end seconds to cut exactly those. layout crop fills the frame from the centre; blur fits the whole frame over a blurred fill. Returns file paths ready for publish_reel. Needs ffmpeg.
| Parameter | Type | Description |
|---|---|---|
file_path * | string | |
clips | array | |
count | integer | |
cut | boolean | false: only suggest clips, don't render them. |
layout | string | |
max_seconds | integer | |
min_seconds | integer | |
template | string | |
transcript_path | string |
content_ideas What to post next
Next post ideas grounded in this account's recent performance: which formats and topics over- and under-performed (likes and comments vs the account's median), optionally focused on a topic. With an AI model it returns ideas with format, hook, angle, evidence and confidence; otherwise the data for you to reason from.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
count | integer | |
focus | string | A theme, product or audience to focus on. |
posts | integer | |
template | string |
triage_comments Sort comments and draft replies
Reads recent comments (one post, or the latest posts) and sorts them: questions, praise, feedback, complaints, leads, spam, abuse. Each gets a priority, a suggested action (reply, private reply, hide, delete) and a draft reply, plus post ideas the audience is asking for. Drafts only: nothing is sent. Without an AI model it returns the comments for you to triage.
| Parameter | Type | Description |
|---|---|---|
account | string | Which connected account: @username or Instagram user ID. Omit to use the default account. |
max_comments | integer | |
media_id | string | |
posts | integer | Latest posts to read when no media_id. |
template | string | Template whose voice the replies should follow. |
unanswered_only | boolean |
list_templates List caption templates
Caption templates: header/footer, hashtags (in the caption or first comment), mentions, first comment, collaborators, location and the account voice used by the writing tools. Saved as JSON in the templates folder.
save_template Save a caption template
Creates or replaces a caption template. Use extends to build on another template (hashtags, mentions and collaborators are merged; guidance is appended).
| Parameter | Type | Description |
|---|---|---|
name * | string | |
caption_footer | string | |
caption_header | string | |
collaborators | array | |
description | string | |
extends | string | |
first_comment | string | |
guidance | string | |
hashtags | array | |
hashtags_in | string | |
is_ai_generated | boolean | |
location_id | string | |
mentions | array |
delete_template Delete a caption template
Deletes a saved template file. Asks the user first.
| Parameter | Type | Description |
|---|---|---|
name * | string | |
confirmation_token | string | Only after the user approved: the confirmation_token returned by the previous call with identical arguments. |