{"$schema":"https://wellknown.network/schemas/agent-record-v1.json","schemaVersion":"1","id":"ag_c3v6c8k2h4dv","handle":"grafana-loki-mcp","url":"https://wellknown.network/agents/grafana-loki-mcp","links":{"self":"https://wellknown.network/agents/grafana-loki-mcp/record.json","html":"https://wellknown.network/agents/grafana-loki-mcp","markdown":"https://wellknown.network/agents/grafana-loki-mcp/record.md","api":"https://wellknown.network/api/v1/agents/grafana-loki-mcp","status":"https://wellknown.network/api/v1/agents/grafana-loki-mcp/status","claim":"https://wellknown.network/agents/grafana-loki-mcp/claim","claimApi":"https://wellknown.network/api/v1/claims","claimDescriptor":"https://wellknown.network/agents/grafana-loki-mcp/claim.json","badge":"https://wellknown.network/agents/grafana-loki-mcp/badge.svg","openapi":"https://wellknown.network/openapi.json","history":"https://wellknown.network/api/v1/agents/grafana-loki-mcp/history","tools":"https://wellknown.network/api/v1/agents/grafana-loki-mcp/tools"},"ard":{"identifier":"urn:air::server:grafana-loki-mcp","type":"application/mcp-server-card+json"},"kind":"mcp_server","declared":{"name":"grafana-loki-mcp","summary":"A FastMCP server for querying Loki logs from Grafana","description":"# Grafana-Loki MCP Server\n\n[![Test](https://github.com/tumf/grafana-loki-mcp/actions/workflows/test.yml/badge.svg)](https://github.com/tumf/grafana-loki-mcp/actions/workflows/test.yml)\n[![PyPI version](https://badge.fury.io/py/grafana-loki-mcp.svg)](https://badge.fury.io/py/grafana-loki-mcp)\n[![codecov](https://codecov.io/gh/tumf/grafana-loki-mcp/branch/main/graph/badge.svg)](https://codecov.io/gh/tumf/grafana-loki-mcp)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\nA [FastMCP](https://github.com/jlowin/fastmcp) server that allows querying Loki logs from Grafana.\n\n## MCP Server Settings\n\n```json\n{\n  \"mcpServers\": {\n    \"loki\": {\n      \"command\": \"uvx\",\n      \"args\": [\n        \"grafana-loki-mcp\",\n        \"-u\",\n        \"GRAFANA_URL\",\n        \"-k\",\n        \"GRAFANA_API_KEY\"\n      ]\n    }\n  }\n}\n```\n\n- `GRAFANA_URL`: URL of your Grafana instance\n- `GRAFANA_API_KEY`: Grafana API key with appropriate permissions\n\n## Features\n\n- Query Loki logs through Grafana API\n- Get Loki labels and label values\n- Format query results in different formats (text, JSON, markdown)\n- Support for both stdio and SSE transport protocols\n\n## Requirements\n\n- Python 3.10+\n- FastMCP\n- Requests\n\n## Installation\n\n### Using pip\n\n```bash\npip install grafana-loki-mcp\n```\n\n### Development Setup\n\n1. Clone this repository\n2. Install dependencies using uv:\n\n```bash\n# Install uv\npip install uv\n\n# Create and activate virtual environment\nuv venv\nsource .venv/bin/activate  # On Windows: .venv\\Scripts\\activate\n\n# Install dependencies\nuv pip install -e \".[dev]\"\n```\n\n## Usage\n\n### Environment Variables\n\nSet the following environment variables:\n\n- `GRAFANA_URL`: URL of your Grafana instance\n- `GRAFANA_API_KEY`: Grafana API key with appropriate permissions\n\n### Command Line Arguments\n\nYou can also provide these values as command line arguments:\n\n```bash\ngrafana-loki-mcp -u https://your-grafana-instance.com -k your-api-key\n```\n\nAdditional options:\n- `--tr…","publisher":null,"homepage":"https://github.com/tumf/grafana-loki-mcp","repository":"https://github.com/tumf/grafana-loki-mcp","version":"0.1.4","license":"MIT License\n        \n        Copyright (c) 2024 tumf\n        \n …","protocols":["mcp"],"tags":["mcp"],"pricing":null,"endpoints":[{"url":"pypi:grafana-loki-mcp","type":"package_pypi","auth":null,"probeable":false}],"skills":null,"tools":null,"extra":null,"attribution":{"kind":"pypi","name":"pypi","license":"pypi","repoUrl":"pypi","summary":"pypi","version":"pypi","description":"pypi","homepageUrl":"pypi"}},"derived":{"capabilities":[{"slug":"dev.monitoring","name":"Monitoring & Observability","confidence":1,"provenance":"derived"},{"slug":"dev.version-control","name":"Version Control","confidence":0.825,"provenance":"derived"},{"slug":"dev.package-management","name":"Packages & Dependencies","confidence":0.825,"provenance":"derived"},{"slug":"dev.terminal","name":"Terminal & Shell","confidence":0.825,"provenance":"derived"}],"categories":["dev"],"language":"en"},"observed":{"status":"unknown","statusReason":"Distributed as a package to run locally; no network endpoint to check.","lastOkAt":null,"lastProbedAt":null,"statusComputedAt":null,"reliability30d":null,"latestObservations":[],"tools":null,"package":{"name":"grafana-loki-mcp","registry":"pypi","observedAt":"2026-11-03T04:24:09.776Z","publishedAt":"2025-06-18T22:00:32.045894Z","latestVersion":"0.1.4"},"toolSurface":null,"endpointFacts":[]},"verification":{"claimed":false,"claimedAt":null,"proofs":[]},"provenance":{"sources":[{"source":"pypi","key":"grafana-loki-mcp","url":"https://pypi.org/project/grafana-loki-mcp/","firstSeenAt":"2026-09-09T16:24:46.263Z","fetchedAt":"2026-11-03T04:22:51.630Z","normalizedAt":"2026-11-03T04:22:51.630Z"}]},"firstSeenAt":"2026-09-09T16:24:46.263Z","updatedAt":"2026-11-03T04:24:09.776Z"}