open-agents-ai 0.187.581 → 0.187.583
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +36 -0
- package/dist/index.js +1110 -181
- package/npm-shrinkwrap.json +2 -2
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3424,10 +3424,46 @@ Connect the agent to a Telegram bot. Each incoming message spawns a dedicated su
|
|
|
3424
3424
|
/telegram # Toggle bridge on/off (uses saved key)
|
|
3425
3425
|
/telegram status # Show connection status + active sub-agents
|
|
3426
3426
|
/telegram stop # Disconnect and kill all sub-agents
|
|
3427
|
+
/telegram auth # Show a one-time TUI-only admin auth code
|
|
3428
|
+
/telegram auth cancel # Cancel the pending admin auth code
|
|
3429
|
+
/telegram bot <username> <text> # Send bot-to-bot message by @username
|
|
3430
|
+
/telegram poll <chat> <question> | <a> [| <b>] # Send a poll
|
|
3431
|
+
/telegram live-photo <chat> <live> <photo> [caption] # Send a live photo
|
|
3432
|
+
/telegram draft <chat_id> <draft_id> [text] # Set or clear a message draft
|
|
3433
|
+
/telegram admins <chat> [--bots] # List chat administrators
|
|
3434
|
+
/telegram personal <user_id> <limit> # Fetch profile personal chat messages
|
|
3435
|
+
/telegram access get <managed_bot_user_id> # Show managed-bot access restrictions
|
|
3436
|
+
/telegram access set <managed_bot_user_id> <restricted|open> [user_ids] # Configure access
|
|
3437
|
+
/telegram delete-reaction <chat> <msg> --user <id> # Delete a message reaction
|
|
3438
|
+
/telegram delete-reactions <chat> --user <id> # Delete recent reactions
|
|
3427
3439
|
```
|
|
3428
3440
|
|
|
3429
3441
|
The bot token and admin ID are persisted to project settings, so you only need to set them once. After that, bare `/telegram` toggles the bridge on and off like a service watchdog.
|
|
3430
3442
|
|
|
3443
|
+
### Telegram Admin Authentication
|
|
3444
|
+
|
|
3445
|
+
Run `/telegram auth` in the TUI to generate a one-time six-digit code. The code is rendered only in the terminal and is not inserted into agent prompts or Telegram sub-agent context. From the Telegram account that should become admin, send:
|
|
3446
|
+
|
|
3447
|
+
```text
|
|
3448
|
+
/auth <code>
|
|
3449
|
+
```
|
|
3450
|
+
|
|
3451
|
+
On success, that Telegram user ID is saved as the admin user and future private-DM slash commands are passed through the same command handler as the local TUI. `/telegram auth cancel` invalidates a pending code.
|
|
3452
|
+
|
|
3453
|
+
### Bot API 10.0 Features
|
|
3454
|
+
|
|
3455
|
+
The Telegram bridge handles modern Bot API traffic directly:
|
|
3456
|
+
|
|
3457
|
+
- **Guest Mode** — inbound `guest_message` updates are normalized into regular agent work and answered through `answerGuestQuery`, so users can interact from profile-surface guest chats before a normal bot DM exists.
|
|
3458
|
+
- **Command menu registration** — when the bridge starts, OA registers the local slash-command surface with Telegram via `setMyCommands`; Telegram-safe names such as `/full_send_bless` are mapped back to canonical TUI commands like `/full-send-bless` before execution.
|
|
3459
|
+
- **Bot-to-bot sends** — `/telegram bot <username> <text>` targets another bot by username using Telegram's supported bot-to-bot message subset.
|
|
3460
|
+
- **Managed bot access** — `/telegram access get|set` reads and configures managed-bot access restrictions by managed bot user ID.
|
|
3461
|
+
- **Polls and live photos** — incoming polls, poll media summaries, option media, country/member limits, and live photos are captured as first-class Telegram message context; `/telegram poll` and `/telegram live-photo` send the matching Bot API payloads.
|
|
3462
|
+
- **Direct-message channels** — direct-message channel/topic metadata is preserved on normalized Telegram messages for routing and future adapter logic.
|
|
3463
|
+
- **Drafts and profile chat reads** — `/telegram draft` can set or clear message drafts, and `/telegram personal <user_id> <limit>` fetches recent messages from a user's profile personal chat.
|
|
3464
|
+
- **Reactions/admin helpers** — `/telegram delete-reaction` removes a message reaction, `/telegram delete-reactions` removes recent reactions by a user/chat, and `/telegram admins <chat> [--bots]` can include bot administrators.
|
|
3465
|
+
- **TUI sub-agent visibility** — Telegram conversations register as blue plane-labeled sub-agent views in the systems panel and show an active plane indicator in the footer while the bridge or Telegram sub-agents are active.
|
|
3466
|
+
|
|
3431
3467
|
### Admin Slash Command Passthrough
|
|
3432
3468
|
|
|
3433
3469
|
When the admin sends a `/command` in a private DM, it's routed directly through the terminal's command handler — the same code path as typing the command in the TUI. This means you can control the agent from your phone:
|