Hi Guys,
I have an app functionality to transfer a call to a particular call queue(Queue A) based on hours. is there an API call to transfer calls to queues?
Thanks,
Tejasri
Hi Guys,
I have an app functionality to transfer a call to a particular call queue(Queue A) based on hours. is there an API call to transfer calls to queues?
Thanks,
Tejasri
Hi @Tejasri_Kalluri
I hope there is no public API available to transfer calls to queues, I will check with the product team and get back to you.
Thanks,
Santhosh
Hi @Tejasri_Kalluri,
How are the hours determined?
If it is also configured as a part of the app, then we can try using a custom action under routing automation to route the call to a particular queue.
Let me know if this works for you?
Hi @Arjun_Paliath,
Yes, hours will be configured. I will check and let you know
Sure, do let me know if you need anything else.
I have added the links to the Routing Automation Documentation below.
Hi @Arjun_Paliath,
I go with sample app form documentation as for me new to this functionality. I follow guidelines workflow I am unable to route the calls to another queue. Can anyone help me to route the calls?
here is my code which action.json is similar to the sample app and server.js is
exports = {
validateVIPPhoneNumber: function (request) {
let validVIPNumbers = ['+18565021484', '+12015844716'],
response = validVIPNumbers.includes(request.input) ? 'valid' : 'invalid';
data = {
response,
"app_variables": {}
};
return renderData(null, { data });
},
validateUserSingleDigit: function (request) {
let validVIPNumbers = ['1', '2'],
response = validVIPNumbers.includes(request.input) ? 'valid' : 'invalid';
// Third party API and response structure
return renderData(null, {
success: true, data: {
response,
"app_variables": {}
}
});
},
validateUserMultipleDigits: function (request) {
let validVIPNumbers = ['11', '12'],
response = validVIPNumbers.includes(request.input) ? 'valid' : 'invalid';
return renderData(null, {
success: true, data: {
response,
"app_variables": {}
}
});
},
validateUserSpeech: function (request) {
let regex = /(transfer)|(call)/,
response = regex.test(request.input) ? 'valid' : 'invalid';
return renderData(null, {
success: true, data: {
response,
"app_variables": {}
}
});
},
respondOrderStatus: function () {
let index = Math.floor(Math.random() * Math.max(5));
let name = ['Freshcaller', "Freshdesk", "Freshsales", "Freshchat", "Freshservice"],
response = arguments[0].input;
return renderData(null, {
success: true, data: {
response, "app_variables": { "name": name[index], status: "in progress" }
}
});
}
};
{
"validateVIPPhoneNumber": {
"display_name": "validate VIP users based on phone numbers",
"parameters": {
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"input": {
"type": "string"
}
},
"required": [
"input"
]
},
"response": {
"type": "object",
"properties": {
"user_id": {
"type": "string"
}
}
},
"description": "Sends an OTP to user's registered email address"
},
"validateUserSingleDigit": {
"display_name": "validate when a single digit input is given",
"parameters": {
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"input": {
"type": "string"
}
},
"required": [
"input"
]
},
"description": "Sends an OTP to user's registered email address",
"response": {
"type": "object",
"properties": {
"user_id": {
"type": "string"
}
}
}
},
"validateUserMultipleDigits": {
"display_name": "validate when a multiple digit input is given",
"parameters": {
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"input": {
"type": "string"
}
},
"required": [
"input"
]
},
"description": "Sends an OTP to user's registered email address",
"response": {
"type": "object",
"properties": {
"user_id": {
"type": "string"
}
}
}
},
"validateUserSpeech": {
"display_name": "validate when a users speech is transcripted and given as input",
"parameters": {
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"input": {
"type": "string"
}
},
"required": [
"input"
]
},
"description": "Sends an OTP to user's registered email address",
"response": {
"type": "object",
"properties": {
"user_id": {
"type": "string"
}
}
}
},
"respondOrderStatus": {
"display_name": "to send the message to be played as a dynmaic message in Freshcaller",
"parameters": {
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"input": {
"type": "string"
}
},
"required": [
"input"
]
},
"description": "Sends an OTP to user's registered email address",
"response": {
"type": "object",
"properties": {
"user_id": {
"type": "string"
}
}
}
}
}
with is my freshcaller work flow
the highlighted one is an app installed in account, and call actions is routing automation and my account type is forest. if you see in server.js validVIPNumbers array I was calling from +12015844716 to +18565021484 number.no response is coming as well as in logs. let me know what I am missing here in code and as well as testing
Let me check @Tejasri_Kalluri, I will update you when I have an update.
@Tejasri_Kalluri Can you provide me with the dist file of your app?
I created a sample app for Routing automation and it worked as expected.
I will verify your routing automation setting and update you if you can share the full zip file.
Hi @Arjun_Paliath,
This is the dist file of my custom app let me know anything needed from my end
routing.zip (3.8 KB)
Ok @Arjun_Paliath, i will check into that
Hi @Tejasri_Kalluri,
Apologies for the delay in getting back to you.
The sample app looks good. However, can you confirm if you have set up the workflow to accept the phone number as the input? I have attached a screenshot below.
The input should be the phone number when you are checking for VIP Numbers.
Let me know if this helps.
Hi @Arjun_Paliath this works for me thank you