Skip to main content
Glama

get_message_history

Retrieve message history from multiple integrated services, optionally filtering by date to track conversations and interactions across platforms.

Instructions

List message history optionally since a date

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
from_dateNo

Implementation Reference

  • The handler function for the 'get_message_history' tool. It checks configuration, extracts the optional 'from_date' from input args, and delegates to the Twilio client's getMessageHistory method.
    async get_message_history(args: Record<string, unknown>) { if (!cfg.twilioAccountSid || !cfg.twilioAuthToken) throw new Error("TWILIO_ACCOUNT_SID/TWILIO_AUTH_TOKEN are not configured"); const fromDate = args.from_date ? String(args.from_date) : undefined; return client.getMessageHistory(fromDate); },
  • The registration of the 'get_message_history' tool in the tools array, including name, description, and input schema.
    { name: "get_message_history", description: "List message history optionally since a date", inputSchema: { type: "object", properties: { from_date: { type: "string" } }, }, },
  • Input schema for the 'get_message_history' tool, defining an optional 'from_date' string property.
    inputSchema: { type: "object", properties: { from_date: { type: "string" } }, },
  • Helper method in TwilioClient class that makes the API request to retrieve Twilio message history, optionally filtered by DateSent query parameter.
    getMessageHistory(fromDate?: string) { return this.request(`/Accounts/${this.accountSid}/Messages.json`, { headers: { Authorization: `Basic ${this.authHeader}` }, query: fromDate ? { DateSent: fromDate } : undefined, }); }

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/TaylorChen/muti-mcps'

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