Transcribing WhatsApp Audio

I have a workflow starting from a Whatsapp message trigger. I would like to allow for voice messages and transcribe them to work the same way as messages.

The flow:

1. WhatsApp Trigger: Receive Whatsapp audio message
2. WhatsApp Business Console: Resource = Media; Operation = Download; Media ID = {{ $json.messages[0].audio.id }}
3. Output URL: https://lookaside.fbsbx.com/whatsapp_business/attachments/?mid=1037297827866118&ext=1725962641&hash=ATsrYE0Bm6tqwdrMSNlvHrmz8nZ2r4e4t3uBOP_hl03Ejw

I cannot seem to be able to download this file, or transcribe it via OpenAI or AWS Transcribe.

Running n8n via n8n cloud (still on trial on the website)

Any suggestions?

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hi!
After your WhatsApp node put an HTTP Request with the followings instructions:

Method : GET
URL: Get url from node WhatsApp Output URL
Authentication: Predefined Credential Type
Credential Type: WhatsApp API
WhatsApp API: Your credential
Send Headers: Turn ON
Specify Headers: Using Fields Below, etc.

Thanks a lot @tetraetila - managed to get this working :slight_smile:

A bit of an HTTP request noob here - If you don’t mind a few follow-ups.

The output here is a file to download, while AWS Transcribe node requires a URI. How do I get it to a point where I can transcribe the audio?

Also (side-note) - what’s the value you are hiding in your screenshot?

Thanks!

still not fully resolved. Downloading was possible but not the transcribing.

To transcribe your audio, after your HTTP Request put a OpenAI (Audio Actions > Transcribe a Recording. The Output is your audio transcribed.

HTTP Request get the file and sent to OpenAI who do the job.

The value are sensitive data, API key. Don’t worry about!