Skip to main content
Glama

get-block-meta-content

Retrieve block metadata content from the FlyonUI MCP server. This tool extracts metadata by accepting an endpoint input, enabling developers to access and utilize block-specific data efficiently.

Instructions

Fetch the content of the block metadata from the FlyonUI MCP server. Use this tool to retrieve the block metadata content.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
endpointYes

Implementation Reference

  • The handler function for the 'get-block-meta-content' tool. It takes an 'endpoint' parameter, constructs the URL by appending '?type=mcp', performs an HTTP GET request using apiClient, and returns the response data as a structured content object with JSON-stringified text. Errors are caught and rethrown with descriptive messages.
    async ({ endpoint }) => { try { const url = endpoint + "?type=mcp"; const response = await apiClient.get(url); if (response.status !== 200) { throw new Error(`Failed to fetch block meta content: ${response.status}`); } return { content: [ { type: "text", text: JSON.stringify(response.data, null, 2), } ], }; } catch (error) { console.error("Error fetching block meta content:", error); throw new Error("Failed to fetch block meta content"); } }
  • The input schema for the tool, defining a single required string parameter 'endpoint' validated using Zod.
    inputSchema: { endpoint: z.string() },
  • src/index.ts:142-173 (registration)
    The registration of the 'get-block-meta-content' tool using McpServer's registerTool method, including title, description, input schema, and the handler function.
    server.registerTool( "get-block-meta-content", { title: "Get Block Meta Content", description: "Fetch the content of the block metadata from the FlyonUI MCP server. Use this tool to retrieve the block metadata content.", inputSchema: { endpoint: z.string() }, }, async ({ endpoint }) => { try { const url = endpoint + "?type=mcp"; const response = await apiClient.get(url); if (response.status !== 200) { throw new Error(`Failed to fetch block meta content: ${response.status}`); } return { content: [ { type: "text", text: JSON.stringify(response.data, null, 2), } ], }; } catch (error) { console.error("Error fetching block meta content:", error); throw new Error("Failed to fetch block meta content"); } } );

Other Tools

Related Tools

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/themeselection/flyonui-mcp'

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