Conditional Call Transfer and Handling Unsuccessfu...
# support
c
Hi, I would like to implement conditional call transfer (conditional call forwarding) functionality for our AI assistant. Specifically, I want the assistant to transfer calls only during certain hours. Could you guide me on how to configure this feature and any best practices to consider? Additionally, I would like to know how the system handles unsuccessful transfers. For instance, what happens if the endpoint number is busy or doesn’t answer the call? Is there a way to define fallback actions or notifications in such cases?
v
@Cleverize Hello! To implement conditional call transfer based on certain hours, you'll need to set up a schedule within your system that checks the current time against your defined hours of operation. If the current time falls within those hours, you can use the
transferCall
function to forward the call to the appropriate number. Here are some steps and best practices to consider: 1. **Define Business Hours**: Clearly define the hours during which you want calls to be transferred. 2. **Time-Checking Logic**: Implement logic in your AI assistant's code to check the current time against your business hours. 3. **Use
transferCall
Wisely**: Only invoke
transferCall
when the current time meets your defined conditions. 4. **Test Thoroughly**: Ensure your time-based conditions are correctly triggering the call transfer. Regarding unsuccessful transfers, handling scenarios where the endpoint number is busy or doesn't answer is crucial. You can configure fallback actions such as: - **Retry Logic**: Attempt to transfer the call again after a certain time interval. - **Alternative Number**: Transfer the call to a second number if the first is unavailable. - **Voicemail**: If all else fails, direct the call to a voicemail system. - **Notifications**: Set up notifications to inform relevant personnel that a transfer attempt failed. To define fallback actions, you would typically set up additional logic in your system to handle these cases. This could involve using conditional statements to check the result of the
transferCall
attempt and then executing the appropriate fallback action. If you need more specific guidance on setting up these features or if you encounter any issues, please don't hesitate to ask for support.
You can continue this conversation by mentioning me in the message.
s
@Cleverize 1. For using Assistant conditionally based on working and non-working hours you have to check with your telephony provider. 2. As of now we don't have fallback plan for failed transfers or unattended trasnfers but it's in our list. What if transfer is unattended then the call gets dropped.
Do let me know if you require further help!!
c
Hey @Shubham Bajaj Thank you very much for your response. I actually found out Vapi supports dynamic call transfers through server requests, and I want to add the conditional call transfer (define the transfer logic on my server), but it is not currently working. Here are the steps that I have tried 1. Created a tool using api to transfer the call
Copy code
json
{
  "type": "transferCall",
  "function": {
    "name": "transferAccountManager",
    "description": "Use this function to transfer the call if the user wants to talk to their account manager. DO NOT call this function unless you are instructed to do so.",
    "parameters": 
      {
        "type": "object",
        "properties": {
          "destination": {
            "type": "string",
            "description": "The destination to transfer the call to."
          }
        },
        "required": [
          "destination"
        ]
      }
  }
}
2. Attached the tool to the AI Assistant 3. Edit the prompt to let it know about the functionality
Copy code
You are an AI customer phone support agent acting on behalf of a business.
If the customer specifically asked you to transfer the call to its account manager, call transferAccountManager function.
4. Add my server url to the assistant 5. Enable transfer-destination-request in the server messages During the call, when I ask the assistant to transfer the call, it tells me "transferirng the call now" but, it is not calling my server webhook function. Call Id: "97541019-495a-4374-92f8-261aae099944"
s
@Cleverize create a new #1211483291191083018 ticket for it.
c
@Shubham Bajaj Thanks, will create a ticket.
@Shubham Bajaj I have created a support ticket for this, but haven't gotten a response back yet. Can you please help me with this matter?
s
@Cleverize sorry for the late response, can you please tag me to your #1211483291191083018 ticket.
7 Views