If you've ever created an Adhearsion application, you've probably poked through the events.rb file that's included in the root directory by default. Though its usage case may be initially opaque, consider the following scenarios:
The events.rb file and the DSL surrounding it was invented for this reason.
The file is all pure-Ruby with a few user-friendly APIs exposed. You'll primarily need to register new event handlers with the following (example) syntax:
A few examples like this are included by default with the sample events.rb file.events.asterisk.before_call.each do |call|
ahn_log.dialplan "Handling call with " + call.variables.inspect
end
Page Information
|
Wiki Information |
Recent PBwiki Blog Posts |