Skip to main content
Glama
justmytwospence

ynab-mcp

get_budget_settings

Retrieve date and currency format settings for a YNAB budget to ensure consistent financial data display and reporting.

Instructions

[1 API call] Get a budget's date and currency format settings

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
budget_idNoBudget ID or 'last-used'last-used

Implementation Reference

  • The 'get_budget_settings' tool implementation, including registration, input schema, and handler logic.
    server.registerTool("get_budget_settings", {
      title: "Get Budget Settings",
      description: "[1 API call] Get a budget's date and currency format settings",
      inputSchema: {
        budget_id: z.string().default("last-used").describe("Budget ID or 'last-used'"),
      },
      annotations: { readOnlyHint: true },
    }, async ({ budget_id }) => {
      try {
        const response = await getClient().plans.getPlanSettingsById(budget_id);
        const s = response.data.settings;
        const lines = [
          `Date Format: ${s.date_format?.format}`,
          `Currency Format:`,
          `  ISO Code: ${s.currency_format?.iso_code}`,
          `  Symbol: ${s.currency_format?.currency_symbol}`,
          `  Decimal Digits: ${s.currency_format?.decimal_digits}`,
          `  Symbol First: ${s.currency_format?.symbol_first}`,
          `  Display Symbol: ${s.currency_format?.display_symbol}`,
        ];
        return textResult(lines.join("\n"));
      } 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