Skip to main content
Glama
ClawyPro

Clawy MCP Server

by ClawyPro

fmp_financial

Retrieve financial statements (income, balance sheet, cash flow) for companies using stock ticker symbols to analyze financial performance.

Instructions

Get company financial statements (income statement, balance sheet, cash flow) from FMP.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
symbolYesStock ticker symbol
statementYesType of financial statement
periodNoReporting period (default: annual)
limitNoNumber of periods to return (default 5)

Implementation Reference

  • src/tools/fmp.ts:16-27 (registration)
    The "fmp_financial" tool is registered here in the fmpTools array, specifying its input schema and API endpoint.
    {
      name: "fmp_financial",
      description: "Get company financial statements (income statement, balance sheet, cash flow) from FMP.",
      inputSchema: z.object({
        symbol: z.string().describe("Stock ticker symbol"),
        statement: z.enum(["income-statement", "balance-sheet-statement", "cash-flow-statement"])
          .describe("Type of financial statement"),
        period: z.enum(["annual", "quarter"]).optional().describe("Reporting period (default: annual)"),
        limit: z.number().optional().describe("Number of periods to return (default 5)"),
      }),
      endpoint: "/v1/fmp/financial",
    },
  • The handler logic for "fmp_financial" (and all other tools in allTools) is dynamically registered in src/index.ts. It uses the `gatewayRequest` helper to fetch data from the API endpoint defined in the tool registration.
    // Register all tools
    for (const tool of allTools) {
      server.tool(
        tool.name,
        tool.description,
        tool.inputSchema.shape,
        async (params) => {
          const method = tool.method || "POST";
          const result = await gatewayRequest(method, tool.endpoint, params as Record<string, unknown>);
    
          if (result.error) {
            return {
              content: [{ type: "text" as const, text: `Error (${result.status}): ${result.error}` }],
              isError: true,
            };
          }
    
          const text = typeof result.data === "string"
            ? result.data
            : JSON.stringify(result.data, null, 2);
    
          return {
            content: [{ type: "text" as const, text }],
          };
        },
      );

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/ClawyPro/clawy-mcp-server'

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