Skip to main content
Glama

mcp-youtube

by kirbah
responseFormatter.ts769 B
import type { CallToolResult } from "@modelcontextprotocol/sdk/types.js"; export const formatSuccess = (data: any): CallToolResult => { return { success: true, content: [{ type: "text", text: JSON.stringify(data, null, 2) }], }; }; export const formatVideoMap = ( videoIds: string[], results: any[] ): Record<string, any> => { return videoIds.reduce( (acc, videoId, index) => { acc[videoId] = results[index]; return acc; }, {} as Record<string, any> ); }; export const formatChannelMap = ( channelIds: string[], results: any[] ): Record<string, any> => { return channelIds.reduce( (acc, channelId, index) => { acc[channelId] = results[index]; return acc; }, {} as Record<string, any> ); };

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/kirbah/mcp-youtube'

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