feat: image message TTL and inline display#944
Open
chaehyun2 wants to merge 4 commits intoslopus:mainfrom
Open
feat: image message TTL and inline display#944chaehyun2 wants to merge 4 commits intoslopus:mainfrom
chaehyun2 wants to merge 4 commits intoslopus:mainfrom
Conversation
Images are now sent as separate encrypted messages with a TTL marker (expiresIn) outside the encryption layer. Server stores expiresAt and a cleanup job deletes expired messages every 5 minutes. Server: expiresAt field on SessionMessage, TTL cleanup in main.ts, v3 POST accepts expiresIn per message Web: sendMessage splits images into separate ephemeral message with groupId (inside encryption) and expiresIn: 300 (outside encryption) CLI: routeIncomingMessage buffers image messages by groupId, attaches to matching text message before passing to UserMessageSchema Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Show image thumbnails (120x120) in user message bubbles. Click thumbnail to expand full-size with dark overlay. Images stored in ephemeral messageImageStore keyed by localId. Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
Reducer assigns new internal IDs, losing the original localId needed to look up images in messageImageStore. Pass realID as localId in user messages, and add id-based fallback lookup in MessageView. Generated with [Claude Code](https://claude.ai/code) via [Happy](https://happy.engineering) Co-Authored-By: Claude <noreply@anthropic.com> Co-Authored-By: Happy <yesreply@happy.engineering>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
expiresIn(outside encryption). Server storesexpiresAtand auto-deletes expired messages every 5 minutes. Default TTL is 3 days.expiresAtnullable field onSessionMessage, index for efficient cleanup, v3 POST acceptsexpiresInper messagesendMessage()splits images into separate ephemeral messages withgroupId(inside encryption) linking to text messagerouteIncomingMessage()buffers image messages bygroupId, attaches to matching text messageHow it works
{role: 'user', content: {type: 'images', groupId, images}}withexpiresIn: 259200(3 days)imageGroupIdinside encrypted payloadexpiresIn→ setsexpiresAt→ cleanup job deletes after TTLgroupId→ when text arrives, merges images → sends to ClaudeTest plan
🤖 Generated with Claude Code