tgcli MCP server
2026년 11월 12일 커밋MTProto를 통해 개인 계정으로 Telegram 메시지를 검색, 아카이브 및 전송할 수 있는 AI 클라이언트를 제공합니다.
다른 이름 kfastov/tgcli
- 스타
- 45
- Tools
- —
- 다운로드, 30일
- —
- 최신 버전
- —
- 마지막 커밋
- 2026년 11월 12일
- 라이선스
- MIT
tgcli MCP란?
MTProto를 통해 개인 계정으로 Telegram 메시지를 검색, 아카이브 및 전송할 수 있는 AI 클라이언트를 제공합니다.
프로젝트 README에서 생성된 요약
tgcli MCP server 정보
tgcli를 사용하면 AI 클라이언트를 통해 개인 Telegram 통신을 관리할 수 있습니다. 이 도구는 표준 bot API 대신 MTProto 프로토콜을 사용하여 메시지를 검색, 아카이브 및 전송할 수 있게 해줍니다. 로컬 환경에서 작동하며, 개인 계정 인증을 위해 Telegram 개발자 포털에서 발급받은 api_id와 api_hash가 필요합니다.
개발자는 구성 설정을 통해 MCP 기능을 활성화하여 선호하는 AI 클라이언트에 연결할 수 있습니다. 활성화되면 서버는 127.0.0.1:8080과 같이 사용자가 선택한 로컬 호스트 및 포트에서 실행됩니다. 시스템은 메시지 데이터베이스와 세션 파일을 포함하는 로컬 스토어를 통해 데이터를 관리합니다. 그룹 토픽 관리, 미디어 다운로드, 아카이브된 메시지 검색, 채널 태그 및 메타데이터 처리 등 다양한 특정 작업을 지원합니다.
사용자는 tgcli 커맨드 라인을 통해 서버를 시작하거나 백그라운드 동기화 서비스를 관리하며 시스템과 상호작용합니다. 이 도구는 연락처, 그룹 및 채널 메타데이터에 대한 특화된 명령어를 제공하여 AI가 사용자의 Telegram 환경을 포괄적으로 파악할 수 있도록 지원합니다.
활용 사례
- 1아카이브된 메시지 검색아카이브된 Telegram 기록 내에서 특정 정보를 AI에게 찾아달라고 요청합니다.
- 2Telegram 메시지 전송AI 클라이언트에 특정 연락처나 사용자 이름으로 텍스트 메시지 또는 파일을 보내도록 지시합니다.
- 3미디어 파일 다운로드AI가 Telegram 채팅에서 미디어 콘텐츠를 가져오고 다운로드하도록 합니다.
- 4포럼 토픽 관리AI를 사용하여 Telegram 포럼 내의 특정 토픽을 탐색하거나 상호작용합니다.
프로젝트의 README를 바탕으로 작성되었습니다. 모든 활용 사례는 해당 내용의 인용문과 대조하여 확인합니다.
자동 검사
2026년 11월 14일에 실행됨전체 보고서 →아직 인증되지 않았습니다. 서버는 80점 이상의 점수, 심각한 결함 없음, 그리고 검사에 충분한 데이터를 갖추어야 합니다. 검사 방식 · 점수를 높이기 위해 수정할 항목
- 소스 저장소 연결 및 접근 가능kfastov/tgcli is public and reachablegithub.com/kfastov/tgcli ↗통과
- 패키지가 이 저장소를 소스로 명시검사되지 않음
- 빌드 출처(Sigstore 증명)검사되지 않음
- 오픈 소스 라이선스 (OSI)MITspdx.org/licenses/MIT.html ↗통과
- 최근 1년 내 커밋 또는 릴리스Last commit or release 2026-11-12github.com/kfastov/tgcli ↗통과
- OpenSSF Scorecard검사되지 않음
- 패키지 이름이 인기 패키지와 유사하지 않음검사되지 않음
- 패키지 및 해당 종속성에 중요한 보안 권고 없음검사되지 않음
- 모델에 대한 숨겨진 지침 없음0 tool descriptions and the README read; no override phrases, credential paths or hidden characters통과
- 파괴적인 도구에 라벨 표시됨검사되지 않음
- 원격 엔드포인트가 MCP 핸드셰이크에 응답검사되지 않음
README
GitHub에서 보기tgcli
Telegram CLI with background sync and an optional MCP server for your personal account (MTProto, not bot API).
Installation
npm install -g @kfastov/tgcli
brew install kfastov/tap/tgcli
Authentication
Get Telegram API credentials:
- Go to https://my.telegram.org/apps
- Log in with your phone number
- Create a new application
- Copy
api_idandapi_hash
Then authenticate:
tgcli auth
Quick start
tgcli auth
tgcli sync --follow
tgcli messages list --chat @username --limit 20
tgcli messages search "course" --chat @channel --source archive
tgcli send text --to @username --message "hello"
tgcli server
Commands
tgcli auth Authentication and session setup
tgcli config View and edit config
tgcli sync Archive backfill and realtime sync
tgcli server Run background sync service (MCP optional); stop, restart, logs
tgcli service Install/start/stop/status/logs for background service
tgcli channels List/search channels
tgcli messages List/search messages
tgcli send Send text or files
tgcli media Download media
tgcli topics Forum topics
tgcli tags Channel tags
tgcli metadata Channel metadata cache
tgcli contacts Contacts and people
tgcli groups Group management
tgcli doctor Diagnostics and sanity checks
Commands run through tgcli server, which the CLI starts on demand. After an upgrade, the next command of any kind replaces a server the CLI started itself, as soon as its backfill queue is empty. A server you started yourself with tgcli server or tgcli service keeps running the old code until you restart it; the CLI warns about this on stderr. tgcli server restart restarts the server on the CLI's version, tgcli server stop stops it, and tgcli server logs --follow shows its log.
Use tgcli [command] --help for details. Add --json for machine-readable output.
Once a day tgcli checks npm for a newer release in the background and, at a terminal, prints one line on stderr with the upgrade command (brew update && brew upgrade tgcli or npm i -g @kfastov/tgcli). Set TGCLI_NO_UPDATE_CHECK=1 to turn it off; see docs/cli.md.
MCP (optional)
Enable it via config:
tgcli config set mcp.enabled true
By default the server binds to http://127.0.0.1:8080/mcp. To change it:
tgcli config set mcp.host 127.0.0.1
tgcli config set mcp.port 8080
Then run tgcli server and point your client at the configured address.
Configuration & Store
The tgcli store lives in the OS app-data directory and contains config.json, sessions, and messages.db.
Override the location with TGCLI_STORE.
Legacy version: see MIGRATION.md.
Development
Run it from a clone with Node 22: npm ci, then node cli.js. See docs/development.md for tests and for trying a change on your own account.
tgcli MCP 질문
tgcli에서 MCP server를 어떻게 활성화하나요?
config 명령어를 통해 mcp.enabled를 true로 설정한 다음, tgcli server를 실행하고 클라이언트가 설정된 주소를 가리키도록 합니다.
tgcli는 Telegram 인증에 무엇을 사용하나요?
my.telegram.org에서 발급받은 Telegram API 자격 증명(api_id 및 api_hash)과 세션 설정을 위한 tgcli auth 명령어를 사용합니다.
tgcli로 오프라인 상태에서 메시지 기록을 검색할 수 있나요?
네, 동기화를 통해 메시지를 아카이브하며 로컬 아카이브에서 검색할 수 있습니다.
tgcli는 bot API를 사용하나요?
아니요, bot API 대신 MTProto를 통해 개인 Telegram 계정으로 작동합니다.