Skip to main content
Glama
flamekk

MCP Streamable HTTP Demo

by flamekk

TP5 MCP 스트리밍 가능 HTTP 데모

이 프로젝트는 다음 데모 목표를 재현합니다:

  • 두 가지 도구를 노출하는 MCP 서버.

  • @modelcontextprotocol/inspector를 사용한 테스트.

  • Streamable HTTP를 통해 MCP를 사용하는 LangChain/LangGraph 호환 에이전트.

  • Streamable HTTP를 통해 MCP를 사용하는 n8n AI 에이전트 설정.

중요한 보안 참고 사항

프롬프트에 붙여넣은 OpenAI 키가 채팅에 노출되었습니다. 에이전트를 실행하기 전에 해당 키를 취소하고 새 키를 생성하십시오. 새 키를 .env에 넣으십시오. 커밋하지 마십시오.

설정

Copy-Item .env.example .env
npm install

.env를 편집하고 다음을 설정하십시오:

OPENAI_API_KEY=your_new_key

MCP 서버 시작

npm run server

MCP 엔드포인트는 다음과 같습니다:

http://127.0.0.1:3000/mcp

상태 확인(health) 엔드포인트는 다음과 같습니다:

http://127.0.0.1:3000/health

MCP Inspector로 테스트

한 터미널에서 서버를 계속 실행하십시오:

npm run server

다른 터미널에서 Inspector CLI를 사용하여 도구 목록을 확인하십시오:

npm run inspector:list-tools

Windows에서 현재 Inspector CLI는 올바른 JSON 응답을 출력한 후 Node/libuv 어설션과 함께 종료될 수 있습니다. tools JSON에 calculatetext_stats가 포함되어 있다면 MCP 호출 자체는 성공한 것입니다.

Inspector CLI로 도구를 호출하십시오:

npx --yes @modelcontextprotocol/inspector --cli http://127.0.0.1:3000/mcp --transport http --method tools/call --tool-name calculate --tool-arg operation=add --tool-arg "numbers=[2,3,4]"

Inspector UI를 열 수도 있습니다:

npm run inspector

그런 다음 선택하십시오:

Transport: Streamable HTTP
URL: http://127.0.0.1:3000/mcp

로컬 스모크 테스트

npm run smoke

이것은 MCP 도구 목록을 나열하고 calculate를 호출합니다.

LangChain 에이전트

서버가 실행 중이고 .env에 유효하게 교체된 OPENAI_API_KEY가 포함되어 있는지 확인하십시오.

npm run agent

사용자 지정 프롬프트:

npm run agent -- "Calcule 42 / 6 puis analyse le texte: Bonjour depuis MCP."

n8n 에이전트

docs/n8n-agent.md를 따르십시오.

n8n MCP 클라이언트 도구 구성은 다음과 같습니다:

Endpoint: http://127.0.0.1:3000/mcp
Server Transport: HTTP Streamable
Authentication: None
Tools to Include: All
F
license - not found
-
quality - not tested
C
maintenance

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/flamekk/Model-Context-Protocol'

If you have feedback or need assistance with the MCP directory API, please join our Discord server