Added support for managing multiple workspaces including:
- New workspace bind command to link existing directories
- Enhanced session management scoped to workspaces
- Improved error handling with localized messages
- Fixed interactive state lookup for multi-workspace contexts
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add opt-in `inject_sender` config option for projects. When enabled,
cc-connect prepends a metadata line to each message before forwarding
to the agent:
[cc-connect sender_id=ou_abc123 platform=feishu]
<original message>
This allows agents (Claude Code, Codex, etc.) to identify who sent the
message and adjust behavior accordingly — e.g. personal task views,
role-based access control, or per-user tone.
The feature is off by default and can be enabled per-project:
[[projects]]
inject_sender = true
Closes#91
* feat: add multi-workspace mode and base_dir config fields
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add WorkspaceBindingManager for channel-to-workspace persistence
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add workspacePool for managing per-workspace agent state
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add ChannelNameResolver interface and Slack implementation
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add multi-workspace fields, SetMultiWorkspace, and idle reaper to Engine
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add resolveWorkspace method for channel-to-directory mapping
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: wire multi-workspace mode setup in main.go
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add workspace init flow for cloning repos and binding channels
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: add /workspace commands (init, unbind, list, status)
Add handleWorkspaceCommand with subcommands:
- (no args): show current workspace binding for the channel
- init <git-url>: clone repo and bind workspace to channel
- unbind: remove workspace binding from channel
- list: show all workspace bindings for the project
Only available when multi-workspace mode is enabled.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* feat: wire multi-workspace routing into handleMessage with per-workspace agents
Add workspace resolution to handleMessage that resolves channels to workspace
directories, creates per-workspace agents with correct work_dir, and routes
messages through workspace-specific session managers. The normal (single-workspace)
code path is unchanged — all new logic is gated behind e.multiWorkspace.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test: add integration tests for multi-workspace resolution
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: resolve multi-workspace bugs found during live testing
Three bugs fixed:
1. App mention events not handled - Slack sends `app_mention` events
(not `message.channels`) when the bot is @mentioned. Added
AppMentionEvent handler in the Slack platform.
2. Bot mention prefix not stripped - app_mention text includes
`<@UBOTID> ` prefix, breaking command parsing and workspace
resolution. Now stripped before passing to engine.
3. Slash command syntax incompatible with Slack - `/workspace` commands
were being intercepted by Slack as slash commands. Changed all
user-facing references and prefix detection to use `workspace`
without the leading slash.
Also added debug logging to handleEvent for diagnosing event delivery.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix: instruct agent to use Slack mrkdwn formatting
Add Slack formatting guidelines to the agent system prompt so responses
use Slack's mrkdwn syntax instead of standard Markdown (e.g. *bold*
instead of **bold**, no ## headings).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Add support for rich permission prompts using interactive cards when platforms support them. CardButtons now support Extra field for callback data. Implement fallback chain: inline buttons → cards → plain text. Includes i18n support and tests for all platforms.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add nil checks for card operations in core engine.
Improve token redaction utility and error handling.
Initialize delete mode state properly.
Fix error message in cc-connect update.
Add missing platform allowFrom checks.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
1. Unix socket permissions: 0o660 → 0o600 (owner-only access), preventing
other processes in the same group from injecting messages via the API.
2. Telegram bot token redaction: when file downloads fail, the bot token
embedded in the Telegram API URL is now replaced with [REDACTED] in
error messages to prevent token leakage in logs.
3. Startup warning for open allow_from: all platforms now log a WARN-level
message when allow_from is not configured, making it obvious that the
deployment permits all users. This surfaces the fail-open default so
operators can make an informed decision.
Ref #60
* feat(cards): interactive card UI for slash commands on Feishu
- Add platform-agnostic Card model (core/card.go) with builder API
- Add CardSender/CardNavigable interfaces (core/interfaces.go)
- Implement Feishu card renderer using column_set for mobile layout
- Redesign all slash command responses to use interactive cards
- Add handleCardNav router and executeCardAction for in-place updates
- Convert /new /quiet /switch /stop to act: and nav: actions
- /help card uses tab buttons grouped by Session/Agent/Tools/System
- renderUpgradeCard: sync update check with 8s timeout
- Fix: return error card instead of nil in handleCardNav /list /switch
Made-with: Cursor
* fix(cards): address PR #52 review feedback
- Add enable_feishu_card config option (default true) so operators can
fall back to plain-text replies when card permissions are unavailable;
wraps Platform in interactivePlatform only when cards are enabled
- Fix goroutine leak in renderUpgradeCard: use buffered channel (cap 1)
so the background goroutine can always complete even after a timeout
- Fix /stop concurrent logic in executeCardAction: consolidate state
mutation under a single interactiveMu critical section
- Fix code indentation in platform/feishu/card.go (action map and
CardSelect/CardNote case blocks)
- Add unit tests for Card.RenderText and Card.HasButtons (core/card_test.go)
- Add Feishu platform tests for ReplyCard/SendCard and card renderer
(platform/feishu/platform_test.go)
- Update docs/feishu.md and README with enable_feishu_card option
Made-with: Cursor
Add `/bind setup` command to write relay instructions to memory file.
Implement SystemPromptSupporter interface to detect native prompt support.
Add related i18n messages for setup flow and hint messages.
Update bind command to show setup hint when needed.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add drainEvents utility to clear buffered events between turns and apply it in processInteractiveMessage and cmdCompress to avoid processing stale events from previous agent interactions.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Refactor TTS configuration to use pointer type and add validation for TTS mode. Update help messages to include TTS command documentation. Fix ffmpeg command construction for audio conversion.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
When the cron jobs file is corrupted, json.Unmarshal fails silently
and all scheduled tasks are lost without any log output. Add error
logging so the issue is visible in logs.
The idle timer in processInteractiveEvents kept running while
the event loop was blocked waiting for a user permission response.
If the user took longer than eventIdleTimeout to respond, the timer
would fire and kill the session on the next loop iteration.
Stop the idle timer before waiting on pending.Resolved and restart
it after the permission is resolved.
Add data persistence to RelayManager with JSON storage.
Remove unused MsgRelayBindOK message.
Improve relay binding success messages.
Update RelayManager constructor to accept data directory path.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Move compression logic to async goroutine with proper state handling.
Add event processing with timeout and cleanup.
Add i18n support for compression done message.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add new i18n message keys for various command responses (switch, timeout, relay bindings).
Improve formatting of command list output with better descriptions and shell command display.
Adjust Feishu platform message type detection threshold for posts.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Updated iFlow CLI integration flags from `-p` to `-i` for interactive mode.
Modified quiet mode handling to preserve state across session stops.
Added shell command support in i18n messages.
Fixed empty tool ID handling in iFlow session.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add new `/shell` command (with aliases `/sh`, `/exec`, `/run`) to execute shell commands and return output. Includes timeout handling, working directory detection, output trimming, and error handling. Also adds command documentation in all supported languages.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
- add BotCommandInfo and CommandRegistrar interface for platform abstraction
- implement GetAllCommands to collect builtin/custom commands and skills
- add i18n descriptions for all 30 builtin commands (en/zh/zh-TW/ja/es)
- implement RegisterCommands for Telegram setMyCommands API integration
- Add AddToBind() method to incrementally add projects to binding
- Add RemoveFromBind() method to remove specific project from binding
- Update /bind command to support multiple projects:
- /bind <project> - add project to binding
- /bind -<project> - remove specific project
- /bind remove - clear all bindings
- Add debug logging for telegram group message filtering
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add logic to delete stale preview messages when stream preview is degraded.
Implement PreviewCleaner interface for Telegram platform and add test coverage.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add ability to define custom slash commands that execute shell commands directly:
- Extend CommandConfig with Exec and WorkDir fields
- Add cmdCommandsAddExec handler for exec commands
- Implement executeShellCommand with timeout and output handling
- Add work_dir support for exec commands
- Update documentation and i18n messages
- Add tests and error handling
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Add support for configuring agent idle timeout duration via config file
(idle_timeout_mins). Defaults to 2 hours (changed from previous fixed 30 mins).
Timeout can be disabled by setting to 0.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
Adjust eventIdleTimeout constant from 5 to 30 minutes to better handle agent response scenarios. Also includes minor code formatting cleanup in Engine struct.
generated by llmgit
Co-Authored-By: Claude <noreply@anthropic.com>
- Add quiet mode status to /status command with i18n support
- Fix Feishu help command line breaks (use buildPostJSON instead of md tag)
- Improve tool message formatting (code block for long content)
- Strip XML tags from session summary display
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add disabled_platforms config option to disable streaming preview
for specific platforms (e.g. feishu) where it causes formatting issues.
- Add DisabledPlatforms field to StreamPreviewConfig and StreamPreviewCfg
- Check platform name against disabled list in canPreview()
- Allows pure text messages to use correct message type instead of cards
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>