Skip to main content
Glama
alxspiker

AI Meta MCP Server

list_functions

Discover available custom MCP functions to understand what tools AI models can create and execute within the meta-function architecture.

Instructions

List all custom MCP functions

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function for the 'list_functions' tool. It logs the action, maps over customTools to create a list of function metadata (name, description, executionEnvironment, dates), and returns it as a JSON string in the MCP response format.
    async () => {
      console.error(`Listing all functions`);
      
      const functionList = Object.entries(customTools).map(([name, tool]) => ({
        name,
        description: tool.description,
        executionEnvironment: tool.executionEnvironment,
        createdAt: tool.createdAt,
        updatedAt: tool.updatedAt,
      }));
    
      return {
        content: [
          {
            type: "text",
            text: JSON.stringify(functionList, null, 2),
          },
        ],
      };
    }
  • src/index.ts:460-484 (registration)
    The registration of the 'list_functions' tool using server.tool(), including name, description, empty input schema (no parameters), and the handler function.
    server.tool(
      "list_functions",
      "List all custom MCP functions",
      {},
      async () => {
        console.error(`Listing all functions`);
        
        const functionList = Object.entries(customTools).map(([name, tool]) => ({
          name,
          description: tool.description,
          executionEnvironment: tool.executionEnvironment,
          createdAt: tool.createdAt,
          updatedAt: tool.updatedAt,
        }));
    
        return {
          content: [
            {
              type: "text",
              text: JSON.stringify(functionList, null, 2),
            },
          ],
        };
      }
    );
  • The input schema for 'list_functions' tool, which is empty object indicating no input parameters required.
    {},

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/alxspiker/ai-meta-mcp-server'

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