Assembly AI error..

willy Lafort

New Member
Mar 5, 2017
25
1
3
65
Can anybody tell me where I went wrong..?
Thank you;

ERROR...
Transcription... got stuck on "pending"
log shows..
[2026-06-16 09:16:03] production.DEBUG: Listener crashed: Error connecting to 127.0.0.1:8021 at /var/www/fspbx/app/Services/FreeswitchEslService.php:48
[2026-06-16 09:16:13] production.DEBUG: Listener crashed: Error connecting to 127.0.0.1:8021 at /var/www/fspbx/app/Services/FreeswitchEslService.php:48
[2026-06-16 09:21:05] production.DEBUG: Checking email challenge enabled status...
[2026-06-18 00:29:01] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 00:23:48] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 00:25:05] production.DEBUG: VoicemailTranscriptionService@transcribe: An unexpected error occurred during transcription with provider 'openai'. {"error":"OpenAI API key is not configured. Please set the API key in your environment file.","file":"/var/lib/freeswitch/storage/voicemail/default/coxx.sxxxxx.com/4001/msg_d3475569-xxxxxxxx.wav"}
[2026-06-19 11:06:56] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 12:30:57] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 19:03:28] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 19:04:10] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 22:06:01] production.DEBUG: Checking email challenge enabled status...
[2026-06-19 23:21:02] production.DEBUG: VoicemailTranscriptionService@transcribe: An unexpected error occurred during transcription with provider 'openai'. {"error":"OpenAI API key is not configured. Please set the API key in your environment file.","file":"/var/lib/freeswitch/storage/voicemail/default/coxx.sxxxxxx.com/4001/msg_20eefxxxxx.wav"}
[2026-06-20 00:51:27] production.DEBUG: AssemblyAI API key is not configured.
[2026-06-20 00:51:27] production.ERROR: AssemblyAI API key is not configured. {"exception":"[object] (Exception(code: 0): AssemblyAI API key is not configured. at /var/www/fspbx/app/Services/CallTranscription/CallTranscriptionService.php:55)
[stacktrace
---------------------------------------------------------------
in ".env".............

ASSEMBLYAI_API_KEY=65fxxxxxxxxxxxxxxxxxxxxxxxxxxxx
ASSEMBLYAI_REGION=US
ASSEMBLYAI_BASE_URL="https://api.us.assemblyai.com"
ASSEMBLYAI_WEBHOOK_HEADER=X-FSPBX-Webhook
ASSEMBLYAI_WEBHOOK_SECRET=ItgpEDNg9qxxxxxxxxxxxxxxxxxxxxxxxxxxx
-------------------------------------------------------------
OPENAI_API_KEY=sk-proj-_4XT-8Pl........................................................sA
OPENAI_SPEECH_TIMEOUT=60
OPENAI_SPEECH_MAX_ATTEMPTS=2
------------------------------------------------
 
@willy Lafort any time you make a change in the .env file you need to run this command. Saving the file is not enough as it keeps using the cached values until you run the command:

Code:
cd /var/www/fspbx
php artisan config:cache
 
Thank you for the respone, I did clear the cache.
maybe it's not even reaching assemblyai site
ASSEMBLYAI_BASE_URL=.... the video instruction didn't specify what the URL should be
I found that part in google search "https://api.us.assemblyai.com"
I just now relized its a dead link "404"
maybe that's the issue
 
I found the answer..
I corrected the value of ASSEMBLYAI_BASE_URL= "https://api.assemblyai.com" and voicemail transcription works
but the old recording still said "Pending" How can I change that.. I can create a new recording, but I want to know what to do if I get this error.
 

Attachments

  • Screenshot from 2026-06-20 09-06-23.png
    Screenshot from 2026-06-20 09-06-23.png
    24.7 KB · Views: 4
Last edited:
Hmmm, actually, there is no way to reset the pending transcription that is stuck at the moment. I should probably add a Retry button. I'll address this in future updates. Good news is you probably won't have this issue again now that it works.

The URL wasn't mentioned in the video because you can simply omit it for the US and Canada. It uses a default one if not specified. For other countries, you do need to specify it, and that's why the setting is there.

I hope you like the transcription module!