Skip to content

Add voice message support for Telegram/WhatsApp #6

Description

@osisdie

Overview

Both Telegram and WhatsApp support voice messages, but the current brokers only handle text and image messages. Adding voice support would significantly improve the mobile experience.

What to do

  • Download voice message audio file from platform API
  • Convert OGG/OPUS to a format suitable for transcription
  • Transcribe audio to text (options: Whisper API, Claude vision, or platform-native STT)
  • Pass transcribed text to Claude Code as the user message
  • Reply with the transcription + Claude's response

Relevant files

  • external_plugins/whatsapp-channel/broker-relay.ts — WhatsApp broker
  • external_plugins/line-channel/broker-relay.ts — LINE broker (similar pattern for reference)

Notes

  • WhatsApp sends voice as audio/ogg with codec opus
  • Telegram sends voice as .oga files
  • Consider adding a VOICE_TRANSCRIPTION_PROVIDER env var for flexibility

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions