Skip to main content
Glama
ousepachn

Beehiiv Analytics MCP Server

by ousepachn

get_subscribers

Retrieve subscriber data for a Beehiiv publication to analyze audience composition and track growth metrics.

Instructions

Get subscribers for a publication

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
publication_idYesThe ID of the publication
limitNoNumber of subscribers to return (default: 10)

Implementation Reference

  • Core implementation of the get_subscribers tool: makes HTTP GET request to Beehiiv API's subscribers endpoint.
    async getSubscribers(publicationId, limit = 10) { return await makeRequest('GET', `${this.baseUrl}/publications/${publicationId}/subscribers?limit=${limit}`, this.headers); }
  • server.js:252-270 (registration)
    Registration of the get_subscribers tool in the tools/list response, including name, description, and input schema.
    { name: "get_subscribers", description: "Get subscribers for a publication", inputSchema: { type: "object", properties: { publication_id: { type: "string", description: "The ID of the publication" }, limit: { type: "number", description: "Number of subscribers to return (default: 10)", default: 10 } }, required: ["publication_id"] } },
  • Input schema definition for the get_subscribers tool.
    inputSchema: { type: "object", properties: { publication_id: { type: "string", description: "The ID of the publication" }, limit: { type: "number", description: "Number of subscribers to return (default: 10)", default: 10 } }, required: ["publication_id"] }
  • MCP tools/call dispatch handler that executes get_subscribers by calling the BeehiivAPI method.
    case 'get_subscribers': result = await client.getSubscribers(args.publication_id, args.limit || 10); break;

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/ousepachn/beehiivanalyticsMCP'

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