Skip to main content
Glama
shahlaukik

Money Manager MCP Server

by shahlaukik

asset_create

Add new financial accounts or assets to track balances and organize personal finances in the Money Manager system.

Instructions

Creates a new asset/account.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
assetGroupIdYesAsset group ID
assetGroupNameYesAsset group name
assetNameYesAsset name
assetMoneyYesInitial balance
linkAssetIdNoOptional: Linked asset ID
linkAssetNameNoOptional: Linked asset name

Implementation Reference

  • The main handler function for the asset_create tool. Validates input using AssetCreateInputSchema and makes a POST request to the /assetAdd API endpoint to create a new asset.
    /**
     * Handler for asset_create tool
     * Creates a new asset/account
     */
    export async function handleAssetCreate(
      httpClient: HttpClient,
      input: unknown,
    ): Promise<AssetOperationResponse> {
      const validated = AssetCreateInputSchema.parse(input);
    
      const response = await httpClient.post<ApiOperationResponse>("/assetAdd", {
        assetGroupId: validated.assetGroupId,
        assetGroupName: validated.assetGroupName,
        assetName: validated.assetName,
        assetMoney: validated.assetMoney,
        linkAssetId: validated.linkAssetId || "",
        linkAssetName: validated.linkAssetName || "",
      });
    
      return {
        success: response.success !== false && response.result !== "fail",
        assetId: response.assetId,
        message: response.message,
      };
    }
  • Zod schema definition for validating input parameters of the asset_create tool, including assetGroupId, assetGroupName, assetName, assetMoney, and optional link fields.
    /**
     * Input schema for asset_create tool
     */
    export const AssetCreateInputSchema = z.object({
      assetGroupId: NonEmptyString,
      assetGroupName: NonEmptyString,
      assetName: NonEmptyString,
      assetMoney: z.number(),
      linkAssetId: z.string().optional(),
      linkAssetName: z.string().optional(),
    });
    
    export type AssetCreateInput = z.infer<typeof AssetCreateInputSchema>;
  • src/index.ts:224-245 (registration)
    MCP tool registration in the TOOL_DEFINITIONS array, defining the name, description, and inputSchema for the asset_create tool.
    {
      name: "asset_create",
      description: "Creates a new asset/account.",
      inputSchema: {
        type: "object" as const,
        properties: {
          assetGroupId: { type: "string", description: "Asset group ID" },
          assetGroupName: { type: "string", description: "Asset group name" },
          assetName: { type: "string", description: "Asset name" },
          assetMoney: { type: "number", description: "Initial balance" },
          linkAssetId: {
            type: "string",
            description: "Optional: Linked asset ID",
          },
          linkAssetName: {
            type: "string",
            description: "Optional: Linked asset name",
          },
        },
        required: ["assetGroupId", "assetGroupName", "assetName", "assetMoney"],
      },
    },
  • Internal tool handler registry mapping 'asset_create' to the handleAssetCreate function.
    export const toolHandlers = {
      // Initialization
      init_get_data: handleInitGetData,
    
      // Transactions
      transaction_list: handleTransactionList,
      transaction_create: handleTransactionCreate,
      transaction_update: handleTransactionUpdate,
      transaction_delete: handleTransactionDelete,
    
      // Summary
      summary_get_period: handleSummaryGetPeriod,
      summary_export_excel: handleSummaryExportExcel,
    
      // Assets
      asset_list: handleAssetList,
      asset_create: handleAssetCreate,
      asset_update: handleAssetUpdate,
      asset_delete: handleAssetDelete,
    
      // Credit Cards
      card_list: handleCardList,
      card_create: handleCardCreate,
      card_update: handleCardUpdate,
    
      // Transfers
      transfer_create: handleTransferCreate,
      transfer_update: handleTransferUpdate,
    
      // Dashboard
      dashboard_get_overview: handleDashboardGetOverview,
      dashboard_get_asset_chart: handleDashboardGetAssetChart,
    
      // Backup
      backup_download: handleBackupDownload,
      backup_restore: handleBackupRestore,
    } as const;
  • TypeScript interface definition for AssetCreateInput used in conjunction with the Zod schema.
     */
    export interface AssetCreateInput {
      assetGroupId: string;
      assetGroupName: string;
      assetName: string;
      assetMoney: number;
      linkAssetId?: string;
      linkAssetName?: string;
    }
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. It indicates a creation operation but fails to mention required permissions, whether this is idempotent, what happens on duplicate assets, or the response format. For a mutation 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 extremely concise with just one sentence that directly states the tool's purpose. There is no wasted language or unnecessary elaboration, making it efficiently front-loaded.

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?

For a creation tool with 6 parameters, no annotations, and no output schema, the description is inadequate. It doesn't explain what an 'asset/account' represents in this system, how creation affects other entities, or what to expect upon success/failure. The context signals indicate significant complexity that isn't addressed.

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?

Schema description coverage is 100%, so the schema already documents all 6 parameters thoroughly. The description adds no additional parameter information beyond what's in the schema, such as explaining relationships between parameters (e.g., assetGroupId vs assetGroupName) or usage examples. Baseline 3 is appropriate when schema does the heavy lifting.

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 verb ('creates') and resource ('new asset/account'), making the purpose immediately understandable. However, it doesn't distinguish between 'asset' and 'account' or clarify how this differs from sibling tools like card_create or transaction_create, 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 card_create or transaction_create, nor does it mention prerequisites or constraints. It simply states what the tool does without context for selection.

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