k

k-targo-subway-mcp-server

@slicequeue/k-targo-subway-mcp-server
0 Stars 190 次浏览 slicequeue 更新于 2026-08-23

MCP 服务配置

复制以下 JSON 到 OPClaw 或其他 MCP 客户端的配置文件中即可使用

{
  "mcpServers": {
    "k-targo-subway": {
      "args": [
        "k-targo-subway-mcp-server"
      ],
      "command": "npx",
      "env": {
        "GOV_API_KEY": "your_targo_api_key_here"
      }
    }
  }
}

服务介绍

K-Targo Subway MCP Server

smithery badge

MCP (Model Context Protocol) .

  • ** **:
  • ** **:
  • ** **: Tago API
  • **MCP **: Model Context Protocol

Installing via Smithery

To install k-targo-subway-mcp-server for Claude Desktop automatically via Smithery:

npx -y @smithery/cli install @slicequeue/k-targo-subway-mcp-server --client claude

1. API

(TAGO) API . API .

API

API

  1. "(TAGO)" API
  2. API

# Windows
set GOV_API_KEY=your_api_key_here

# macOS/Linux
export GOV_API_KEY=your_api_key_here

# .env   ()
echo "GOV_API_KEY=your_api_key_here" > .env

2. npx ()

npx k-targo-subway-mcp-server

3. npm

npm install k-targo-subway-mcp-server

4.

npm install -g k-targo-subway-mcp-server

MCP

1. (search_subway_station)

.

** :**

  • stationName (string):

** :**

// ""  
const result = await searchSubwayStationTool.handler({
  stationName: ""
}, {});

2. (get_station_timetable)

.

** :**

  • stationCode (string):
  • direction (string): (/)

** :**

//    
const result = await getStationTimetableTool.handler({
  stationCode: "0222",
  direction: ""
}, {});

src/
 config/           #  
    index.ts
 external/         #  API 
    common/       #  
    tago-subway/  # Tago  API
        api.ts    # API 
        service.ts #  
        dtos/     #   
        types/    #  
 tools/           # MCP 
    subway.ts    #   
    index.ts     #  
    types.ts     #   
 utils/           # 
    PackageJsonUtil.ts
    ResponseUtil.ts
 index.ts         #  

1.

npm install

2. API

# .env  
echo "GOV_API_KEY=your_api_key_here" > .env

#   
export GOV_API_KEY=your_api_key_here  # macOS/Linux
set GOV_API_KEY=your_api_key_here     # Windows

.env

# _(TAGO)_ API 
# (https://www.data.go.kr/)  API  
# API URL: https://www.data.go.kr/data/15098554/openapi.do
GOV_API_KEY=your_public_data_api_key_here

# :
# GOV_API_KEY=abc123def456ghi789jkl012mno345pqr678stu901vwx234yz567

3.

npm run dev

4.

npm run build

5.

#  
npm test

# API 
npm run test:api

#   
npm run test:api:station

API

(TAGO) API

#  
GOV_API_KEY=your_public_data_api_key_here

  • GET /subway-station/search:
  • GET /subway-station/{stationCode}/timetable:

MCP

MCP :

{
  "mcpServers": {
    "k-targo-subway": {
      "command": "npx",
      "args": ["k-targo-subway-mcp-server"],
      "env": {
        "GOV_API_KEY": "your_targo_api_key_here"
      }
    }
  }
}

MCP

//  
const searchResult = await mcpClient.callTool('search_subway_station', {
  stationName: ''
});

//  
const timetableResult = await mcpClient.callTool('get_station_timetable', {
  stationCode: '0222',
  direction: ''
});

CLI

# npx  ()
npx k-targo-subway-mcp-server

#    
k-targo-subway-mcp-server

#  npm  
npm start

  1. ** **: src/tools/
  2. **API **: src/external/ API
  3. ** **:
  4. ****: test/
  5. ** **: npm run build

MCP Tool

.     .

TAGO API

API.   .

  (:  = "0222").

# 
npm run build

# npm 
npm publish

# 
node dist/index.js

MIT License

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

相关 MCP 服务