op7418

Claude To IM — Communication skill for Claude Code

Communication community

Host-agnostic bridge connecting Claude Code SDK to IM platforms (Telegram, Discord, Feishu).

How to install Claude To IM

This entry records only its repository, not the path inside it, so there is no exact command to give. Open op7418/Claude-to-IM and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What Claude To IM does

Host-agnostic bridge connecting Claude Code SDK to IM platforms (Telegram, Discord, Feishu).

Alternatives in Communication

  • Prompts.chat — f.k.a. Awesome ChatGPT Prompts 154.3k ★
  • Lark Coding Agent Bridge — Bot that bridges Feishu/Lark messenger with a local Claude Code or Codex CLI 2.4k ★
  • Nekro Agent — NekroAgent 是一个面向多人互动场景的跨平台 Agent 框架,集 Claude Code 沙盒执行、工作区编排、长期记忆、结构化 MCP 管理与可视化控制台于一体,兼具高扩展性、多模态交互、实时状态推送和自动化 800 ★

README

Claude-to-IM

English | [中文](README.zh-CN.md)

Claude-to-IM is a host-agnostic bridge library that connects [Claude Code SDK](https://docs.anthropic.com/en/docs/claude-code/sdk) to IM platforms, allowing users to interact with Claude through Telegram, Discord, and Feishu (Lark).

This library handles all IM-side complexity — message routing, streaming previews, permission approval flows, Markdown rendering, chunking, retry, rate limiting — while delegating persistence, LLM calls, and permission resolution to the host application through a set of dependency injection interfaces.

Out-of-the-Box Solution

If you want a ready-to-use desktop application without writing any integration code, check out [CodePilot](https://github.com/op7418/CodePilot) — a desktop GUI client for Claude Code with built-in IM bridge support. CodePilot implements all the host interfaces for you and provides a complete UI for managing sessions, settings, and bridge connections.

Claude-to-IM was extracted from CodePilot as a standalone library for developers who want to embed the IM bridge capability in their own applications.

Features

  • Multi-platform adapters: Telegram (long polling), Discord (Gateway WebSocket), Feishu/Lark (WSClient)
  • Streaming previews: Real-time response drafts via message editing, with per-platform throttling
  • Permission management: Interactive inline buttons for Claude Code tool approvals (allow / deny / allow for session)
  • Session binding: Each IM chat maps to a persistent conversation session with working directory and model settings
  • Markdown rendering: Platform-native formatting — HTML for Telegram, Discord-flavored Markdown, Feishu rich text cards
  • Reliable delivery: Auto-chunking at platform limits, retry with exponential backoff, HTML fallback on parse errors, message deduplication
  • Security: Input validation, token bucket rate limiting (20 msg/min per chat), user authorization whitelists, full audit logging
  • **Host-ag