gramcp MCP
A Rust-based Telegram MCP server that acts as a secure proxy for AI agents. It connects to a user's personal Telegram account via MTProto, allowing tools to read chats, triage messages, search history, and send replies. It includes security features like prompt injection protection, tool whitelisting, and audit logging to mitigate risks when agents interact with untrusted chat inputs.
Package and access
Local package with source-attributed installation metadata. Koskamo does not execute packages during review.
What you can do with it
- Read and triage unread Telegram messages
- Search chat history for specific information
- Draft and send replies to contacts or groups
- Protect agent interactions from prompt injection attacks
Source and maintenance
- Maintenance checked
Packages and installation
Source-provided package data. Koskamo has not executed or live-probed this package.
ghcr.io/ilodezis/gramcp:0.1.0
{
"transport": "stdio",
"identifier": "ghcr.io/ilodezis/gramcp:0.1.0",
"registryType": "oci",
"packageArguments": [
{
"type": "positional",
"value": "serve"
},
{
"name": "--stdio",
"type": "named"
}
],
"runtimeArguments": [
{
"name": "-v",
"type": "named",
"value": "{volume}:/data",
"variables": {
"volume": {
"default": "gramcp-data",
"isRequired": true,
"description": "Docker volume name or absolute host path"
}
},
"isRequired": true,
"description": "Volume holding the Telegram session, state.db, and outbox. Sign in once with `docker run --rm -it -v gramcp-data:/data -e TELEGRAM_API_ID -e TELEGRAM_API_HASH ghcr.io/ilodezis/gramcp login`."
}
],
"environmentVariables": [
{
"name": "TELEGRAM_API_ID",
"format": "number",
"isRequired": true,
"description": "Telegram api_id from my.telegram.org"
},
{
"name": "TELEGRAM_API_HASH",
"isRequired": true,
"description": "Telegram api_hash from my.telegram.org"
}
]
}Tools
Reported by the attributed source; not independently observed by Koskamo.
Connect from your client
Each snippet configures the same source-provided package; replace placeholders before use.
Cursor
{
"mcpServers": {
"gramcp-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"TELEGRAM_API_ID=<YOUR_TELEGRAM_API_ID>",
"-e",
"TELEGRAM_API_HASH=<YOUR_TELEGRAM_API_HASH>",
"ghcr.io/ilodezis/gramcp:0.1.0",
"serve"
],
"env": {
"TELEGRAM_API_ID": "<YOUR_TELEGRAM_API_ID>",
"TELEGRAM_API_HASH": "<YOUR_TELEGRAM_API_HASH>"
}
}
}
}Cline
{
"mcpServers": {
"gramcp-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"TELEGRAM_API_ID=<YOUR_TELEGRAM_API_ID>",
"-e",
"TELEGRAM_API_HASH=<YOUR_TELEGRAM_API_HASH>",
"ghcr.io/ilodezis/gramcp:0.1.0",
"serve"
],
"env": {
"TELEGRAM_API_ID": "<YOUR_TELEGRAM_API_ID>",
"TELEGRAM_API_HASH": "<YOUR_TELEGRAM_API_HASH>"
}
}
}
}VS Code
{
"servers": {
"gramcp-mcp": {
"type": "stdio",
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"TELEGRAM_API_ID=<YOUR_TELEGRAM_API_ID>",
"-e",
"TELEGRAM_API_HASH=<YOUR_TELEGRAM_API_HASH>",
"ghcr.io/ilodezis/gramcp:0.1.0",
"serve"
],
"env": {
"TELEGRAM_API_ID": "<YOUR_TELEGRAM_API_ID>",
"TELEGRAM_API_HASH": "<YOUR_TELEGRAM_API_HASH>"
}
}
}
}Claude Desktop
{
"mcpServers": {
"gramcp-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"-e",
"TELEGRAM_API_ID=<YOUR_TELEGRAM_API_ID>",
"-e",
"TELEGRAM_API_HASH=<YOUR_TELEGRAM_API_HASH>",
"ghcr.io/ilodezis/gramcp:0.1.0",
"serve"
],
"env": {
"TELEGRAM_API_ID": "<YOUR_TELEGRAM_API_ID>",
"TELEGRAM_API_HASH": "<YOUR_TELEGRAM_API_HASH>"
}
}
}
}Let your agent find its tools
Find servers like gramcp MCP from your agent. Add Koskamo once to search the index for endpoints, access requirements, and client setup. Public discovery needs no key.