Transfer customer number
# support
p
I created a blueprint like this on Make.com My tool is as attached I defined my tools from functions. What I want to do is this. When a call transfer is to be made while talking to a customer, I want to make the call transfer with the customer number. Where am I wrong? @Shubham Bajaj https://cdn.discordapp.com/attachments/1326935139518775366/1326935139808313459/blueprint_3.json?ex=67813c26&is=677feaa6&hm=4831ea68384cc18cce89953b5620eea4f5b11c9d8d9b9ff50c45cf2d6bf32726& https://cdn.discordapp.com/attachments/1326935139518775366/1326935140227616768/Ekran_Resmi_2025-01-09_18.24.56.png?ex=67813c26&is=677feaa6&hm=052e39cee5906f40b52d87a0e8067f1ce9acd5792c2f8dfc4a22afebc92b2bf9&
v
@phlanexes It sounds like you're trying to set up a call transfer system using Make.com (formerly Integromat) that integrates with a Voice API. To assist you better, I would need to know more details about the specific issue you're facing. However, based on the context you've provided, here are some general steps you should ensure are correctly set up in your blueprint: 1. **Trigger**: Your blueprint should start with a trigger that initiates the call transfer process. This could be a specific phrase the customer says or an option they select. 2. **Get Customer Number**: Ensure that your system captures the customer's phone number correctly. This might be done automatically if the number is part of the incoming call data. 3. **Transfer Function**: Use the
transferCall
function, which should be defined in your Voice API, to transfer the call to the desired number. Make sure you pass the customer's phone number as a parameter to this function. 4. **Error Handling**: Implement error handling to manage any issues that might occur during the transfer process, such as the transfer function failing or the destination number being unavailable. If you have a specific error message or behavior that's not working as expected, please provide more details so I can offer a more precise solution. If you need to transfer a call now and have the customer's number, please provide the destination number so I can initiate the transfer for you.
You can continue this conversation by mentioning me in the message.
Got it. Tagging @User for additional help.
s
@phlanexes You'll need to create a custom call transfer function and assign the caller ID to the customer's number. This way, when the call is transferred to the destination, the caller ID will appear as the customer's number. Let me know if you need any further help.
p
should I do this from the dashboard or via make? or rather let me ask like this. All I need is to make the transfer with the customer number while making a call transfer. what is the simplest way to do this?
s
@phlanexes All you want is to show customer number, then you can set it using caller ID by setting it to the customer number on your destination number. 1. First, you need to create a tool with a name other than "transfer call", such as "customTransferCall" 2. You need to attach the tool to your assistant
Copy code
curl -X POST https://api.vapi.ai/assistant \
     -H "Authorization: Bearer " \
     -H "Content-Type: application/json" \
     -d '{
  "model": {
    "provider": "openai",
    "tools": [
      {
        "type": "transferCall",
        "async": false,
        "function": {
          "name": "customTransferCall"
        },
        "destinations": [
          {
            "type": "number",
            "number": "your-destination-number-here",
            "numberE164CheckEnabled": false,
            "callerId": "your-customer-number-will-work-as-caller-id-here"
          }
        ]
      }
    ],
    "model": "gpt-4o"
  }
}'
3. You need to use the same tool name inside your prompt for the transfer call 4. Make, sure to included the tool, within your prompt.
@phlanexes do let me know how it goes!!
p
@Shubham Bajaj I created a test as in the attachment <?php $apiUrl = "https://api.vapi.ai/assistant"; $authorizationToken = "5974304b-1896-4c50-xxxxxxxxx"; $destinationNumber = "83340xxxxx"; $callerId = "70258xxxxx"; $data = [ "model" => [ "provider" => "openai", "tools" => [ [ "type" => "transferCall", "async" => false, "function" => [ "name" => "customCallTransfer" ], "destinations" => [ [ "type" => "number", "number" => $destinationNumber, "numberE164CheckEnabled" => false, "callerId" => $callerId ] ] ] ], "model" => "gpt-4o" ] ]; $ch = curl_init($apiUrl); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_POST, true); curl_setopt($ch, CURLOPT_HTTPHEADER, [ "Authorization: Bearer $authorizationToken", "Content-Type: application/json" ]); curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data)); $response = curl_exec($ch); if (curl_errno($ch)) { echo 'cURL Error: ' . curl_error($ch); } else { $responseData = json_decode($response, true); print_r($responseData); } curl_close($ch); ?> But when I call this scenario, the transfer still does not go through with the customer number and a new empty assistant is constantly created on the dashboard. https://cdn.discordapp.com/attachments/1326935139518775366/1328362720222904424/Ekran_Resmi_2025-01-13_16.53.13.png?ex=67866db0&is=67851c30&hm=6bf03b308960144a79c3a1cdef48cfff7bcab83af98383f2e313e9a987bb137d& https://cdn.discordapp.com/attachments/1326935139518775366/1328362720528961558/Ekran_Resmi_2025-01-13_16.53.27.png?ex=67866db0&is=67851c30&hm=8bda34ead51961cc32097b0fab4b800bd11d1607f770933d5738f0d076a177c6& https://cdn.discordapp.com/attachments/1326935139518775366/1328362720898056203/Ekran_Resmi_2025-01-13_16.55.40.png?ex=67866db0&is=67851c30&hm=d95bcafc20bd2f0969b175ece0e41d9bd90bf59ac9fc7b4b6c1ce6669f4b6d8c&
s
@phlanexes My bad, you're supposed to create the tool instead of the assistant. I forgot to mention that the above request is for creating the assistant instead of the tool. Here's the correct API reference for creating a tool: https://docs.vapi.ai/api-reference/tools/create. Because I failed to properly explain that it's for the using along witht the assistant and how to use it properly, it's not working as expected. If possible, can you join Discord Office hours today? I will resolve it live over the call: https://discord.gg/zVj4GuCZ?event=1325956872708161667
p
@Shubham Bajaj I may be out of the office at that time. If there is a video recording, I would love to watch it.
s
@phlanexes you can simply create the tool using the create tool api and then includes it's tool with your assistant it will work.
These OH are not recorded.
Do let me know if you require further help.
p
Is there a difference between the tool we created via Dashboard and the tool we created via API?
s
No there is no difference.
p
I finally got it done