bro-in-law
MCP Serverbro-in-lawpublic

mcp demo backend

mcp示例 后端服务

Repository Info

1
Stars
0
Forks
1
Watchers
0
Issues
Python
Language
-
License

About This Server

mcp示例 后端服务

Model Context Protocol (MCP) - This server can be integrated with AI applications to provide additional context and capabilities, enabling enhanced AI interactions and functionality.

Documentation

健康数据 API 服务

这是一个基于 Flask 的轻量级健康数据 API 服务,用于管理用户信息和健康数据。

项目结构

项目/
├── app.py          # 主应用文件,包含 API 路由
├── models.py       # 数据模型,处理数据读写
├── config.py       # 配置文件
├── data/           # 数据目录
│   ├── user.json   # 用户数据
│   └── health.json # 健康数据
└── requirements.txt # 项目依赖

安装依赖

pip install -r requirements.txt

运行服务

python app.py

服务将在 http://127.0.0.1:5000 启动

API 端点

初始化示例数据

GET /api/init

生成并保存示例用户数据和健康数据。首次运行应用时需要调用此 API。

用户信息

GET /api/user

返回用户的基本信息(姓名、年龄、联系方式等)。

更新用户信息

PUT /api/user
Content-Type: application/json

{
  "name": "李四",
  "age": 50,
  "contact": "13900139000"
}

通过 JSON 更新用户信息,可以更新任意字段。

健康数据查询

GET /api/health?start_date=2023-01-01&end_date=2023-01-31&metric=blood_pressure

按时间范围和指标查询健康数据。

查询参数:

  • start_date: 开始日期 (YYYY-MM-DD),可选
  • end_date: 结束日期 (YYYY-MM-DD),可选
  • metric: 健康指标类型,例如 'blood_pressure',可选

不提供任何参数时,返回所有健康数据。

Quick Start

1

Clone the repository

git clone https://github.com/bro-in-law/mcp-demo-backend
2

Install dependencies

cd mcp-demo-backend
npm install
3

Follow the documentation

Check the repository's README.md file for specific installation and usage instructions.

Repository Details

Ownerbro-in-law
Repomcp-demo-backend
LanguagePython
License-
Last fetched8/10/2025

Recommended MCP Servers

💬

Discord MCP

Enable AI assistants to seamlessly interact with Discord servers, channels, and messages.

integrationsdiscordchat
🔗

Knit MCP

Connect AI agents to 200+ SaaS applications and automate workflows.

integrationsautomationsaas
🕷️

Apify MCP Server

Deploy and interact with Apify actors for web scraping and data extraction.

apifycrawlerdata
🌐

BrowserStack MCP

BrowserStack MCP Server for automated testing across multiple browsers.

testingqabrowsers

Zapier MCP

A Zapier server that provides automation capabilities for various apps.

zapierautomation