Skip to main content
Glama

get_mentions

Retrieve posts where your Instagram account has been tagged or mentioned to track user-generated content and monitor brand mentions.

Instructions

Get posts where your account has been tagged or @mentioned. Useful for tracking UGC.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoNumber of mentions (max 100)

Implementation Reference

  • The actual implementation of the getMentions method which makes the API request.
    async getMentions(limit = 25, accountId?: string): Promise<IGMention[]> {
      const id = accountId ?? this.aid();
      const data = await this.request("GET", `${id}/tags`, {
        params: {
          fields:
            "id,media_type,media_url,permalink,caption,timestamp,username",
          limit: String(Math.min(limit, 100)),
        },
      });
      return data.data ?? [];
    }
  • src/index.ts:320-330 (registration)
    Tool registration for get_mentions defining its schema and description.
    {
      name: "get_mentions",
      description:
        "Get posts where your account has been tagged or @mentioned. Useful for tracking UGC.",
      inputSchema: {
        type: "object" as const,
        properties: {
          limit: { type: "integer", description: "Number of mentions (max 100)", minimum: 1, maximum: 100, default: 25 },
        },
      },
    },
  • The tool handler switch-case block that invokes getMentions.
    case "get_mentions": {
      const mentions = await c.getMentions(args.limit ?? 25);
      return JSON.stringify({ mentions, count: mentions.length }, null, 2);
    }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/mcpware/instagram-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server