Habit Tracker MCP Server
Enables users to analyze their habits over a specified period and receive weekly reviews through natural language prompts.
README
Habit Tracker API
π° REST API
π° JWT-based authentication
π° MCP server with stdio transport
π Litestar, FastMCP, SQLAlchemy-advanced, Alembic, Pydantic, Pytest
Prereq
- Python 3.11
- Docker/docker compose (v2)
Envs
- prod
- dev
- test
ΠΠ»ΠΎΠ½ΠΈΡΠΎΠ²Π°Π½ΠΈΠ΅ ΡΠ΅ΠΏΠΎΠ·ΠΈΡΠΎΡΠΈΡ
git clone git@github.com:darialissi/litestar-habittracker.git && cd litestar-habittracker
Π‘Π±ΠΎΡΠΊΠ° ΠΈ Π·Π°ΠΏΡΡΠΊ ΠΏΡΠΈΠ»ΠΎΠΆΠ΅Π½ΠΈΡ ΠΈ Π΅Π³ΠΎ Π·Π°Π²ΠΈΡΠΈΠΌΠΎΡΡΠ΅ΠΉ [prod]
docker compose --profile prod up
ΠΠ½ΡΠ΅ΡΠ°ΠΊΡΠΈΠ²Π½Π°Ρ Π΄ΠΎΠΊΡΠΌΠ΅Π½ΡΠ°ΡΠΈΡ Π΄ΠΎΡΡΡΠΏΠ½Π° Π½Π° http://127.0.0.1:8000/docs

ΠΠΎΠΊΠ°Π»ΡΠ½Π°Ρ ΠΊΠΎΠ½ΡΠΈΠ³ΡΡΠ°ΡΠΈΡ ΠΈ Π·Π°ΠΏΡΡΠΊ ΠΏΡΠΈΠ»ΠΎΠΆΠ΅Π½ΠΈΡ [dev]
- ΠΠ° ΠΎΡΠ½ΠΎΠ²Π΅ .env.example ΡΠΎΠ·Π΄Π°ΡΡ .env Π² ΠΊΠΎΡΠ½Π΅ ΠΏΡΠΎΠ΅ΠΊΡΠ°
- ΠΠ°ΠΏΡΡΡΠΈΡΡ ΡΠ΅ΡΠ΅Π· ΠΎΠ±ΠΎΠ»ΠΎΡΠΊΡ dev.sh (ΠΏΡΠΈ Π½Π΅ΠΎΠ±Ρ
ΠΎΠ΄ΠΈΠΌΠΎΡΡΠΈ ΡΠ΄Π΅Π»Π°ΡΡ ΡΠ°ΠΉΠ» ΠΈΡΠΏΠΎΠ»Π½ΡΠ΅ΠΌΡΠΌ:
chmod +x dev.sh)
Π’Π΅ΡΡΠΈΡΠΎΠ²Π°Π½ΠΈΠ΅ [test]
Unit
pytest -m unit
Integration
pytest -m integration
# just validation without DB
pytest -m validation
E2E (+ load)
# ΠΠΎΠ΄Π½ΠΈΠΌΠ°Π΅ΠΌ ΡΠ΅ΡΡΠΎΠ²ΡΡ ΠΠ
docker compose --profile test up -d
pytest -m e2e
pytest -s -m load
MCP configuration
Π’ΠΎΠΊΠ΅Π½ ΠΌΠΎΠΆΠ½ΠΎ ΠΏΠΎΠ»ΡΡΠΈΡΡ ΡΠ΅ΡΠ΅Π· GET /api/account/token
"mcpServers": {
"mcp-habittracker": {
"command": "/Users/lissi/Projects/litestar-habittracker/.venv/bin/python3",
"args": [
"/Users/lissi/Projects/litestar-habittracker/src/app_mcp.py"
],
"env": {
"MCP_AUTH_TOKEN": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
}
}
ΠΡΠΈΠΌΠ΅ΡΡ ΠΏΡΠΎΠΌΠΏΡΠΎΠ²
ΠΡΠΏΠΎΠ»Π½ΠΈ Π°Π½Π°Π»ΠΈΠ· ΠΌΠΎΠΈΡ
ΠΏΡΠΈΠ²ΡΡΠ΅ΠΊ Π·Π° ΠΏΠΎΡΠ»Π΅Π΄Π½ΠΈΠ΅ 10 Π΄Π½Π΅ΠΉ.
Π‘ΠΈΡΡΠ΅ΠΌΠ½ΡΠ΅ ΠΏΡΠΎΠΌΠΏΡΡ (ΡΠ΄ΠΎΠ±Π½Π΅Π΅ ΠΈΡΠΏΠΎΠ»ΡΠ·ΠΎΠ²Π°ΡΡ ΡΠ΅ΡΠ΅Π· ΠΈΠ½ΡΠ΅ΡΡΠ΅ΠΉΡ ΠΊΠ»ΠΈΠ΅Π½ΡΠ°)
# Ρ ΡΠΊΠ°Π·Π°Π½ΠΈΠ΅ΠΌ ΠΊΠΎΠ»-Π²Π° Π΄Π½Π΅ΠΉ Π΄Π»Ρ Π°Π½Π°Π»ΠΈΠ·Π°
habits_analysis 5 Π΄Π½Π΅ΠΉ
weekly_review
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.