YNAB MCP Server

by calebl
Verified

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Integrations

  • Supports publishing the MCP server as an npm package for easier distribution and installation

  • Used for building tools that interact with YNAB's API through typed interfaces

  • Utilized for schema validation of tool inputs when interacting with YNAB data

ynab-mcp-서버

mcp-framework로 구축된 모델 컨텍스트 프로토콜(MCP) 서버입니다. 이 MCP는 https://ynab.com 에서 YNAB 예산 설정과 상호 작용할 수 있는 도구를 제공합니다.

AI가 이 도구와 상호 작용하려면 YNAB에서 개인 액세스 토큰( https://api.ynab.com/#personal-access-tokens )을 받아야 합니다. 이 MCP 서버를 클라이언트에 추가할 때 개인 액세스 토큰을 YNAB_API_TOKEN으로 제공해야 합니다. 이 토큰은 LLM으로 직접 전송되지 않습니다. YNAB API에서 사용할 수 있도록 환경 변수에 비공개로 저장됩니다.

설정

환경 변수 지정:

  • YNAB_API_TOKEN(필수)
  • YNAB_BUDGET_ID(선택 사항)

목표

이 프로젝트의 목표는 AI 대화를 통해 YNAB 예산과 소통하는 것입니다. 몇 가지 주요 워크플로를 활성화하고자 합니다.

워크플로:

첫 번째 설정

  • 사용 가능한 예산 중에서 예산을 선택하라는 메시지가 표시됩니다. 다른 도구를 먼저 사용하려고 하면 기본 예산을 설정하라는 메시지가 표시됩니다.
    • 필요한 도구: ListBudgets

초과 지출 카테고리 관리

새로운 거래 추가

거래 승인

월 총 지출과 총 수입을 확인하세요

카테고리 목표에 따라 자금을 할당할 준비가 된 자동 분배

현재 상태

사용 가능한 도구:

  • ListBudgets - 계정에서 사용 가능한 예산을 나열합니다.
  • BudgetSummary - 자금이 부족한 범주와 예산이 부족한 계정에 대한 요약을 제공합니다.
  • GetUnapprovedTransactions - 승인되지 않은 모든 거래 검색
  • CreateTransaction - 지정된 예산 및 계정에 대한 거래를 생성합니다.
    • 예시 프롬프트: Add a transaction to my Ally account for $3.98 I spent at REI today
    • 먼저 GetBudget을 호출해야 계정 ID를 알 수 있습니다.

다음:

빠른 시작

지엑스피1

프로젝트 구조

ynab-mcp-server/ ├── src/ │ ├── tools/ # MCP Tools │ └── index.ts # Server entry point ├── package.json └── tsconfig.json

구성 요소 추가

YNAB SDK는 사용 가능한 API 엔드포인트를 설명합니다: https://github.com/ynab/ynab-sdk-js .

YNAB 오픈 API 사양은 https://api.ynab.com/papi/open\_api\_spec.yaml 에 있습니다. 이 사양은 AI가 새로운 도구를 생성하도록 유도하는 데 사용할 수 있습니다. 커서 에이전트에 대한 프롬프트 예시:

create a new tool based on the readme and this openapi doc: https://api.ynab.com/papi/open_api_spec.yaml The new tool should get the details for a single budget

CLI를 사용하여 더 많은 도구를 추가할 수 있습니다.

# Add a new tool mcp add tool my-tool # Example tools you might create: mcp add tool data-processor mcp add tool api-client mcp add tool file-handler

도구 개발

도구 구조의 예:

import { MCPTool } from "mcp-framework"; import { z } from "zod"; interface MyToolInput { message: string; } class MyTool extends MCPTool<MyToolInput> { name = "my_tool"; description = "Describes what your tool does"; schema = { message: { type: z.string(), description: "Description of this input parameter", }, }; async execute(input: MyToolInput) { // Your tool logic here return `Processed: ${input.message}`; } } export default MyTool;

npm에 게시하기

  1. package.json을 업데이트하세요:
    • name 이 고유하고 npm 명명 규칙을 따르는지 확인하세요.
    • 적절한 version 설정하세요
    • description , author , license 등을 추가합니다.
    • 올바른 항목 파일에 대한 bin 포인트를 확인하세요.
  2. 로컬로 빌드하고 테스트하세요.
    npm run build npm link ynab-mcp-server # Test your CLI locally
  3. npm에 로그인합니다(필요한 경우 계정을 만듭니다):
    npm login
  4. 패키지를 게시하세요:
    npm publish

게시 후 사용자는 이를 Claude 데스크톱 클라이언트에 추가하거나(아래 참조) npx로 실행할 수 있습니다.

Claude Desktop과 함께 사용

Smithery를 통해 설치

Smithery 를 통해 Claude Desktop용 YNAB Budget Assistant를 자동으로 설치하려면:

npx -y @smithery/cli install @calebl/ynab-mcp-server --client claude

지역 개발

Claude Desktop 구성 파일에 다음 구성을 추가하세요.

MacOS : ~/Library/Application Support/Claude/claude_desktop_config.json Windows : %APPDATA%/Claude/claude_desktop_config.json

{ "mcpServers": { "ynab-mcp-server": { "command": "node", "args":["/absolute/path/to/ynab-mcp-server/dist/index.js"] } } }

출판 후

Claude Desktop 구성 파일에 다음 구성을 추가하세요.

MacOS : ~/Library/Application Support/Claude/claude_desktop_config.json Windows : %APPDATA%/Claude/claude_desktop_config.json

{ "mcpServers": { "ynab-mcp-server": { "command": "npx", "args": ["ynab-mcp-server"] } } }

다른 MCP 클라이언트

사용 가능한 다른 클라이언트는 https://modelcontextprotocol.io/clients에서 확인하세요.

빌딩 및 테스트

  1. 도구를 변경하세요
  2. npm run build 실행하여 컴파일합니다.
  3. 서버는 시작 시 자동으로 도구를 로드합니다.

자세히 알아보기

You must be authenticated.

A
security – no known vulnerabilities
A
license - permissive license
A
quality - confirmed to work

YNAB(You Need A Budget) 데이터와 AI 기반 상호작용을 가능하게 하는 모델 컨텍스트 프로토콜 서버로, 사용자는 대화형 인터페이스를 통해 예산을 쿼리할 수 있습니다.

  1. Setup
    1. Goal
      1. Workflows:
        1. First time setup
        2. Manage overspent categories
        3. Adding new transactions
        4. Approving transactions
        5. Check total monthly spending vs total income
        6. Auto-distribute ready to assign funds based on category targets
      2. Current state
        1. Quick Start
          1. Project Structure
            1. Adding Components
              1. Tool Development
                1. Publishing to npm
                  1. Using with Claude Desktop
                    1. Installing via Smithery
                    2. Local Development
                    3. After Publishing
                    4. Other MCP Clients
                  2. Building and Testing
                    1. Learn More
                      ID: k7h1fcvgs1