Enable Voice Agent API (BYO LLM) for PWA #1354
Replies: 3 comments
-
Thanks for asking your question. Please be sure to reply with as much detail as possible so the community can assist you efficiently. |
Beta Was this translation helpful? Give feedback.
-
The Voice Agent API isn't restricted in anyway. Your account has credit. You mentioned you are passing scopes to the Grant token endpoint, but it doesn't accept scopes. You can just pass it to set the time to live. https://developers.deepgram.com/reference/token-based-auth-api/grant-token This endpoint Generates a temporary JSON Web Token (JWT) with a 30-second (by default) TTL and That's why you keep getting the scope of Check out our guide on this endpoint as it may help: https://developers.deepgram.com/guides/fundamentals/token-based-authentication
|
Beta Was this translation helpful? Give feedback.
-
Hi John, Thank you very much for your help and clarification. I also realized that, for now, it only works in English, so I’ll proceed with ttl_seconds and handle STT and TTS separately. Really appreciate your quick support! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi team,
I need help enabling the Voice Agent API (BYO LLM) for my project.
Problem:
When I request a token with /v1/auth/grant using these scopes:
["listen:stream", "speak:playback", "agent:converse"]
The response always returns only ["asr:write"], even when using an Owner API Key.
When I test with curl, I also get a 400 error: {"err_code":"BAD_REQUEST","err_msg":"Invalid credentials"}.
As a result, the WebSocket connection to:
wss://agent.deepgram.com/v1/agent/converse
fails with code 1006.
Reproducible test:
curl -i -X POST "https://api.deepgram.com/v1/auth/grant"
-H "Authorization: Token <API_KEY>"
-H "Content-Type: application/json"
-d '{"ttl":60,"scopes":["listen:stream","speak:playback","agent:converse"]}'
The returned JWT always has only ["asr:write"].
Details:
Language/stack: JavaScript (Node.js) on Firebase Functions and a web app on Firebase Hosting.,
Request ID from the last failed attempt: 95e5c6b6-59eb-4890-9a69-a06510b764f5,
Does anyone know if the Voice Agent API in Deepgram gets enabled automatically for new projects, or if I need to activate it manually? If it’s manual, what’s the process to enable it?
Thank you for your help, as I’ve been struggling with this for a few days now.
Beta Was this translation helpful? Give feedback.
All reactions