Skip to main content
Glama
justmytwospence

ynab-mcp

update_month_category

Allocate money to YNAB budget categories by updating assigned amounts for specific months. Modify category budgets to match financial plans.

Instructions

[1 API call] Update the budgeted/assigned amount for a category in a specific month. This is how you allocate money to categories.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
budget_idNoBudget ID or 'last-used'last-used
monthYesMonth in YYYY-MM-DD format (first of month) or 'current'
category_idYesThe category ID
budgetedYesAmount to budget/assign in dollars (e.g., 500.00)

Implementation Reference

  • Registration and handler implementation of the 'update_month_category' tool.
    server.registerTool("update_month_category", {
      title: "Update Month Category Budget",
      description: "[1 API call] Update the budgeted/assigned amount for a category in a specific month. This is how you allocate money to categories.",
      inputSchema: {
        budget_id: z.string().default("last-used").describe("Budget ID or 'last-used'"),
        month: z.string().describe("Month in YYYY-MM-DD format (first of month) or 'current'"),
        category_id: z.string().describe("The category ID"),
        budgeted: z.number().describe("Amount to budget/assign in dollars (e.g., 500.00)"),
      },
      annotations: { readOnlyHint: false },
    }, async ({ budget_id, month, category_id, budgeted }) => {
      try {
        const response = await getClient().categories.updateMonthCategory(budget_id, month, category_id, {
          category: { budgeted: dollarsToMilliunits(budgeted) },
        });
        const c = response.data.category;
        return textResult(`Updated "${c.name}" for ${month}: Budgeted ${formatCurrency(c.budgeted)}`);
      } catch (e: any) {
        return errorResult(e.message);
      }
    });

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/justmytwospence/ynab-mcp'

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