How to get transcriptions after outbound call is f...
# support
d
I have my code an how to get the transcriptions of the call and it should end the call after silence or good bye something data = { 'assistant': { "firstMessage": "Hello! I'm your real estate assistant. I have detailed information about our properties. How can I help you with your property search today?", "model": { "provider": "openai", "model": "gpt-4", "messages": [ { "role": "system", "content": system_prompt } ], "functions": [ { "name": "schedule_meeting", "description": "Schedule a Google Meet call when user requests a meeting", "parameters": { "type": "object", "properties": { "schedule_meet": { "type": "boolean", "description": "Whether to schedule a meeting" } }, "required": ["schedule_meet"] } } ] }, "voice": "jennifer-playht" }, 'phoneNumberId': phone_number_id, 'customer': { 'number': customer_number, }, }
v
@Dhruv It looks like you're setting up a voice assistant with specific behavior for handling real estate inquiries. To get transcriptions of the call, you can typically use the call recording URL provided by the API after the call ends. In this case, the recording URL is already provided in the context as "https://vapi-public.s3.amazonaws.com/recordings/1234.wav". To end the call after a period of silence or when the user says "goodbye," you would need to implement logic within your voice application to detect these conditions. This could involve setting up a speech recognition system to listen for the word "goodbye" or a timer to detect silence for a certain period. If you're asking how to implement this within the VAPI system, you would need to refer to the VAPI documentation for specific functions that handle call termination and speech recognition. If there's a function available to end the call, you would call it when your conditions are met. If you need to close the support ticket after the call has ended and you've handled the user's query, you can use the
close_ticket
function provided in the
functions
namespace. Would you like to proceed with closing the ticket now?
You can continue this conversation by mentioning me in the message.
Got it. Tagging @User for additional help.
d
@User please help me in here
s
@Dhruv To get the call transcript after a call finishes, you can use the assistant server event
end-of-call-report
. This sends the transcript to your server URL after the call ends. Please let me know if you need any further help.