Event System Commands
Once connected to a mod_event_socket port, or actually once connected in any way (for example, via other events handler modules) to the Event System, you can interact via simple commands.
A lot of information is exposed online in our http://freeswitch.org/confluence, search for "mod_event_socket", at paragraph "Command Documentation".
Let's see the most important, and don't forget to terminate the command, when all data has been entered (all additional headers, and so on) with double CR/LF (that is, double "Enter").
api
Send an api command (blocking mode) and wait for completion:
api <command><arg>
Api commands are all the ones you can execute typing at the FreeSWITCH console.
Examples:
api originate sofia/mydomain.com/ext@yourvsp.com 1000 api sleep 5000
bgapi
Send an api command (non-blocking mode) this will let you execute a job in the background and the result will be sent as an event with an indicated uuid to match the reply to the command):
bgapi <command...