Skip to main content
Glama
shahlaukik

Money Manager MCP Server

by shahlaukik

summary_get_period

Retrieve financial summary statistics for a specified date range to analyze spending, income, and trends within Money Manager.

Instructions

Retrieves financial summary statistics for a date range.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
startDateYesStart date (YYYY-MM-DD)
endDateYesEnd date (YYYY-MM-DD)

Implementation Reference

  • The primary handler function implementing the logic for the 'summary_get_period' tool. Validates input schema, calls the Money Manager API '/getSummaryDataByPeriod' endpoint with startDate and endDate parameters, and transforms the raw response into a structured SummaryResponse object containing overall summary, income by category, and expense by category breakdowns.
    /**
     * Handler for summary_get_period tool
     * Retrieves financial summary statistics for a date range
     */
    export async function handleSummaryGetPeriod(
      httpClient: HttpClient,
      input: unknown,
    ): Promise<SummaryResponse> {
      const validated = SummaryGetPeriodInputSchema.parse(input);
    
      const rawResponse = await httpClient.get<RawSummaryResponse>(
        "/getSummaryDataByPeriod",
        {
          startDate: validated.startDate,
          endDate: validated.endDate,
        },
      );
    
      return {
        summary: rawResponse.summary,
        incomeByCategory: rawResponse.income || [],
        expenseByCategory: rawResponse.outcome || [],
      };
    }
  • Zod schema defining the input validation for the summary_get_period tool, requiring 'startDate' and 'endDate' fields validated against the DateSchema (YYYY-MM-DD format). Includes TypeScript type inference.
    /**
     * Input schema for summary_get_period tool
     */
    export const SummaryGetPeriodInputSchema = z.object({
      startDate: DateSchema,
      endDate: DateSchema,
    });
    
    export type SummaryGetPeriodInput = z.infer<typeof SummaryGetPeriodInputSchema>;
  • Registration of the summary_get_period handler function in the central toolHandlers registry object, which maps tool names to their executor functions.
    // Summary
    summary_get_period: handleSummaryGetPeriod,
  • src/index.ts:176-186 (registration)
    MCP tool registration in the TOOL_DEFINITIONS array, defining the tool name, description, and JSON schema for input validation exposed to the Model Context Protocol server.
      name: "summary_get_period",
      description: "Retrieves financial summary statistics for a date range.",
      inputSchema: {
        type: "object" as const,
        properties: {
          startDate: { type: "string", description: "Start date (YYYY-MM-DD)" },
          endDate: { type: "string", description: "End date (YYYY-MM-DD)" },
        },
        required: ["startDate", "endDate"],
      },
    },
  • Registration of the SummaryGetPeriodInputSchema in the central ToolSchemas registry, used for runtime input validation across all tools.
    // Summary
    summary_get_period: SummaryGetPeriodInputSchema,
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. While 'retrieves' implies a read-only operation, it doesn't specify whether authentication is required, what format the statistics are returned in, whether there are rate limits, or if the data is cached. For a tool with zero annotation coverage, this leaves significant behavioral gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that communicates the core purpose without any wasted words. It's appropriately sized for a simple retrieval tool and front-loads the essential information about what the tool does.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a simple read operation with 2 well-documented parameters and no output schema, the description is minimally adequate. However, it doesn't explain what 'financial summary statistics' includes or the return format, which would be helpful given the lack of output schema. The absence of annotations means the description should do more to cover behavioral aspects.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The schema description coverage is 100%, with both parameters clearly documented in the input schema. The description adds the context that these parameters define a 'date range' for the financial summary, but doesn't provide additional semantic meaning beyond what the schema already specifies about date format and requirements.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with a specific verb ('retrieves') and resource ('financial summary statistics'), and specifies the scope ('for a date range'). It distinguishes itself from siblings like summary_export_excel by focusing on retrieval rather than export, but doesn't explicitly differentiate from dashboard tools that might also provide summaries.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention when this tool is appropriate compared to dashboard_get_overview or summary_export_excel, nor does it specify any prerequisites or constraints beyond the date range requirement implied by the parameters.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/shahlaukik/money-manager-mcp'

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