Openapi MCP
ภาพรวม
คำอธิบายจากผู้ทำ (ภาษาอังกฤษตามต้นฉบับ)
Turn any OpenAPI 3 spec into a working MCP server. One file, local (stdio) or remote (HTTP).
ใช้ทำอะไรได้
ตัวนี้ยังไม่ได้เรียบเรียงเป็นภาษาไทย ด้านล่างคือข้อเท็จจริงที่เราอ่านจาก registry
- การเชื่อมต่อ: รันบนเครื่อง
- ช่องทาง (transport): stdio
- หมวด: เครื่องมือนักพัฒนา
ติดตั้ง
เลือกโปรแกรม AI ที่คุณใช้ แล้วคัดลอกค่าตั้งไปวาง
ผลตรวจผ่าน 2/3 · ทำงานบนเครื่องคุณ
ขั้นแรก: คุณใช้ AI ตัวไหน
เลือกแอปที่คุณใช้ ขั้นตอนจะขึ้นด้านล่าง
ต่อกับ Claude ได้ แต่ต้องเตรียมก่อน
ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว) · ใช้ได้เฉพาะแอป Claude บนคอม (Windows หรือ Mac) ไม่ใช่บนเว็บหรือมือถือ
เปิดไฟล์ตั้งค่าของแอป Claude บนคอม
SettingsDeveloperEdit Config
วางค่าตั้งนี้แล้วบันทึกไฟล์
{ "mcpServers": { "openapi": { "command": "npx", "args": [ "-y", "@asthanaji/openapi-mcp" ] } } }ปิดแอป Claude แล้วเปิดใหม่
ลองเลย
ใช้ Openapi MCP บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง✓ ถ้า Claude บอกว่ากำลังใช้ Openapi MCP หรือมีชื่อเครื่องมือของ Openapi MCP ขึ้นในคำตอบ แปลว่าต่อสำเร็จ
ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป
ChatGPT ยังต่อ Openapi MCP ไม่ได้
Openapi MCP ต้องติดตั้งในเครื่องคุณ แต่ ChatGPT ต่อได้เฉพาะตัวที่ทำงานบนเว็บ
คุณทำแบบนี้แทนได้
ก · ใช้แอปที่ต่อ Openapi MCP ได้
- ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว) · ใช้ได้เฉพาะแอป Claude บนคอม (Windows หรือ Mac) ไม่ใช่บนเว็บหรือมือถือ
- ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
- ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
- ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
ข · ตัวอื่นในหมวด เครื่องมือนักพัฒนา ที่ต่อกับ ChatGPT ได้
เลือกจากตัวที่ใช้มากในหมวดเดียวกัน เฉพาะตัวที่ต่อด้วยที่อยู่ได้โดยไม่ต้องใส่คีย์
- Sentry✓ ChatGPT
- Front-End Checklist✓ ChatGPT
- Compiler Explorer✓ ChatGPT
ต่อกับ Claude Code ได้ แต่ต้องเตรียมก่อน
ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
เปิด Terminal
Mac: กด Command+Space พิมพ์ Terminal · Windows: เปิด PowerShell
วางคำสั่งนี้แล้วกด Enter
claude mcp add openapi -- npx -y @asthanaji/openapi-mcpพิมพ์ /mcp ใน Claude Code
ต้องเห็น Openapi MCP ในรายการและขึ้นว่าเชื่อมต่อแล้ว
ลองเลย
ใช้ Openapi MCP บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง✓ ถ้า Claude Code บอกว่ากำลังใช้ Openapi MCP หรือมีชื่อเครื่องมือของ Openapi MCP ขึ้นในคำตอบ แปลว่าต่อสำเร็จ
ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Anthropic เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป
ต่อกับ Cursor ได้ แต่ต้องเตรียมก่อน
ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
เปิดแชตของ AI ใน Cursor โหมด Agent
ลองเลย
ใช้ Openapi MCP บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง✓ ถ้า Cursor บอกว่ากำลังใช้ Openapi MCP หรือมีชื่อเครื่องมือของ Openapi MCP ขึ้นในคำตอบ แปลว่าต่อสำเร็จ
ชื่อเมนูตรวจกับหน้าช่วยเหลือของ Cursor เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป
ต่อกับ VS Code ได้ แต่ต้องเตรียมก่อน
ต้องลง Node.js ในเครื่องก่อน (ทำครั้งเดียว)
เปิดแชตของ AI ใน VS Code โหมด Agent
ลองเลย
ใช้ Openapi MCP บอกหน่อยว่าทำอะไรให้ฉันได้บ้าง แล้วลองทำให้ดูหนึ่งอย่าง✓ ถ้า VS Code บอกว่ากำลังใช้ Openapi MCP หรือมีชื่อเครื่องมือของ Openapi MCP ขึ้นในคำตอบ แปลว่าต่อสำเร็จ
ชื่อเมนูตรวจกับหน้าช่วยเหลือของ VS Code เมื่อ 11 พ.ย. 2569 · หน้าจอของคุณอาจต่างเล็กน้อยตามรุ่นของแอป
โปรแกรมอื่นที่ใช้ MCP ได้ เช่น Windsurf, Zed หรือ Gemini CLI มีวิธีเพิ่มต่างกัน ดูวิธีของแต่ละตัวในหน้ารวมโปรแกรม
ค่าตั้งแบบไฟล์ JSON อยู่ในหัวข้อ “สำหรับคนเขียนโค้ด” ด้านล่าง
สำหรับคนเขียนโค้ด: คำสั่ง Terminal และค่าตั้ง JSON
ติดตั้งในเครื่อง
Claude Code
claude mcp add openapi -- npx -y @asthanaji/openapi-mcpClaude Desktop (claude_desktop_config.json)
{
"mcpServers": {
"openapi": {
"command": "npx",
"args": [
"-y",
"@asthanaji/openapi-mcp"
]
}
}
}Cursor (~/.cursor/mcp.json)
{
"mcpServers": {
"openapi": {
"command": "npx",
"args": [
"-y",
"@asthanaji/openapi-mcp"
]
}
}
}VS Code (mcp.json)
{
"servers": {
"openapi": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@asthanaji/openapi-mcp"
]
}
}
}ค่าตั้งนี้สร้างจากข้อมูลใน registry ของผู้ทำ ถ้าไม่ตรงกับ README ให้เชื่อ README
สรุป
- ดาวน์โหลดต่อสัปดาห์i
- 57/สัปดาห์
- การเชื่อมต่อ
- รันบนเครื่อง
- ช่องทาง (transport)
- stdio
- รุ่นล่าสุดi
- 0.1.1
- ส่งเข้า registryi
- 12 ต.ค. 2569
- แก้โค้ดล่าสุดi
- 12 ต.ค. 2569
- ผู้ทำ
- Asthanaji05
- แพ็กเกจ
npm: @asthanaji/openapi-mcp- สถานะใน registry
- ใช้งานอยู่
ใช้กับโปรแกรมไหนได้
ดูจากแบบการต่อของ server ตัวนี้ และเอกสารของผู้ทำโปรแกรมแต่ละตัว ตรวจเมื่อ 10 พ.ย. 2569
ติดตั้งบนเครื่องได้ใน
ClaudeGooseLM StudioMsty StudioCherry StudioCursorVS Code + GitHub CopilotVisual StudioWindsurf (Devin Desktop)ZedKiroClineContinueJetBrains AI AssistantClaude CodeCodex CLIGemini CLIOpenCodenodecodeWarpLibreChatRaycast
คู่มือที่เกี่ยวข้อง
ทำอะไรได้บ้าง
รันในเครื่องคุณ รายการเครื่องมือจะขึ้นในแอป AI หลังติดตั้ง
ผลตรวจเบื้องต้นi
เราตรวจจากข้อมูลที่ใครก็เปิดดูได้ ยังไม่ได้อ่านโค้ด ข้อที่ไม่เกี่ยวกับตัวนี้ไม่นับในตัวหาร · ตรวจเมื่อ 11 พ.ย. 2569
- ✓ ผ่าน
ตัวตนผู้ทำตรงกับ repo
ชื่อใน registry ยืนยันด้วยบัญชี GitHub Asthanaji05 ซึ่งเป็นเจ้าของ repo
- ✓ ผ่าน
ยังมีคนดูแล
มีการแก้โค้ดล่าสุด 30 วันที่ผ่านมา
- ✕ ไม่ผ่าน
มีสัญญาอนุญาต (license)
ไม่พบไฟล์ license ใน repo
- – ไม่เกี่ยว
endpoint ตอบ
ตัวนี้รันบนเครื่องคุณ ไม่มี endpoint บนอินเทอร์เน็ต
- – ไม่เกี่ยว
ล็อกอินแบบ OAuth
ตัวนี้รันบนเครื่อง ใช้ค่าที่ตั้งในเครื่องแทน
- … ยังไม่ตรวจ
คำอธิบายเครื่องมือไม่มีคำสั่งแอบแฝง
รันในเครื่องคุณ เราอ่านรายการเครื่องมือได้เฉพาะตัวที่มี endpoint บนอินเทอร์เน็ต
พูดคุย
ถาม แชร์เคล็ดลับ หรือแจ้งว่าใช้ไม่ได้ เรียงตามที่คนกดว่ามีประโยชน์
ยังไม่มีใครโพสต์ ถามหรือแชร์เป็นคนแรกได้เลย
ข้อความในส่วนนี้เขียนโดยผู้ใช้ ไม่ใช่ทีม PopNx
รีวิวจากผู้ใช้
ยังไม่มีรีวิว
เทียบกับตัวอื่นในหมวด เครื่องมือนักพัฒนาi
- ดาวมากกว่า 0% ของอีก 5760 ตัวในหมวดนี้
- ส่งรุ่นใหม่เข้า registry ล่าสุดกว่า 51% ของอีก 5760 ตัวในหมวดนี้
- ผลตรวจเบื้องต้นดีกว่าหรือเท่ากับ 29% ของอีก 5760 ตัวในหมวดนี้
เทียบกับทุก server ที่ยังใช้งานในหมวดนี้ทั้งทะเบียน ดาวนับเฉพาะเมื่อผู้ลงทะเบียนเป็นเจ้าของ repo
คำถามที่พบบ่อย
Openapi MCP ปลอดภัยไหม?
จากการตรวจเบื้องต้นของเรา ผ่าน 2 จาก 3 ข้อที่ตรวจได้ เรายังไม่ได้อ่านโค้ด ก่อนใส่กุญแจหรือ token ให้ดูว่า server ขอสิทธิ์อะไร และเลือกกุญแจที่ทำได้เท่าที่จำเป็น
ต้องใช้กุญแจหรือรหัสอะไรบ้าง?
registry ไม่ได้ระบุว่าต้องใช้กุญแจ แต่บางตัวจะขอให้ล็อกอินตอนใช้ครั้งแรก
ตัวนี้รันบนเครื่องหรือบนคลาวด์?
รันบนเครื่องของคุณ โปรแกรม AI จะเปิด server ขึ้นมาเองเมื่อใช้ ข้อมูลไม่ต้องผ่านเซิร์ฟเวอร์ของผู้ทำ (ยกเว้นตัวที่ไปเรียกบริการออนไลน์ต่อ)
ยังมีคนดูแลอยู่ไหม?
repo บน GitHub มีการแก้โค้ดล่าสุด 30 วันที่ผ่านมา และส่งรุ่นล่าสุด (0.1.1) เข้า registry 30 วันที่ผ่านมา
ใช้กับโปรแกรมไหนได้บ้าง?
โปรแกรมที่รองรับ MCP เช่น Claude Desktop, Claude Code, Cursor และ VS Code ตัวนี้ต้องมี Node.js ในเครื่องด้วย
มีตัวไหนใช้แทนได้บ้าง?
ในหมวดเดียวกันมี REA, Netdata, Front-End Checklist
ตัวที่ใช้แทนได้
server หมวดเดียวกันจากผู้ทำคนอื่น เรียงตามดาว
อ่านการ์ด:↓ ดาวน์โหลดต่อสัปดาห์i★ ดาว GitHubiสามเสา: รีวิว · ผลตรวจ · การใช้งานiอัปเดต = วันที่ส่งรุ่นล่าสุดเข้า registryi
README จากผู้ทำ
เปิดอ่าน README
ส่วนนี้คัดจาก repo ของผู้ทำตามต้นฉบับ PopNx MCP ไม่ได้ตรวจหรือรับรองเนื้อหา ตัด HTML รูปภาพ และสคริปต์ออกแล้ว ลิงก์จะพาออกนอกเว็บ
OpenAPI MCP
Turn any OpenAPI 3 spec into a working MCP server. One file, about 130 lines, no dependencies.
node openapi-mcp.mjs https://your-api.com/openapi.json
Every API endpoint becomes a tool that an AI client (Claude, Cursor, etc.) can call. There is no code generation and no per-endpoint files. The spec is read at startup, and the tools are built in memory.
Quick start
Requires Node 18 or newer.
git clone <this-repo>
cd openapi-mcp node openapi-mcp.mjs sample/animechan.openapi.json
It prints openapi-mcp: 4 tools from "Animechan" -> ... and then waits silently for an MCP client. That is normal: it talks JSON-RPC over stdin/stdout and is not meant to be read by humans.
Use it with an AI client
Claude Desktop (local mode)
Add this to ~/Library/Application Support/Claude/claude_desktop_config.json, then restart the app:
{
"mcpServers": { "animechan": { "command": "node", "args": ["/full/path/openapi-mcp.mjs", "/full/path/animechan.openapi.json"] } } }
If the client can't find node, use the full path from which node.
Claude Code (remote mode)
Start the server, then register it:
MCP_AUTH_TOKEN=secret node openapi-mcp.mjs sample/animechan.openapi.json --http 8787
claude mcp add --transport http animechan http://localhost:8787/mcp \ --header "Authorization: Bearer secret"
Then ask in plain English: "give me a random quote from Naruto".
Two modes
| Mode | Command | Use when |
|---|---|---|
| Local (stdio) | node openapi-mcp.mjs | The client launches the server on your machine |
| Remote (HTTP) | node openapi-mcp.mjs --http | The client connects to a URL, or you want to self-host |
In HTTP mode, clients send JSON-RPC messages as POST http://host: /mcp. Put --http last.
Test it by hand:
curl -X POST localhost:8787/mcp -H 'Authorization: Bearer secret' \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'
Options
node openapi-mcp.mjs <spec-url-or-file> [base-url] [--http <port>]
| Argument / env var | What it does | |
|---|---|---|
| OpenAPI 3 spec, as a URL or a local file (JSON; YAML needs npm i yaml) | |
[base-url] | Overrides the API address. Defaults to servers[0].url in the spec | |
API_TOKEN | Your secret for the API. The spec's securitySchemes decide where it goes (see Authentication) | |
OAUTH_CLIENT_ID, OAUTH_CLIENT_SECRET | OAuth2 client-credentials: the token is fetched and refreshed automatically | |
OAUTH_REFRESH_TOKEN | OAuth2 refresh-token grant (use with the client id and secret) | |
OAUTH_TOKEN_URL, OAUTH_SCOPE | Optional: override the tokenUrl from the spec, or request a scope | |
API_HEADERS | Extra headers sent on every call, for anything the schemes don't cover. Example: '{"X-App-Id":"abc"}' | |
TOOL_FILTER | Regex. Only tools whose name matches are exposed. Example: `'^(get\ | list)'` for read-only |
MCP_AUTH_TOKEN | HTTP mode only. Requires Authorization: Bearer on every request |
Big APIs can have hundreds of endpoints. Too many tools makes the model choose worse, so use TOOL_FILTER to keep the useful ones.
Authentication
The server reads securitySchemes from the spec and puts your secret in the right place. You only supply the secret as an environment variable:
| Spec says | Set | Sent as |
|---|---|---|
http / bearer | API_TOKEN=tok | Authorization: Bearer tok |
http / basic | API_TOKEN=user:pass | Authorization: Basic |
apiKey in header | API_TOKEN=key | The header named in the spec (e.g. X-Key: key) |
apiKey in query | API_TOKEN=key | The query parameter named in the spec |
apiKey in cookie | API_TOKEN=key | Cookie: name=key |
oauth2 / openIdConnect, you already have an access token | API_TOKEN=token | Authorization: Bearer token |
oauth2, machine-to-machine | OAUTH_CLIENT_ID + OAUTH_CLIENT_SECRET | Token fetched from the tokenUrl, cached, and renewed before it expires |
oauth2, you logged in once elsewhere | the two above + OAUTH_REFRESH_TOKEN | Access tokens renewed from the refresh token |
Example for Claude Desktop:
{
"mcpServers": { "my-api": { "command": "node", "args": ["/full/path/openapi-mcp.mjs", "https://my-api.com/openapi.json"], "env": { "API_TOKEN": "your-secret" } } } }
Notes:
- If the spec declares a security scheme but no credentials are set, a warning is printed to stderr at startup.
- If the spec lists several schemes, the first one in the top-level
securitylist is used (or the first one defined). Per-endpointsecurityoverrides are not applied, so the secret is sent on every call. - OAuth client credentials are sent as HTTP Basic auth to the token endpoint.
- The OAuth browser login (authorization-code flow) is not built in. Get a token or refresh token once with your provider's tools, then pass it in.
- If a provider rotates refresh tokens, the new one is kept in memory only, so it is lost on restart.
How it works
- Load the spec and resolve
$refpointers. - Build tools: each operation becomes one MCP tool.
operationIdis the name,summarythe description, and parameters plus request body the input schema. - Call: a tool call makes the real HTTP request and returns
HTTPfollowed by the response body (cut at 50,000 characters). - Serve the tools over JSON-RPC 2.0, via stdio or HTTP.
APIs without an OpenAPI spec
Many small public APIs only have HTML docs. For those, write a small spec by hand (see sample/animechan.openapi.json, 4 tools in about 35 lines), then run it the same way.
Limitations
- OpenAPI 3 only. Convert Swagger 2.0 specs first.
- JSON request bodies only. No file uploads.
- Auth: bearer, basic, API keys, and OAuth2 client-credentials or refresh-token. There is no interactive OAuth login, and one scheme is used per API.
- HTTP mode speaks plain HTTP (put HTTPS in front when deploying) and has no streaming, batch requests, or OAuth for clients connecting to the server (it only supports the
MCP_AUTH_TOKENbearer token). Some remote clients may require these. - HTTP mode speaks plain HTTP (put HTTPS in front when deploying) and has no streaming, batch requests, or OAuth. Some remote clients may require these.
- If you deploy remotely, every user shares your server's IP, so upstream rate limits apply to all of them. Set
MCP_AUTH_TOKEN, or anyone who finds the URL can use your API key.
Contributing
Issues and pull requests are welcome. The goal is to stay small and readable, so please keep new features to a few lines each.