Yet another Go ESL for FreeSwitch, to build lightweight FS event socket application :)
// TODO...
func main() {
server := NewServer(context.TODO(),"0.0.0.0:8080")
server.Callback = func(channel *OutboundChannel) {
channel.Connect()
channel.Answer()
// TODO: create your own state machine model
for event := range channel.Events {
switch event.Name {
case EslEventCustom:
{// custom event logic
channel.Hangup()
}
case EslEventChannelHangupComplete: // create a new cdr send to channel
}
}
channel.Shutdown()
}
}
What is SC?
TODO:
TODO:
Here is a simple clearfy FS manual and introduce some confused concepts in FS not only Channel lifecycle and more.
TODO:
- When Inbound disconnected and how to recover the inbound connection state?
- If sendmsg could recover the session
- Wrap the fsctl commands in this package
- Total callcenter example single node no cluster