Skip to main content
Glama
whitebirchio

Monarch Money MCP Server

by whitebirchio

get_accounts

Retrieve all financial accounts from Monarch Money to view balances, track assets, and manage personal finances through integration with Claude Desktop.

Instructions

Get all financial accounts from Monarch Money

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • src/tools.ts:13-21 (registration)
    Tool registration for 'get_accounts' in the MCP tool definitions array, including name, description, and input schema (empty object, no required parameters)
    {
      name: 'get_accounts',
      description: 'Get all financial accounts from Monarch Money',
      inputSchema: {
        type: 'object',
        properties: {},
        required: [],
      },
    },
  • Route handler in executeTool switch statement that dispatches to getAccounts() method when tool name is 'get_accounts'
    case 'get_accounts':
      return await this.getAccounts();
  • Implementation of getAccounts() handler method that calls the API, formats the response with success/data/summary structure, and handles errors
    private async getAccounts(): Promise<any> {
      try {
        const accounts = await this.api.getAccounts();
        return {
          success: true,
          data: accounts,
          summary: `Found ${accounts?.length || 0} accounts`,
        };
      } catch (error) {
        throw new Error(
          `Failed to get accounts: ${
            error instanceof Error ? error.message : 'Unknown error'
          }`
        );
      }
    }
  • Underlying MonarchMoneyAPI.getAccounts() method that executes GraphQL query to fetch accounts with detailed fields and handles authentication errors
    async getAccounts(): Promise<Account[]> {
      const query = `
            query GetAccounts {
              accounts {
                ...AccountFields
                __typename
              }
              householdPreferences {
                id
                accountGroupOrder
                __typename
              }
            }
    
            fragment AccountFields on Account {
              id
              displayName
              syncDisabled
              deactivatedAt
              isHidden
              isAsset
              mask
              createdAt
              updatedAt
              displayLastUpdatedAt
              currentBalance
              displayBalance
              includeInNetWorth
              hideFromList
              hideTransactionsFromReports
              includeBalanceInNetWorth
              includeInGoalBalance
              dataProvider
              dataProviderAccountId
              isManual
              transactionsCount
              holdingsCount
              manualInvestmentsTrackingMethod
              order
              logoUrl
              type {
                display
                group
                name
                __typename
              }
              subtype {
                name
                display
                __typename
              }
              credential {
                id
                updateRequired
                disconnectedFromDataProviderAt
                dataProvider
                institution {
                  id
                  plaidInstitutionId
                  name
                  status
                  __typename
                }
                __typename
              }
              institution {
                id
                name
                primaryColor
                url
                __typename
              }
              __typename
            }
      `;
    
      try {
        const data: any = await this.graphQLClient.request(query);
        return data.accounts || [];
      } catch (error: any) {
        if (
          error.message.includes('401') ||
          error.message.includes('unauthorized')
        ) {
          throw new Error(
            'Authentication failed. Please check your MONARCH_TOKEN environment variable.'
          );
        }
        throw new Error(`Failed to get accounts: ${error.message}`);
      }
    }
  • TypeScript interface definition for Account type with properties like id, displayName, currentBalance, type, subtype, and institution
    export interface Account {
      id: string;
      mask: string | null;
      displayName: string;
      currentBalance: number;
      includeInNetWorth: boolean;
      type: {
        name: string;
        group: string;
        display: string;
      };
      subtype: {
        name: string;
        display: string;
      };
      institution?: {
        id: string;
        name: string;
      };
    }
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. It states what the tool does but doesn't mention whether this is a read-only operation, if it requires authentication, what format the data returns in, or any rate limits. For a tool with zero annotation coverage, this is a significant gap.

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 states the tool's purpose without any wasted words. It's appropriately sized and front-loaded, making it easy for an agent to parse quickly.

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

Completeness2/5

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

Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what 'all financial accounts' means (e.g., types, fields returned), how the data is structured, or any behavioral aspects like pagination or errors. For a tool with no structured metadata, this leaves too many gaps.

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

Parameters4/5

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

The tool has 0 parameters with 100% schema description coverage, so the schema already fully documents the input requirements. The description doesn't need to add parameter information, and it appropriately doesn't mention any. Baseline 4 is correct for zero-parameter tools.

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 action ('Get') and resource ('all financial accounts from Monarch Money'), making the purpose immediately understandable. However, it doesn't differentiate from sibling tools like 'get_account_balance' or 'get_account_snapshots', which prevents a perfect score.

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 like 'get_account_balance' or 'get_account_snapshots'. There's no mention of prerequisites, context, or exclusions, leaving the agent to infer usage from tool names alone.

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/whitebirchio/monarch-mcp'

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