Skip to content

feat(middleware): add multimodal media attachments to AgentRuntime contract#411

Merged
alexey-pelykh merged 1 commit intomainfrom
feat/385-media-attachments-contract
Mar 8, 2026
Merged

feat(middleware): add multimodal media attachments to AgentRuntime contract#411
alexey-pelykh merged 1 commit intomainfrom
feat/385-media-attachments-contract

Conversation

@alexey-pelykh
Copy link
Copy Markdown

Summary

  • Add MediaAttachment type with mimeType, filePath, base64, sourceUrl, and fileName fields
  • Add optional media field to AgentExecuteParams (inbound attachments)
  • Add AgentMediaEvent to the AgentEvent discriminated union (outbound streaming)
  • Add optional media field to AgentRunResult (outbound final result)
  • Add optional mediaCapabilities to AgentRuntime interface (runtime capability declaration)

All additions are optional — existing runtimes and consumers continue to work unchanged.

Closes #385

Test plan

  • Type-check passes (tsc --noEmit — no new errors)
  • Full test suite passes (863 tests, 93 files)
  • Lint clean (oxlint — 0 warnings, 0 errors)
  • Format clean (oxfmt)
  • No exhaustive switches on AgentEvent.type that would break

🤖 Generated with Claude Code

…ntract (#385)

Add MediaAttachment type and extend the runtime contract to support
media in both directions:
- Inbound: media field on AgentExecuteParams
- Outbound: AgentMediaEvent in the event stream, media field on AgentRunResult
- Capability declaration: mediaCapabilities on AgentRuntime interface

All additions are optional — existing runtimes continue to work unchanged.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@alexey-pelykh alexey-pelykh enabled auto-merge (squash) March 8, 2026 06:55
@alexey-pelykh alexey-pelykh merged commit 1e5a8c8 into main Mar 8, 2026
5 checks passed
@alexey-pelykh alexey-pelykh deleted the feat/385-media-attachments-contract branch March 8, 2026 07:03
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.

feat(middleware): add multimodal media attachments to AgentRuntime contract

1 participant