• vygala sainath
  • NEWBIE
  • 0 Points
  • Member since 2014

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 1
    Replies

i am trying to develop visualforce page. i want to make a call. iwrite a code 

 

public class SampleClass{

String account = 'XXXXXXXXXXXXXXXXXXX';
String token = 'YYYYYYYYYYYYYYYYYY';

public PageReference hello(){
TwilioRestClient client = new TwilioRestClient(account, token);

Map<String,String> params = new Map<String,String> {
        'To'   => '+919953938584',
        'From' => '+919910728457',
        'Url' => 'http://twimlets.com/holdmusic?Bucket=com.twilio.music.ambient'
    };
TwilioCall call = client.getAccount().getCalls().create(params);
return null ;

}

}

 

and vsualforce page

 

<apex:page controller="SampleClass">

    <apex:form >
            <apex:commandButton action="{!hello}" value="Make a Call"/>
    </apex:form>

</apex:page>

 

 

both the numbers are verified so call is going and a music is playing.now i want that when the user click  make a call button then he can talk to the dialled phone number.means his voice went to the number which is dialled and he can hear that voice.in other way that user can dial a phone number and talk to a  person using only browser .is this possible .Please guideline .

  • September 17, 2013
  • Like
  • 0