Commit Graph

69 Commits

Author SHA1 Message Date
Hyudryu
72db01db63 slack: Added replyInThread logic and custom react emoji in config 2026-02-17 13:42:57 -08:00
Re-bin
5ad9c837df refactor: clean up telegram media sending logic 2026-02-17 10:37:55 +00:00
Darye
23b7e1ef5e Handle media files (voice messages, audio, images, documents) on Telegram Channel 2026-02-16 16:29:03 +01:00
Grzegorz Grasza
c9926153b2 Add table-to-text conversion for Slack messages
Slack has no native table support, so Markdown tables are passed
through verbatim by slackify-markdown.  Pre-process tables into
readable key-value rows before converting to mrkdwn.

Assisted-by: Claude 4.6 Opus (Anthropic)
2026-02-16 14:03:33 +01:00
Grzegorz Grasza
ed5593bbe0 slack: use slackify-markdown for proper mrkdwn formatting
Replace the regex-based Markdown-to-Slack converter with the
slackify-markdown library, which uses a proper Markdown parser
(markdown-it-py, already a dependency) to correctly handle headings,
bold/italic, code blocks, links, bullet lists, and strikethrough.

The regex approach didn't handle headings (###), bullet lists (* ),
or code block protection, causing raw Markdown to leak into Slack
messages.

Net -40 lines.

Assisted-by: Claude 4.6 Opus (Anthropic)
2026-02-16 13:56:30 +01:00
Re-bin
db0e8aa61b fix: handle Telegram message length limit with smart splitting 2026-02-16 12:39:39 +00:00
Re-bin
48a14edbda Merge branch 'main' into pr-694 2026-02-16 12:16:05 +00:00
Re-bin
ffbb264a5d fix: consistent sender_id for Telegram command allowlist matching 2026-02-16 12:11:03 +00:00
Re-bin
ba923c0205 Merge branch 'main' into pr-701 2026-02-16 12:07:58 +00:00
Re-bin
e8e7215d3e refactor: simplify Slack markdown-to-mrkdwn conversion 2026-02-16 11:57:55 +00:00
Aleksander W. Oleszkiewicz (Alek)
fe0341da5b Fix regex for URL formatting in Slack channel 2026-02-16 09:58:38 +01:00
Aleksander W. Oleszkiewicz (Alek)
5d683da38f Fix regex for URL and image URL formatting 2026-02-16 09:53:20 +01:00
Aleksander W. Oleszkiewicz (Alek)
90be900448 Enhance Slack message formatting with new regex rules
Added regex substitutions for strikethrough, URL formatting, and image URLs in Slack message conversion.
2026-02-16 09:49:44 +01:00
Thomas Lisankie
51d22b7ef4 Fix: _forward_command now builds sender_id with username for allowlist matching 2026-02-16 00:14:34 -05:00
zhouzhuojie
9bfc86af41 refactor(telegram): extract message splitting into helper function
- Added _split_message() helper for cleaner separation of concerns
- Simplified send() method by using the helper
- Net -18 lines for the message splitting feature
2026-02-15 22:49:01 +00:00
zhouzhuojie
203aa154d4 fix(telegram): split long messages to avoid Message is too long error
Telegram has a 4096 character limit per message. This fix:
- Splits messages longer than 4000 chars into multiple chunks
- Prefers breaking at newline boundaries to preserve formatting
- Falls back to space boundaries if no newlines available
- Forces split at max length if no good boundaries exist
- Adds comprehensive tests for message splitting logic
2026-02-15 22:39:31 +00:00
Aleksander W. Oleszkiewicz (Alek)
7e2d801ffc Implement markdown conversion for Slack messages
Add markdown conversion for Slack messages including italics, bold, and table formatting.
2026-02-15 15:51:19 +01:00
Ahwei
5e082690d8 refactor(feishu): support both direct and localized post content formats 2026-02-14 14:37:23 +08:00
Ahwei
4e4eb21d23 feat(feishu): Add rich text message content extraction feature
Newly added the _extract_post_text function to extract plain text content from Feishu rich text messages, supporting the parsing of titles, text, links, and @mentions.
2026-02-14 12:14:31 +08:00
Xubin Ren
3f59a8e234 Merge pull request #593 from C-Li/feishu_fix
Optimize the display of Markdown titles in Lark card information.
2026-02-13 17:02:27 +08:00
Ahwei
ccf9a6c146 fix(feishu): convert markdown headings to div elements in card messages
Markdown heading syntax (#) is not properly rendered in Feishu interactive
cards. Convert headings to div elements with lark_md format (bold text) for
proper display.

- Add _HEADING_RE regex to match markdown headings (h1-h6)
- Add _split_headings() method to parse and convert headings to div elements
- Update _build_card_elements() to process headings before markdown content
2026-02-13 15:31:30 +08:00
Re-bin
fd7e477b18 fix(security): bind WhatsApp bridge to localhost + optional token auth 2026-02-13 05:37:56 +00:00
Re-bin
903caaa642 feat: unified slash commands (/new, /help) across all channels 2026-02-13 03:30:21 +00:00
Re-bin
b429bf9381 fix: improve long-running stability for various channels 2026-02-12 01:20:57 +00:00
Re-bin
ba2bdb080d refactor: streamline mochat channel 2026-02-10 07:06:04 +00:00
Re-bin
d1f0615282 resolve conflicts with main; remove test_mochat_channel.py 2026-02-10 06:52:52 +00:00
Re-bin
4f928e9d2a feat: improve QQ channel setup guide and fix botpy intent flags 2026-02-09 16:17:35 +00:00
Re-bin
a63a44fa79 fix: align QQ channel with BaseChannel conventions, simplify implementation 2026-02-09 12:04:34 +00:00
Re-bin
2c45657b14 resolve merge conflicts: keep all channels and add QQ 2026-02-09 11:58:38 +00:00
Re-bin
f3ab8066a7 fix: use websockets backend, simplify subtype check, add Slack docs 2026-02-09 11:39:13 +00:00
Re-bin
74e3c411a1 resolve merge conflicts: keep all channels and add slack 2026-02-09 11:17:07 +00:00
tjb-tech
ef7972b6d3 Merge origin/main into feat/mochat-channel 2026-02-09 09:01:25 +00:00
tjb-tech
3779225917 refactor(channels): rename moltchat integration to mochat 2026-02-09 08:50:17 +00:00
tjb-tech
20b8a2fc58 feat(channels): add Moltchat websocket channel with polling fallback 2026-02-09 08:46:47 +00:00
yinwm
34dc933fce feat: add QQ channel integration with botpy SDK
Add official QQ platform support using botpy SDK with WebSocket connection.

Features:
- C2C (private message) support via QQ Open Platform
- WebSocket-based bot connection (no public IP required)
- Message deduplication with efficient deque-based LRU cache
- User whitelist support via allow_from configuration
- Clean async architecture using single event loop

Changes:
- Add QQChannel implementation in nanobot/channels/qq.py
- Add QQConfig schema with appId and secret fields
- Register QQ channel in ChannelManager
- Update README with QQ setup instructions
- Add qq-botpy dependency to pyproject.toml
- Add botpy.log to .gitignore

Setup:
1. Get AppID and Secret from q.qq.com
2. Configure in ~/.nanobot/config.json:
   {
     "channels": {
       "qq": {
         "enabled": true,
         "appId": "YOUR_APP_ID",
         "secret": "YOUR_APP_SECRET",
         "allowFrom": []
       }
     }
   }
3. Run: nanobot gateway

Note: Group chat support will be added in future updates.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-09 15:54:14 +08:00
Re-bin
d223454a98 fix: cap processed UIDs, move email docs into README, remove standalone guide 2026-02-09 06:19:35 +00:00
Re-bin
994f5601e9 resolve merge conflicts: keep both dingtalk and email channels 2026-02-09 06:02:36 +00:00
Re-bin
b6ec6a8a76 fix(dingtalk): security and resource fixes for DingTalk channel 2026-02-08 18:06:07 +00:00
Re-bin
499f602223 Merge branch 'main' into pr-219 2026-02-08 17:34:06 +00:00
Re-bin
00185f2bee feat: add Telegram typing indicator 2026-02-08 05:44:06 +00:00
Re-bin
f7f812a177 feat: add /reset and /help commands for Telegram bot 2026-02-08 05:06:41 +00:00
w0x7ce
240db894b4 feat(channels): add DingTalk channel support and documentation 2026-02-08 11:58:49 +08:00
Re-bin
d258f5beba Merge branch 'main' into pr-289 2026-02-07 17:54:33 +00:00
Re-bin
544eefbc8a fix: correct variable references in WhatsApp LID handling 2026-02-07 17:40:46 +00:00
alan
cf1663af13 feat: conditionally set telegram proxy 2026-02-07 22:18:43 +08:00
alan
3166c15cff feat: add telegram proxy support and add error handling for channel startup 2026-02-07 20:37:41 +08:00
Adrian Höhne
b179a028c3 Fixes Access Denied because only the LID was used. 2026-02-07 12:13:13 +00:00
Re-bin
2ca15f2a9d feat: enhance Feishu markdown rendering 2026-02-07 09:46:53 +00:00
张涔熙
cfe43e4920 feat(email): add consent-gated IMAP/SMTP email channel 2026-02-07 11:08:30 +08:00
Re-bin
c5191eed1a refactor: unify workspace restriction for file tools, remove redundant checks, fix SECURITY.md 2026-02-06 09:16:20 +00:00