Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@tyler6204
Copy link
Member

@tyler6204 tyler6204 commented Jan 21, 2026

  • Add short ID mapping + full GUID retention for BlueBubbles message context so actions survive restarts without bloating prompts.
  • Improve BlueBubbles action handling (react/edit/unsend/reply) and reply-to resolution, including media send and thread context.
  • Expand BlueBubbles chat target resolution (chat_identifier/chatId/chatGuid) and strengthen reply-context caching tests.
  • Refine typing behavior during tool execution and adjust threading tool context fallback.

… reply context caching

- Added functionality to resolve short message IDs to full UUIDs and vice versa, optimizing token usage.
- Introduced a reply cache to store message context for replies when metadata is omitted in webhook payloads.
- Updated message handling to utilize short IDs for outbound messages and replies, improving efficiency.
- Enhanced error messages to clarify required parameters for actions like react, edit, and unsend.
- Added tests to ensure correct behavior of new features and maintain existing functionality.
…text improvements

- Implemented resolution of short message IDs to full UUIDs in both text and media sending functions.
- Updated reply context formatting to optimize token usage by including only necessary information.
- Introduced truncation for long reply bodies to further reduce token consumption.
- Adjusted tests to reflect changes in reply context handling and message ID resolution.
…ching

- Updated message processing to include full message IDs alongside short IDs for better context resolution.
- Improved reply handling by caching inbound messages, allowing for accurate sender and body resolution without exposing dropped content.
- Adjusted tests to validate the new full ID properties and their integration into the message handling workflow.
@tyler6204 tyler6204 changed the title BlueBubbles: short ID mapping with durable full GUIDs for replies and actions BlueBubbles: short ID mapping, action resolution, and threading/typing fixes Jan 21, 2026
@steipete
Copy link
Contributor

Findings / improvements

  • Medium extensions/bluebubbles/src/actions.ts:146 + extensions/ bluebubbles/src/monitor.ts:122 — short IDs resolve globally, no account/chat guard. If a short ID from another account is used, it still resolves and gets sent with the current account credentials. Safer: include account/chat in the short‑ID map or reject short IDs not tied to current account; or require MessageSidFull for action paths.
  • Medium extensions/bluebubbles/src/actions.ts:146 + extensions/ bluebubbles/src/monitor.ts:122 — expired/evicted short IDs fall through silently and get sent to BlueBubbles as numeric strings. That likely fails with unclear errors. Suggest explicit error: “short id expired; use MessageSidFull”.
  • Low (behavior change) extensions/bluebubbles/src/monitor.ts:1373 — inbound cache now only after allowlist/mention gating. A later allowed reply to a previously dropped message won’t get reply context anymore. If that’s intended (privacy), fine; if not, cache before gating but redact body/sender for dropped content.
  • Low (docs) src/auto-reply/templating.ts adds MessageSidFull/ ReplyToIdFull but docs table not updated (docs/gateway/ configuration.md). Worth documenting new fields + short‑ID behavior.

Testing

  • Good: new unit tests in extensions/bluebubbles/src/monitor.test.ts, extensions/bluebubbles/src/send.test.ts, src/auto-reply/reply/ typing-mode.test.ts.
  • Missing: extensions/bluebubbles/src/actions.test.ts coverage for short‑ID resolution + toolContext fallback + “short‑ID not found” error path. Add 2–3 tests.

Extra code read

  • Checked extensions/bluebubbles/src/actions.test.ts, src/auto-reply/ reply/inbound-dedupe.ts, src/channels/conversation-label.ts for side‑effects.

Google / external check

  • Searched BlueBubbles docs: no explicit mention of chat_identifier/ chat GUID parsing or short‑ID patterns; only general Private API feature list. So can’t confirm the chat_identifier mapping from docs. (docs.bluebubbles.app (https://docs.bluebubbles.app/private-api?utm_source=openai))

@steipete steipete merged commit c3adc50 into openclaw:main Jan 21, 2026
18 of 22 checks passed
@steipete
Copy link
Contributor

Landed via temp rebase onto main.

  • Gate: pnpm lint && pnpm build && pnpm test
  • Land commit: 9b9bbae
  • Merge commit: c3adc50

Follow-up fixes landed in #1387.

Thanks @tyler6204!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants