Skip to main content
Glama
langchain.ts571 B
import { type StructuredTool, tool as langchainTool } from 'langchain' import { ListToolkit } from './toolkit.js' import { type Tool } from './tools.js' import { safeFunc } from './util.js' export class AgentMailToolkit extends ListToolkit<StructuredTool> { protected buildTool(tool: Tool): StructuredTool { return langchainTool(async (args) => JSON.stringify((await safeFunc(tool.func, this.client, args)).result, null, 2), { name: tool.name, description: tool.description, schema: tool.paramsSchema, }) } }

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/agentmail-to/agentmail-toolkit'

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