MongoDB + MCP + Claude 프로젝트 (계속) (260205)

WonTerry·2026년 2월 5일

MCP

목록 보기
14/23

Mongodb_MCP를 이용하여 체중 변화를 나타내주세요. 그리고 요청을 처리하는 과정에서 MCP 서버와 주고 받는 데이터(JSON)의 원본을 모두 나타내주세요.

📊 MCP 서버 통신 데이터
1. Schema 조회 요청

Tool: MongoDB_MCP:get_collection_schema
Parameters: (없음)
  1. Schema 조회 응답 (일부)
{
  "schema": {
    "collection": "DailyLog",
    "database": "TerryDB",
    "description": "일일 건강 및 활동 로그",
    "fields": {
      "date": {
        "type": "date",
        "description": "기록 날짜"
      },
      "inbody": {
        "type": "object",
        "fields": {
          "weight": {
            "type": "float"
          },
          "muscle": {
            "type": "float"
          },
          "fatper": {
            "type": "float"
          }
        }
      },
      ...
    }
  },
  "statistics": {
    "document_count": 18,
    ...
  }
}
  1. Aggregation Pipeline 요청
Tool: MongoDB_MCP:execute_aggregation
Parameters:
{
  "pipeline": [
    {
      "$match": {
        "inbody.weight": {
          "$exists": true
        }
      }
    },
    {
      "$project": {
        "_id": 0,
        "date": 1,
        "weight": "$inbody.weight",
        "muscle": "$inbody.muscle",
        "fatper": "$inbody.fatper"
      }
    },
    {
      "$sort": {
        "date": 1
      }
    }
  ],
  "limit": 100
}
  1. Aggregation 응답 (전체 데이터)
{
  "success": true,
  "pipeline": [
    {
      "$match": {
        "inbody.weight": {
          "$exists": true
        }
      }
    },
    {
      "$project": {
        "_id": 0,
        "date": 1,
        "weight": "$inbody.weight",
        "muscle": "$inbody.muscle",
        "fatper": "$inbody.fatper"
      }
    },
    {
      "$sort": {
        "date": 1
      }
    }
  ],
  "result_count": 18,
  "results": [
    {
      "date": "2026-01-19",
      "weight": 00.0,
      "muscle": 00.0,
      "fatper": 00.0
    },
    
    ...
    ```
profile
Hello, I'm Terry! 👋 Enjoy every moment of your life! 🌱 My current interests are Signal processing, Machine learning, Python, Database, LLM & RAG, MCP & ADK, Multi-Agents, Physical AI, ROS2...

0개의 댓글