librelink
MCP server to connect with Freestyle Libre Link and bring CGM data into LLMs
claude mcp add --transport stdio amansk-librelink-mcp-server node /path/to/librelink-mcp-server/dist/index.js \ --env LIBRELINK_EMAIL="LibreLink account email" \ --env LIBRELINK_REGION="Region (US/EU)" \ --env LIBRELINK_PASSWORD="LibreLink account password" \ --env LIBRELINK_TARGET_LOW="Default target low glucose (mg/dL)" \ --env LIBRELINK_TARGET_HIGH="Default target high glucose (mg/dL)"
How to use
LibreLink MCP Server provides local, privacy-focused access to your FreeStyle LibreLink CGM data via the MCP protocol. It runs as a Node.js application and exposes tools that Claude Desktop can query to retrieve real-time readings, historical glucose data, analytics, and pattern insights. The server includes capabilities for real-time glucose, historical history, time-in-range calculations, trend analysis, sensor status, credential management, and configuration of target ranges. Once running, you can configure Claude Desktop to connect to the local MCP server by adding the server entry to your claude_desktop_config.json, specifying the Node process and the path to the compiled server bundle.
Available tools include: get_current_glucose (real-time reading with trend), get_glucose_history (historical data with hours parameter), get_glucose_stats (time-in-range and summary metrics), get_glucose_trends (pattern analysis over a period), get_sensor_info (sensor status), configure_credentials (update LibreLink credentials), configure_ranges (set glucose targets), and validate_connection (test the LibreLink connection). You can then ask Claude Desktop natural language questions such as: What is my current glucose level? Show my glucose readings from the past 6 hours, or Calculate my time in range for this week. The tools return structured data (JSON) that Claude can interpret to present insights and dashboards.
How to install
Prerequisites:
- Node.js 18.x or higher installed on your machine
- npm (comes with Node.js) or pnpm/yarn if preferred
- Git (for cloning, if you install from Git repository)
Installation steps:
-
Clone the repository (or download the npm package):
git clone https://github.com/yourusername/librelink-mcp-server.git cd librelink-mcp-server
-
Install dependencies:
npm install
-
Build the project (if applicable):
npm run build
-
Configure credentials and region (example):
npm run configure
You will be prompted for:
- Email: your LibreLink account email
- Password: your LibreLink account password
- Region: US or EU
- Target ranges: default glucose target range (e.g., 70-180)
-
Run tests or start the MCP server locally:
npm test # optional npm run start # starts the server (or run your own node dist/index.js)
-
Integrate with Claude Desktop by updating claude_desktop_config.json as shown in the README.
Note: If you are not building locally, you can install via npm and run the built bundle from dist/index.js with node.
Additional notes
Tips and common notes:
- Ensure your LibreLink credentials and region are valid; misconfigured region is a common cause of authentication failures.
- The server stores credentials locally in a config file (default: ~/.librelink-mcp/config.json). Ensure the file has restrictive permissions (600).
- When integrating with Claude Desktop, point to the compiled server bundle (dist/index.js) and keep it updated with any rebuilds after code changes.
- The MCP server is designed for local data processing; no data is sent to external servers by default.
- If you encounter connection timeouts, verify your internet connectivity temporarily and re-check LibreLink service status.
- Review the Troubleshooting section in the README for common issues and diagnostic commands like node diagnose-account.js and node test-real-connection.js.
Related MCP Servers
zen
Selfhosted notes app. Single golang binary, notes stored as markdown within SQLite, full-text search, very low resource usage
MCP -Deepseek_R1
A Model Context Protocol (MCP) server implementation connecting Claude Desktop with DeepSeek's language models (R1/V3)
mcp-fhir
A Model Context Protocol implementation for FHIR
mcp
Inkdrop Model Context Protocol Server
mcp-appium-gestures
This is a Model Context Protocol (MCP) server providing resources and tools for Appium mobile gestures using Actions API..
dubco -npm
The (Unofficial) dubco-mcp-server enables AI assistants to manage Dub.co short links via the Model Context Protocol. It provides three MCP tools: create_link for generating new short URLs, update_link for modifying existing links, and delete_link for removing short links.