Skip to main content
Glama

fiscal-api-mcp

国家財政API MCPサーバー — 予算・決算・財政事業データをAIエージェントに提供します。

データソース

ソース

内容

必要なキー

openfiscaldata.go.kr

財政事業・予算・決算・省庁現況

OPENFISCAL_API_KEY (必須)

data.go.kr

分野別・省庁別予算現況

DATAGOKR_API_KEY (任意)

nabostats.go.kr

財政総量・租税負担率・国家債務

NABOSTATS_API_KEY (任意)

Related MCP server: narajangteo-pro

APIキーの発行

OPENFISCAL_API_KEY (必須)

  1. openfiscaldata.go.kr にアクセス

  2. 会員登録 / ログイン

  3. マイページ → OpenAPI申請

  4. 発行されたキーを .env に入力

DATAGOKR_API_KEY (任意)

  1. data.go.kr にアクセス

  2. 会員登録 / ログイン

  3. マイページ → API利用申請

  4. 発行されたキーを .env に入力

NABOSTATS_API_KEY (任意)

  1. nabo.go.kr にアクセス

  2. 会員登録 / ログイン

  3. OpenAPI申請

  4. 発行されたキーを .env に入力

クイックスタート

git clone https://github.com/yangheeseok1/fiscal-api-mcp
cd fiscal-api-mcp
npm install
cp .env.example .env
# .env 파일을 열어 API 키 입력
npm run build

Claude Desktopの設定

Claude Desktopの設定ファイル(claude_desktop_config.json)に以下を追加します。

設定ファイルの場所:

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "fiscal-api-mcp": {
      "command": "node",
      "args": ["C:/경로/fiscal-api-mcp/dist/index.js"],
      "env": {
        "OPENFISCAL_API_KEY": "your_key_here",
        "DATAGOKR_API_KEY": "your_key_here",
        "NABOSTATS_API_KEY": "your_key_here"
      }
    }
  }
}

args のパスは、ご自身の実際のプロジェクトパスに変更してください。 選択キー(DATAGOKR_API_KEY, NABOSTATS_API_KEY)がない場合は、該当する行を削除しても構いません。

設定後、Claude Desktopを再起動するとツールが有効になります。

ツール (7個)

ツール

説明

fiscal_program

財政事業検索・執行現況 (コア)

fiscal_budget

予算案照会

fiscal_settlement

決算照会

fiscal_ministry

省庁財政現況

fiscal_stats

財政統計 (NABOSTATS)

discover_fiscal

APIカタログ探索

query_fiscal

直接API呼び出し

使用例

Claude Desktopで以下のように自然言語で質問してください。

2024년 교육부 예산이 얼마야?
R&D 재정사업 집행현황 보여줘
2015년부터 2024년까지 국가채무 추이 알려줘
기재부 소관 재정사업 목록 뽑아줘
2023년 세출결산에서 집행률이 가장 낮은 부처는?

Available Tools

3 tools
fiscal_guideA

열린재정 OpenAPI 전체 카탈로그(157개)를 카테고리별로 안내합니다. category 없이 호출하면 카테고리 요약을 반환합니다. category를 지정하면 해당 카테고리의 전체 API 목록(코드·이름·필수파라미터)을 반환합니다. 데이터를 찾을 때: fiscal_guide → fiscal_search → fiscal_query 순서로 사용하세요.

ParametersJSON Schema
NameRequiredDescriptionDefault
categoryNo카테고리 지정 시 해당 API 전체 목록 반환. 생략 시 카테고리 요약만 반환.

TDQS

A4.7/5.0
Behavior4/5

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

No annotations provided, so description carries full burden. It clearly describes behavior: returns category summary without parameter, full API list with parameter. No destructive or hidden side effects implied. Lacks mention of rate limits or authentication, but not critical for a guide tool.

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?

Four short, focused sentences. First sentence states main function. Second and third detail parameter behavior. Last gives usage order. No redundant information. Perfectly front-loaded.

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

Completeness5/5

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

For a guide tool with no output schema and one optional parameter, description fully covers what it returns in both cases and how it fits with siblings. No gaps given the tool's simplicity.

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?

Schema already has 100% coverage with enum values and description. Description adds context: without category, returns summary; with category, returns API list. This adds meaningful usage context beyond schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Description clearly states that the tool lists 157 OpenAPI items categorized, and specifies behavior with and without the category parameter. It distinguishes from siblings by recommending a usage order (fiscal_guide → fiscal_search → fiscal_query), showing unique role as a guide.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly states when to use (category summary or full API list) and not to use (data search/fetch, which are for fiscal_search and fiscal_query). Provides a clear ordering recommendation, helping AI agent decide correctly.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

fiscal_queryB

열린재정 API를 호출해 데이터를 조회합니다. api_code는 fiscal_search 또는 fiscal_guide로 먼저 확인하세요. page_size 기본값은 100입니다 (최대 1000).

ParametersJSON Schema
NameRequiredDescriptionDefault
api_codeYesAPI 코드 (fiscal_search로 확인)
paramsNo쿼리 파라미터 (예: {FSCL_YY: 2024, OFFC_NM: '교육부'})
pageNo페이지 번호 (기본: 1)
page_sizeNo페이지당 건수 (기본: 100, 최대: 1000)

TDQS

B3.4/5.0
Behavior2/5

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

No annotations are provided, so the description bears full responsibility for behavioral disclosure. It mentions default page_size and max, but fails to describe whether the tool is read-only, the nature of the API call (e.g., HTTP GET vs POST), error handling, or rate limits. For a data query tool, this is insufficient.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise (three sentences), front-loads the main purpose, and uses bullet points effectively. However, the first line could be slightly more specific about the kind of data (e.g., fiscal data). Overall efficient.

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

Completeness3/5

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

Given the tool has 4 parameters, 1 required, and no output schema, the description adequately covers the basic usage. But it lacks details about return structure, error scenarios, and pagination behavior beyond page_size. It meets minimum viability but is not comprehensive.

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 baseline is 3. The description adds no additional parameter information aside from the default page_size, which is already present in the schema. It adds minimal value beyond what the schema provides.

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 tool queries the '열린재정' API to retrieve data. It specifies the action (querying), resource (API), and distinguishes from siblings by mentioning that the api_code should be checked via fiscal_search or fiscal_guide, implying it is a general-purpose query tool.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides explicit guidance: users must first use fiscal_search or fiscal_guide to obtain the api_code. It also notes the default page_size of 100 (max 1000). However, it does not specify when not to use this tool or provide alternatives for other scenarios.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 3 tool updatesv0.1.0
    • First observedfiscal_guide
    • First observedfiscal_query
    • First observedfiscal_search

TDQS

A4.2/5.0

Scored across 3 tools

Disambiguation5/5

Each tool has a clear, distinct purpose: fiscal_guide for catalog navigation, fiscal_search for finding APIs, and fiscal_query for data retrieval. The documentation explicitly specifies the recommended order of use, eliminating ambiguity.

Naming Consistency4/5

All names use snake_case with a consistent 'fiscal_' prefix, following a verb-like pattern (guide, search, query). Slight deviation: 'fiscal_guide' is more noun-like than verb-like, but overall pattern is coherent.

Tool Count5/5

Three tools is perfectly scoped for a data API server: one for exploration, one for search, and one for direct query. Each tool serves a necessary function without redundancy.

Completeness5/5

The tool set covers the full workflow from discovering APIs (guide), to finding specific endpoints (search), to fetching data (query). There are no obvious gaps for the stated purpose of accessing the 열린재정 OpenAPI.

Maintenance

ActivityInactive
ResponsivenessNo issues

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    Enables AI agents to query Korean listed companies' financial statements, public disclosures, executive information, and shareholder structures in real-time using the DART API.
    2
    -
  • A
    license
    A
    quality
    D
    maintenance
    Integrates 6 Korean public procurement APIs to search, analyze, and manage procurement data using natural language.
    8
    3
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    Enables AI to query real-time Korean public data including weather, real estate prices, air quality, economic indicators, and business registration via natural language.
    1
    MIT
  • A
    license
    A
    quality
    D
    maintenance
    Enables AI agents to verify Korean business registration status, tax type, and invoice eligibility using the NTS public data API via 5 tools.
    5
    36 npm
    MIT