[Freeswitch-users] xml_curl and gateways

Peter P GMX Prometheus001 at gmx.net
Thu Sep 18 09:49:37 PDT 2008


Hello Raymond,

I had a look at your code. You are submitting a complete profile for 
sofia.conf, right?

Best regards
Peter


Raymond Chandler schrieb:
> Peter P GMX wrote:
>   
>> According to http://wiki.freeswitch.org/wiki/Mod_xml_curl I'v tried to 
>> set up gateways dynamically, but I do net get it to work:
>> I always get : "Invalid profile"
>>
>> My assumptions for a right xml answer back to FS are as follows, but I 
>> think at least one of it is false:
>> 1. ) I start with
>> <document type='freeswitch/xml'>
>>   <section name='configuration'>
>>     <configuration name='sofia.conf' description='RailsAdditionalConf'>
>> 2.) I do not want to change settings, so I do NOT add a <settings> tag
>> 3.) I want to enhance an existing profile, so I add a profile tag 
>> (<profile name='external'>)
>> 4.) I assume that I can have an existing profile "external" in the xml 
>> conf files and can mix additional parts dynamically into the same profile
>> 5.) Within the profile I want to add gateways, so I add a gateway tag 
>> (<gateways>)
>> 6.) Then I add the gateways
>> 7.) I add the closing tags
>>
>> Which one of the assumptions if wrong?
>>
>>   
>>     
> I think #2 and #3 are wrong, if I understand what you're saying.
>
> Your response will override the static XML files, NOT add to them or 
> "enhance" them
>   
>> The request I receive is as follows:
>> {"key_name"=>"name", "action"=>"directory", "tag_name"=>"configuration", 
>> "key_value"=>"sofia.conf", "controller"=>"xml_curls", 
>> "hostname"=>"freeswitch", "section"=>"configuration"}
>>
>> I only answer once at startup with the follwing:
>> <document type='freeswitch/xml'>
>>   <section name='configuration'>
>>     <configuration name='sofia.conf' description='RailsAdditionalConf'>
>>         <profile name='external'>
>>           <gateways>
>>   <gateway name="freeswitch2">
>>   <param name="username" value="1007"/>
>>   <param name="realm" value="192.168.0.56:5061"/>
>>   <param name="password" value="xxxx"/>
>>   <param name="proxy" value="192.168.0.56"/>
>>   <param name="expire-seconds" value="30"/>
>>   <param name="register" value="true"/>
>>   <param name="register-transport" value="tls"/>
>>   <param name="retry-seconds" value="30"/>
>>   </gateway>
>>           </gateways>
>>         </profile>
>>     </configuration>
>>   </section>
>> </document>
>>
>> Does anybody have a correct XML answer for a gateway and can post it?
>>   
>>     
>
> I wrote quite a bit of stuff that does most of the xml_curl files. 
> sofia.conf was definitely on my list. you can find the stuff that I 
> wrote in ${SVNROOT}/scripts/contrib/intralanman/PHP/fs_curl/
>
> yes, it's in PHP, but it should give you enough of an idea of how to 
> send your responses.
>
>
> -Ray
>
>
>
>   
>> Best regards
>> Peter
>>
>> _______________________________________________
>> Freeswitch-users mailing list
>> Freeswitch-users at lists.freeswitch.org
>> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
>> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
>> http://www.freeswitch.org
>>   
>>     
>
> _______________________________________________
> Freeswitch-users mailing list
> Freeswitch-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>   




More information about the FreeSWITCH-users mailing list