You need to sign in to do that
Don't have an account?
Raheel Iqbal
Salesforce Make A Call Error
Hi,
I'm trying to integrate Cisco finesse call controls in my salesforce organization. I'm done with sign in and state transitions of agent but now stuck at making call. I'm receiving the following error to requesting make call api in apex:
IO Exception: Unable to tunnel through proxy. Proxy returns "HTTP/1.0 503 Service Unavailable.
Check this code is anything wrong?
I'm trying to integrate Cisco finesse call controls in my salesforce organization. I'm done with sign in and state transitions of agent but now stuck at making call. I'm receiving the following error to requesting make call api in apex:
IO Exception: Unable to tunnel through proxy. Proxy returns "HTTP/1.0 503 Service Unavailable.
Check this code is anything wrong?
Http http = new Http(); HttpRequest request = new HttpRequest(); // Setting authorization header Blob headerValue = Blob.valueOf(account + ':' + token); String authorizationHeader = 'BASIC ' + EncodingUtil.base64Encode(headerValue); request.setHeader('Authorization', authorizationHeader); request.setEndpoint('https://uccx1.dcloud.cisco.com:8445/finesse/api/User/' + account + '/Dialogs'); request.setMethod('POST'); request.setHeader('Content-Type', 'application/xml;charset=UTF-8'); // Set the body as a JSON object request.setBody('<Dialog><requestedAction>MAKE_CALL</requestedAction><fromAddress>1081</fromAddress><toAddress>1080</toAddress></Dialog>'); HttpResponse response = http.send(request); CallResult result = new CallResult(); result.status = response.getStatus(); return result;
Greetings to you!
This error happens if your firewall doesn’t allow access to your server where the web service is hosted. Making the firewall changes should fix this issue.
In general, when you see an issue, follow this checklist to troubleshoot the issue:
Also, check whether you have white-listed salesforce IP's in their proxy: http://www.salesforcegeneral.com/salesforce-articles/ip-whitelists-for-salesforce.html
I hope it helps you.
Kindly let me know if it helps you and close your query by marking it as solved so that it can help others in the future. It will help to keep this community clean.
Thanks and Regards,
Khan Anas
This has to be resolved at the client end to which you are making the webservice callout .
Ask your other Team who have created that webservice and check whether they have white-listed salesforce IP's in their proxy .The Proxy here is not allowing your request to reach the exact end point and its filtering request from the SFDC.
http://www.salesforcegeneral.com/salesforce-articles/ip-whitelists-for-salesforce.html
https://help.salesforce.com/articleView?id=000003652&type=1