Power your agent
คำสั่งของผู้เผยแพร่เอง ไม่ใช่เอนด์พอยต์ของ PlugMCP
Host a copy with our keys and logs.
npx -y [email protected]Claude Code ไม่มีลิงก์ติดตั้งสำหรับคำสั่งแบบโลคัล ให้คัดลอกคำสั่งด้านล่างแล้วรันในเทอร์มินัล
claude mcp add mcp-server-db2i -- npx -y mcp-server-db2i@3.8.7รันในเทอร์มินัล
{ "mcpServers": { "mcp-server-db2i": { "command": "npx", "args": [ "-y", "[email protected]" ] } }}claude_desktop_config.json
URL แบบรีโมตหรือคำสั่งบนเครื่องของคุณ? การติดตั้งสองแบบต่างกันอย่างไร
รันบน PlugMCP
A new server you create. It is not this listing's official endpoint. Use the publisher install when you want their URL and their credentials.
เปิดmcp-server-db2i is a Model Context Protocol (MCP) server for IBM Db2 for i (Db2i) on IBM i (AS/400). It enables AI assistants like Claude and Cursor to query and inspect IBM i databases through the IBM i Access ODBC driver, or optionally the JT400 JDBC driver or Mapepire over SSH.
Listed in the MCP Registry as io.github.Strom-Capital/mcp-server-db2i.
Website: db2i-mcp.com, with a blog that explains each release. Docs: docs.db2i-mcp.com.
AI clients connect to the MCP Server in one of two ways. Local clients such as Claude Desktop, Claude Code and Cursor can start it as a process and talk over stdio. Remote clients connect over Streamable HTTP at /mcp, signing in with OAuth 2.1 (claude.ai custom connectors) or a bearer token (custom agents). Local clients can also use the HTTP endpoint. The server executes read-only queries against Db2 for i using the IBM i Access ODBC driver (default, no Java), the optional JT400 JDBC driver (DB2I_DRIVER=jt400), or Mapepire over SSH (DB2I_DRIVER=mapepire) for systems where only SSH is reachable. One server can reach several IBM i systems through connection profiles, each with its own driver.
graph LR
subgraph clients ["AI Clients"]
local("Claude Desktop, Claude Code, Cursor")
remote("claude.ai connectors")
agents("Custom Agents")
end
subgraph server ["MCP Server"]
stdio["stdio"]
http["Streamable HTTP + Auth"]
tools[["MCP Tools"]]
profiles{{"System profiles"}}
odbc["IBM i Access ODBC"]
jdbc["JT400 JDBC (optional)"]
mapepire["Mapepire over SSH (optional)"]
end
subgraph prod ["IBM i: prod"]
db2prod[("Db2 for i")]
end
subgraph test ["IBM i: test"]
db2test[("Db2 for i")]
end
subgraph dev ["IBM i: dev"]
db2dev[("Db2 for i")]
end
local -->|local process| stdio
local -.->|remote URL| http
remote -->|OAuth 2.1| http
agents -->|bearer token| http
stdio & http --> tools
tools --> profiles
profiles --> odbc & jdbc & mapepire
odbc -->|ODBC| db2prod
jdbc -->|JDBC| db2test
mapepire -->|SSH| db2dev
DB2I_PROFILES, each with its own driver, credentials, and library allowlist. Tools take an optional system argument. See Multiple systemsDB2I_DRIVER=mapepire, reach an IBM i where only SSH is open. Mapepire starts inside the SSH session, with no server install and a host key check. See Using the Mapepire driverexecute_querymcp-server-db2i validate-tools before the server starts. See Business SQL toolsMCP_TOOL_INTENT). See Audit logMCP_CUSTOM_TOOLS_WATCH=truenpm install -g mcp-server-db2i
The default odbc driver needs unixODBC and the IBM i Access ODBC Driver on the machine. No Java is needed. The other drivers' packages are not installed by default, so add them next to the server:
npm install -g mcp-server-db2i node-jt400 # DB2I_DRIVER=jt400, needs a JDK to install and a JRE to run
npm install -g mcp-server-db2i @ibm/mapepire-js ssh2 # DB2I_DRIVER=mapepire, when only SSH reaches the IBM i
With npx, pass them with -p, for example npx -y -p mcp-server-db2i@latest -p node-jt400 mcp-server-db2i. See Installing the jt400 and mapepire packages.
Or with Docker:
docker build -t mcp-server-db2i . # odbc image (amd64; add --platform linux/amd64 on arm64)
docker build --target jt400 -t mcp-server-db2i . # jt400 image (builds natively on arm64)
Create a .env file with your IBM i credentials:
DB2I_HOSTNAME=your-ibm-i-host.com
DB2I_USERNAME=your-username
DB2I_PASSWORD=your-password
DB2I_SCHEMA=your-default-schema # Optional
Add to your MCP client config (e.g., ~/.cursor/mcp.json):
{
"mcpServers": {
"db2i": {
"command": "npx",
"args": ["-y", "mcp-server-db2i@latest"],
"env": {
"DB2I_HOSTNAME": "${env:DB2I_HOSTNAME}",
"DB2I_USERNAME": "${env:DB2I_USERNAME}",
"DB2I_PASSWORD": "${env:DB2I_PASSWORD}"
}
}
}
}
This uses environment variable expansion to keep credentials out of config files. Set the variables in your shell profile (~/.zshrc or ~/.bashrc).
See the Client Setup Guide for Cursor, Claude Desktop, Claude Code, and Docker setup options.
No MCP client? The example web app is a browser chat with result tables, exports and the business SQL tools. Users sign in with their IBM i user profile and bring their own model API key.
In hosts that support MCP Apps, results from execute_query, profile_table and business SQL tools open as a grid and a chart under the tool call. See Result view.
The list tools support pattern matching:
CUST - Contains "CUST"CUST* - Starts with "CUST"*LOG - Ends with "LOG"Clients that support MCP resources can read a table's context without a tool call, and complete library and table names as you type.
resources/list offers the annotated tables, for example db2i://MYLIB/ORDERS. Percent-encode # and other reserved characters in names (ORD%23X for ORD#X). A library outside QUERY_ALLOWED_SCHEMAS is rejected with the same message execute_query gives, and completion offers only allowed libraries. Reads and completions that query IBM i count against the rate limit, and reads are written to the audit log. Completion fetches a library's name list once and reuses it for 60 seconds, so typing a name costs one query rather than one per keystroke.
A prompt is listed only when the tools it tells the model to call are enabled: explore_library needs list_tables and describe_table, and the other two need describe_table. None of them asks for a write.
I've used this server on projects where the source system was the Iptor DC1 ERP on IBM i. The same patterns work with any IBM i ERP.
validate_query, tests it on sample rows, and then writes the endpoint.get_object_ddl, and draft incremental extracts and code mappings for the warehouse.See Use cases for sample prompts and the guardrails that go with each one.
Once connected, you can ask the AI assistant:
validate_query and the execute_query parse check need QSYS2.PARSE_STATEMENT (IBM i 7.3 with Db2 PTF group SF99703 level 3, or 7.4 and later)get_related_objects needs IBM i 7.3 Technology Refresh 9, IBM i 7.4 Technology Refresh 3, or a later releaseget_journal_info needs the journal columns of QSYS2.OBJECT_STATISTICS (IBM i 7.3 Technology Refresh 2 or later)search_ibmi_services needs QSYS2.SERVICES_INFO, which ships with the Db2 for i PTF groupcause and recovery on a failed statement come from SYSTOOLS.SQLCODE_INFO. Without it, errors return the SQLSTATE, SQLCODE and message onlyodbc driver, a JDK at install time and a JRE 11 or higher at runtime for the optional jt400 driver, or SSH access and Java 8 or higher on the IBM i for the optional mapepire driver (see Database Drivers)mapepire driver uses Mapepire's SSH mode, which needs no Mapepire server running on the IBM i.Contributions are welcome! See the Development Guide for setup instructions.
MIT License - see LICENSE for details.
IBM, IBM i and Db2 are trademarks of International Business Machines Corporation. This project is not affiliated with or endorsed by IBM.
Read-only MCP server that lets AI assistants query IBM Db2 for i, with per-user sign-in, a library allowlist and an audit log
{ "mcpServers": { "mcp-server-db2i": { "command": "npx", "args": [ "-y", "[email protected]" ] } }}เครื่องมือ
ยังไม่มีรายการเครื่องมือ เซิร์ฟเวอร์แบบรีโมตจะได้รายการหลังการตรวจสอบสถานะครั้งแรก
FAQ
คัดลอกคอนฟิก stdio สำหรับ Cursor, Claude Desktop, Claude Code หรือ VS Code ได้ในหน้านี้ คอนฟิกนี้ใช้การติดตั้งของผู้เผยแพร่ ไม่ใช่พร็อกซีของ PlugMCP
ระเบียนนี้ไม่ได้ระบุตัวแปรสภาพแวดล้อมที่จำเป็น
MCP Server Db2i ทำงานแบบโลคัลผ่าน stdio
ตรวจสอบล่าสุดเมื่อ 2026-11-13 Read-only MCP server that lets AI assistants query IBM Db2 for i, with per-user sign-in, a library allowlist and an audit log