loki-mcp
Verified Safeby grafana
Overview
A Go-based server that implements the Model Context Protocol (MCP) to integrate Grafana Loki log querying capabilities with AI agents like Claude Desktop or n8n.
Installation
docker run --rm -i loki-mcp-serverEnvironment Variables
- LOKI_URL
- LOKI_ORG_ID
- LOKI_USERNAME
- LOKI_PASSWORD
- LOKI_TOKEN
- PORT
Security Notes
The server uses standard Go libraries for HTTP requests and URL parsing, which correctly handles parameter escaping and mitigates common injection vulnerabilities. It retrieves sensitive credentials (Loki URL, authentication details, organization ID) from environment variables or request parameters, adhering to best practices for secret management. The README explicitly warns users about securing these credentials. No 'eval' or other dangerous dynamic code execution patterns were found. The primary security consideration for users is the safe handling of their `LOKI_USERNAME`, `LOKI_PASSWORD`, or `LOKI_TOKEN` environment variables outside of the application.
Similar Servers
mcp-k8s-go
This MCP server enables interaction with Kubernetes clusters to list, get, apply, and execute commands on various resources through a conversational interface.
mcp-cli
A command-line interface tool for managing Model Context Protocol (MCP) server configuration files across various AI tools.
mcp-sdk-go
A Go SDK for building applications that communicate with large language models and external tools via the Model Context Protocol (MCP), supporting both client and server implementations.
GeminiMCP
Integrate Google's Gemini API for AI-powered tasks and search with Model Control Protocol (MCP) clients, focusing on developer-centric features like code analysis and context handling.