[Freeswitch-users] What is the difference between preAnswer and ring_ready?

Jason White jason at jasonjgw.net
Sat Aug 29 18:50:30 PDT 2009

Max Bridgewater <max.bridgewater at gmail.com> wrote:
> Hi,
> Assuming an inbound call, I have trouble understanding what the supposed
> difference between the following two set of instructions is:
> session.execute("ring_ready");
> session.set("set", "ringback=/home/ring.wav");

Ring_ready sends a SIP "ringing" message and will use your device's default
ringback sound - at least, that has been my experience. I should remember the
message number in the SIP protocol, but I don't (the SIP experts here will
undoubtedly have the details at the ready).
> and
> session.preAnswer();
> session.streamFile("/home/ring.wav")

I think that will play the file as early media.

More information about the FreeSWITCH-users mailing list