[Freeswitch-users] FreeSWITCH, mod_managed and IApiPlugin

Schenk, Oliver OSchenk at wnr.com.au
Tue May 3 08:02:52 MSD 2011


Hi All,

 

I'm completely new to FreeSWITCH, but in a week I managed to achieve
quite a bit. It was quite a learning curve to say the least. This is my
current setup:

 

-          FreeSWITCH 1.0.7 built from tarball.

-          Developing on Windows XP with VS2008 in C#.

-          Configured extension 1024 to connect to a managed dll file,
which implements IAppPlugin.

-          Using X-Lite softphone I can connect to FreeSWITCH as user
1001 and dial 1024 and start going through a menu that I built in C#. It
successfully retrieves records from an SQL database and so forth. No
problems there.

 

My first step was to create a module that gets called whenever a user
dials IN bound. They will hear the menu just described.

 

 

My struggle now is relating to OUT bound calls. What I want is a module
that is started as soon as FreeSWITCH is started and begins executing on
an endless processing loop in the background. This will continuously
monitor a database and if certain conditions occur an outbound call
should be queued and then made. If multiple calls need to be made I
guess they will be queued and processed one by one. I can handle the
queuing part.

 

At this stage I will be testing using extension 1001 as the receiver of
the call using my softphone.

 

 

Question 1:

 

I've been trying to use a class that implements IApiPlugin, but how do I
get it to start when FreeSWITCH starts? As I said it should simply be a
never ending thread as long as FreeSWITCH is running. I can't find any
information regarding how to "Execute" a managed module immediately when
FreeSWITCH has started.

 

 

Question 2:

 

If IApiPlugin can do this, how do I get the session object? Like this?

ManagedSession session = new ManagedSession();

session.Originate(???);

 

I can't find any help at all on this.

 

 

Thanks very much!

 

 

 

Oliver Schenk

 


NOTICE - This e-mail and any files transmitted with it are confidential and are only for the use of the person to whom they are addressed. 
If you are not the intended recipient then you have received this e-mail in error; please advise us immediately if this is the case. 
Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of WestNet Rail.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20110503/f38c691a/attachment.html 


More information about the FreeSWITCH-users mailing list