Instagram MCP server for AI agents

Let Claude, ChatGPT or your own agent read and act on Instagram: 24 typed functions through one MCP server. No Instagram API key needed.

Functions
24
Sign-in
For account actions
Works with
MCP, HTTP, Node, Python

Connect

Just Instagram

An MCP server for Instagram alone, with one tool per function. Paste it into Claude, ChatGPT, Cursor or any MCP client as a remote server.

https://api.bowmark.ai/mcp/site/instagram
Every site

One MCP server for Instagram and every other site Bowmark covers. Your agent looks up what it needs and calls it.

https://api.bowmark.ai/mcp
Set it up in your client

Both need a Bowmark API key. The quickstart gets you one and a first result in a few minutes. Functions that need a login use the person's own account: how sign-in works.

Functions

Open a function to see its arguments, what it returns and how to call it.

Read 11
  • getDirectMessagesLists the signed-in user's direct message threads with preview of the latest message in each.

    Arguments

    None.

    Returns InstagramDirectMessageThread[]

    interface InstagramDirectMessageThread {
      id: string;
      recipientUsername: string;
      recipientId: string;
      lastMessageText: string | null;
      lastMessageTimestamp: string | null;
      isSpamThread: boolean;
      title?: string | null; // group name, else the participants' usernames
      participants?: { id: string; username: string; fullName: string | null }[];
      isGroup?: boolean;
      isUnread?: boolean | null;
      isPinned?: boolean;
      lastActivityAt?: string | null;
      url?: string | null; // https://www.instagram.com/direct/t/<thread_key>/
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getDirectMessages

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getDirectMessages();
  • getFeedReads the public posts behind an Instagram hashtag, keyword or location URL, without a login, in the same post shape as getPost.

    Arguments

    NameTypeRequired
    inputstring | { url?: string; hashtag?: string; keyword?: string; locationId?: string }Yes

    Returns InstagramFeed

    interface InstagramMediaPost {
      id: string;
      shortcode: string;
      url: string;
      permalink: string;
      type: "image" | "video" | "carousel" | "reel" | null;
      isVideo: boolean | null;
      postedAt: string | null; // ISO 8601
      caption: string | null;
      hashtags: string[]; // without "#"
      mentions: string[]; // without "@"
      owner: { id: string | null; username: string | null } | null;
      likeCount: number | null;
      commentCount: number | null;
      viewCount: number | null; // plays; null for images
      videoDurationSeconds: number | null;
      thumbnailUrl: string | null;
      displayUrl: string | null;
      videoUrl: string | null; // signed CDN link, expires
      taggedUsers: string[];
      collaborators: string[];
      location: { id: string; name: string | null } | null;
      isPaidPartnership: boolean | null;
      sponsors: string[];
    }
    
    interface InstagramPlace {
      id: string;
      name: string | null;
      slug: string | null;
      category: string | null;
      postCount: number | null;
      lat: number | null;
      lng: number | null;
      address: string | null;
      city: string | null;
      zipCode: string | null;
      phone: string | null;
    }
    
    interface InstagramFeed {
      source: { kind: "hashtag" | "keyword" | "location"; value: string; url: string };
      posts: InstagramMediaPost[];
      sections: { keyword: string; url: string; posts: InstagramMediaPost[] }[];
      relatedKeywords: string[];
      location: InstagramPlace | null; // location feeds
      hasNextPage: boolean | null;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getFeed

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getFeed("<input>");
  • getHomeFeedReads the signed-in user's home feed.

    Arguments

    None.

    Returns InstagramHomeFeed

    interface InstagramPost {
      id: string;
      shortcode: string;
      permalink: string;
      isVideo: boolean;
      displayUrl: string;
      caption: string | null;
      likeCount: number;
      commentCount: number;
      takenAt: string;
    }
    
    interface InstagramHomeFeedPost extends InstagramPost {
      authorUsername: string;
      authorId: string;
    }
    
    interface InstagramHomeFeed {
      posts: InstagramHomeFeedPost[];
      hasNextPage: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getHomeFeed

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getHomeFeed();
  • getNotificationsReads the signed-in user's activity feed.

    Arguments

    None.

    Returns InstagramNotification[]

    interface InstagramNotification {
      id: string;
      type: "like" | "comment" | "follow" | "mention" | "tag" | "message" | "other";
      senderUsername: string;
      senderId: string;
      senderProfilePicUrl: string | null;
      actionText: string;
      mediaId: string | null;
      mediaUrl: string | null;
      timestamp: string | null;
      isViewed: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getNotifications

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getNotifications();
  • getPostReads one public Instagram post or reel by URL (/p/, /reel/, /reels/, /tv/) or shortcode, without a login: type, caption, hashtags, mentions, owner…

    Arguments

    NameTypeRequired
    inputstring | { url?: string; shortcode?: string }Yes

    Returns InstagramPostDetail

    interface InstagramMediaPost {
      id: string;
      shortcode: string;
      url: string;
      permalink: string;
      type: "image" | "video" | "carousel" | "reel" | null;
      isVideo: boolean | null;
      postedAt: string | null; // ISO 8601
      caption: string | null;
      hashtags: string[]; // without "#"
      mentions: string[]; // without "@"
      owner: { id: string | null; username: string | null } | null;
      likeCount: number | null;
      commentCount: number | null;
      viewCount: number | null; // plays; null for images
      videoDurationSeconds: number | null;
      thumbnailUrl: string | null;
      displayUrl: string | null;
      videoUrl: string | null; // signed CDN link, expires
      taggedUsers: string[];
      collaborators: string[];
      location: { id: string; name: string | null } | null;
      isPaidPartnership: boolean | null;
      sponsors: string[];
    }
    
    interface InstagramMediaItem {
      type: "image" | "video";
      imageUrl: string | null;
      videoUrl: string | null;
      width: number | null;
      height: number | null;
      shortcode: string | null;
    }
    
    interface InstagramComment {
      id: string;
      text: string | null;
      createdAt: string | null;
      likeCount: number | null;
      replyCount: number | null;
      author: { id: string; username: string; isVerified: boolean; profilePicUrl: string | null };
    }
    
    interface InstagramPostDetail extends InstagramMediaPost {
      media: InstagramMediaItem[]; // the image/video, or every carousel slide
      comments: InstagramComment[]; // top public comments; commentCount is the total
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getPost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getPost("<input>");
  • getPostsReads the most recent posts on one public Instagram profile.

    Arguments

    NameTypeRequired
    usernamestringYes

    Returns InstagramPost[]

    interface InstagramPost {
      id: string;
      shortcode: string;
      permalink: string;
      isVideo: boolean;
      displayUrl: string;
      caption: string | null;
      likeCount: number;
      commentCount: number;
      takenAt: string;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getPosts

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getPosts("nasa");
  • getProfileReads one public Instagram profile without a login: full name, biography, bio links, pronouns, verified/private flags, profile picture, follower and…

    Arguments

    NameTypeRequired
    usernamestringYes

    Returns InstagramProfileDetail

    interface InstagramProfile {
      id: string;
      username: string;
      fullName: string;
      biography: string | null;
      externalUrl: string | null;
      isPrivate: boolean;
      isVerified: boolean;
      profilePicUrl: string;
      followerCount: number;
      followingCount: number | null;
      postCount: number | null; // read off the profile embed when the GraphQL root carries none; null only when both fail
    }
    
    interface InstagramProfileDetail extends InstagramProfile {
      bioLinks: { url: string; title: string | null }[];
      pronouns: string[];
      highlightCount: number | null;
      isBusinessAccount: boolean | null; // always null: not served logged out
      isProfessionalAccount: boolean | null; // always null: not served logged out
      category: string | null; // always null: not served logged out
      businessAddress: { street: string | null; city: string | null; zipCode: string | null; latitude: number | null; longitude: number | null } | null; // always null
      similarAccounts: { id: string; username: string; fullName: string | null; isVerified: boolean; profilePicUrl: string | null }[]; // always []: needs a session
      latestPosts: InstagramMediaPost[]; // 12 newest, pinned first; counts null (the grid carries none)
      warnings?: string[];
    }
    
    interface InstagramMediaPost {
      id: string;
      shortcode: string;
      url: string;
      permalink: string;
      type: "image" | "video" | "carousel" | "reel" | null;
      isVideo: boolean | null;
      postedAt: string | null; // ISO 8601
      caption: string | null;
      hashtags: string[]; // without "#"
      mentions: string[]; // without "@"
      owner: { id: string | null; username: string | null } | null;
      likeCount: number | null;
      commentCount: number | null;
      viewCount: number | null; // plays; null for images
      videoDurationSeconds: number | null;
      thumbnailUrl: string | null;
      displayUrl: string | null;
      videoUrl: string | null; // signed CDN link, expires
      taggedUsers: string[];
      collaborators: string[];
      location: { id: string; name: string | null } | null;
      isPaidPartnership: boolean | null;
      sponsors: string[];
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getProfile

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getProfile("nasa");
  • getSavedPostsLists the signed-in user's saved posts with post metadata including media, captions, and engagement counts.

    Arguments

    None.

    Returns InstagramSavedPosts

    interface InstagramPost {
      id: string;
      shortcode: string;
      permalink: string;
      isVideo: boolean;
      displayUrl: string;
      caption: string | null;
      likeCount: number;
      commentCount: number;
      takenAt: string;
    }
    
    interface InstagramSavedPost extends InstagramPost {
      authorUsername: string;
      authorId: string;
      collectionName: string | null;
    }
    
    interface InstagramSavedPosts {
      posts: InstagramSavedPost[];
      hasNextPage: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getSavedPosts

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getSavedPosts();
  • getStoriesLists stories from accounts the signed-in user follows, with expiration times.

    Arguments

    None.

    Returns InstagramStory[]

    interface InstagramStory {
      id: string;
      ownerUsername: string;
      ownerId: string;
      mediaUrl: string;
      isVideo: boolean;
      expiresAt: string | null;
      hasBeenSeen: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getStories

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getStories();
  • getThreadMessagesReads the message history for one direct message thread, including sent and received messages with timestamps.

    Arguments

    NameTypeRequired
    threadIdstringYes

    Returns InstagramDirectMessage[]

    interface InstagramDirectMessage {
      id: string;
      senderUsername: string;
      senderId: string;
      text: string | null;
      timestamp: string | null;
      isUnsent: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/getThreadMessages

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.getThreadMessages("123");
  • searchAccountsSearches Instagram for public accounts matching a query (username, full name, or display name).

    Arguments

    NameTypeRequired
    querystringYes

    Returns InstagramAccountSearchResult[]

    interface InstagramAccountSearchResult {
      id: string;
      username: string;
      fullName: string;
      isPrivate: boolean;
      isVerified: boolean;
      profilePicUrl: string | null;
      followerCount: number | null;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/searchAccounts

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.searchAccounts("nasa");
Act 13
  • blockUserBlocks a user, preventing them from seeing the signed-in account's posts and sending it messages.

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramBlockResult

    interface InstagramBlockResult {
      userId: string;
      username: string;
      blocking: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/blockUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.blockUser("<userId>");
  • commentOnPostPosts a comment on a photo or video by its media id.

    Arguments

    NameTypeRequired
    mediaIdstringYes
    commentTextstringYes

    Returns InstagramCommentResult

    interface InstagramCommentResult {
      commentId: string;
      mediaId: string;
      text: string;
      timestamp: string | null;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/commentOnPost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.commentOnPost("<mediaId>", "<commentText>");
  • followUserFollows a user. For public accounts, follows immediately; for private accounts, sends a follow request. Requires the caller to be signed in through…

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramFollowResult

    interface InstagramFollowResult {
      userId: string;
      username: string;
      following: boolean;
      followRequested: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/followUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.followUser("<userId>");
  • likePostLikes a post by its media id.

    Arguments

    NameTypeRequired
    mediaIdstringYes

    Returns InstagramLikeResult

    interface InstagramLikeResult {
      mediaId: string;
      likeCount: number;
      hasLiked: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/likePost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.likePost("<mediaId>");
  • muteUserMutes a user's posts and stories from the signed-in account's feed, without unfollowing them.

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramMuteResult

    interface InstagramMuteResult {
      userId: string;
      muting: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/muteUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.muteUser("<userId>");
  • savePostSaves a post to the signed-in user's default collection.

    Arguments

    NameTypeRequired
    mediaIdstringYes

    Returns InstagramSaveResult

    interface InstagramSaveResult {
      mediaId: string;
      hasSaved: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/savePost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.savePost("<mediaId>");
  • sendDirectMessageSends a direct message to one user.

    Arguments

    NameTypeRequired
    recipientIdstringYes
    messageTextstringYes

    Returns InstagramSentDirectMessage

    interface InstagramSentDirectMessage {
      id: string;
      text: string;
      timestamp: string | null;
      success: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/sendDirectMessage

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.sendDirectMessage("<recipientId>", "<messageText>");
  • unblockUserUnblocks a previously blocked user.

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramUnblockResult

    interface InstagramUnblockResult {
      userId: string;
      username: string;
      blocking: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/unblockUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.unblockUser("<userId>");
  • unfollowUserUnfollows a user the signed-in account is currently following.

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramUnfollowResult

    interface InstagramUnfollowResult {
      userId: string;
      username: string;
      following: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/unfollowUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.unfollowUser("<userId>");
  • unlikePostRemoves a like from a previously liked post.

    Arguments

    NameTypeRequired
    mediaIdstringYes

    Returns InstagramUnlikeResult

    interface InstagramUnlikeResult {
      mediaId: string;
      likeCount: number;
      hasLiked: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/unlikePost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.unlikePost("<mediaId>");
  • unmuteUserUnmutes a previously muted user, restoring their posts and stories to the signed-in account's feed.

    Arguments

    NameTypeRequired
    userIdstringYes

    Returns InstagramUnmuteResult

    interface InstagramUnmuteResult {
      userId: string;
      muting: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/unmuteUser

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.unmuteUser("<userId>");
  • unsavePostRemoves a post from the signed-in user's saved collection.

    Arguments

    NameTypeRequired
    mediaIdstringYes

    Returns InstagramUnsaveResult

    interface InstagramUnsaveResult {
      mediaId: string;
      hasSaved: boolean;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/unsavePost

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.unsavePost("<mediaId>");
  • updateProfileUpdates the signed-in user's profile information such as biography, full name, or website link.

    Arguments

    NameTypeRequired
    updates{ biography?: string; fullName?: string; website?: string | null }Yes

    Returns InstagramUpdateProfileResult

    interface InstagramUpdateProfileResult {
      userId: string;
      username: string;
      fullName: string;
      biography: string;
      externalUrl: string | null;
    }

    HTTP endpoint

    POST https://api.bowmark.ai/v1/sites/instagram/updateProfile

    Call it

    import { bowmark } from "@bowmark/web";
    
    const result = await bowmark.providers.instagram.updateProfile({});

Use it from code