Hi @sack5539 I am trying to build an
# general-english
a
Hi @sack5539 I am trying to build an agent allocation service in such a way that when an inbound call is coming and is from a number "X" I want agent "A" to be allocated, if the number "Y" is coming I want agent "B" to be allocated. For doing this I want VAPI to send a request to my api endpoint whenever I make a phone call and my server resolves the assistant config that VAPI needs to use cc: @Shubham Bajaj
s
1. A call comes in to your VAPI phone number 2. Before the call connects, VAPI sends a POST request to your configured endpoint with the caller's information 3. Your server processes the request, identifies the phone number (e.g., "X") 4. Your server responds with a configuration for agent "A" 5. VAPI applies this configuration to the call session 6. The caller interacts with the properly allocated agent VAPI provides a feature called "Server Event Request Assistant" which allows you to dynamically configure your assistant based on call context. When a call is received, VAPI can make an HTTP request to your endpoint with caller information, and your server can respond with the appropriate assistant configuration.
a
Hi, I configured with an endpoint but there is still a problem, I don't get requests from VAPI on my endpoint
s
@aadilghani did you assign the server url to your phone_number? if so can you share the phone number ID?
a
Yes I did
861d030f-2707-4150-8e45-f922bd90b0cc
Phone number id
@Shubham Bajaj any update? 🙂
Inbound in general fails
This is the phone number id 9f28cbac-401c-47e0-b6c9-2309ecfb352e
s
@aadilghani looking into it...
@aadilghani Ok, you have assigned this Assistant ID to the phone number and not the Server URL. Because of this, you never get any request on your server URL instead a default assistant is being used. First, remove the Assistant ID. Then, assign a Server URL to your phone number. To assign this server URL, I'll suggest using the update phone number API available over VAPI docs under the API reference page. https://cdn.discordapp.com/attachments/1350156271898333295/1351267699493441586/Screenshot_2025-03-18_at_12.24.13_AM.png?ex=67d9c19c&is=67d8701c&hm=1ddec6aa88916c0f0f2395b21b34816a5baff3c7a1a9f696f023fc0ee8c7b792&
a
Hi Shubham
Sorry for not responding earlier
Sahil from your support team already fixed my issue
Problem was my phone number assigned in 2 organisations
It’s fixed now
You guys are awesome! Thanks