Get agents using phone number
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents \
--header 'Authorization: Bearer <token>'import requests
url = "https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"phoneNumber": "<string>",
"affectedAgents": [
{
"agentId": "<string>",
"agentName": "<string>",
"uses": [
"inbound"
]
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Get agents using phone number
Returns a list of agents that use this SIP phone number. Phone numbers can be used for both inbound call routing (linked agent) and outbound calls (agents configured to use this number for making calls).
GET
/
api
/
v1
/
sip-phone-numbers
/
{id}
/
affected-agents
Get agents using phone number
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request GET \
--url https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents \
--header 'Authorization: Bearer <token>'import requests
url = "https://blackbox.dasha.ai/api/v1/sip-phone-numbers/{id}/affected-agents"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text){
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"phoneNumber": "<string>",
"affectedAgents": [
{
"agentId": "<string>",
"agentName": "<string>",
"uses": [
"inbound"
]
}
]
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Usage Types
Phone numbers can be used by agents in two ways: Inbound (Linked Agent):- One agent can be linked to receive inbound calls on this number
- Incoming calls are automatically routed to the linked agent
- Multiple agents can use this number for making outbound calls
- The number appears as caller ID when agents make calls
Response
Returns affected agents successfully
Phone number and its associated agents that will be impacted by SIP configuration changes. Shows which agents use this phone number for inbound or outbound calls, helping you assess the impact before making changes.
Was this page helpful?