[Freeswitch-users] XML (curl) returned for Event-Calling-Function = switch_xml_locate_user

Mathieu Rene mrene_lists at avgs.ca
Tue Mar 24 22:57:07 PDT 2009


As Raul said, the user_exists function will look for a user  
*attribute* so unless you write your user as <user id="blah"  
accountcode="blah2">, you need to use id (and the later wouldnt set  
the accountcode variable, no)

Math

On 25-Mar-09, at 1:53 AM, Raul Fragoso wrote:

> You should use the id value of the user, not accountcode:
>
> user_exists id gigaset toyos.nl
>
> Regards,
>
> Raul
>
> On Tue, 2009-03-24 at 15:55 +0100, Leon de Rooij wrote:
>> Hi,
>>
>> I'm trying to get some cli commands working in combination with xml-
>> curl.
>>
>> Endpoints are parsed properly for SIP registrations and invites, but
>> when I use the CLI command "user_exists" it returns false, while I do
>> return an  endpoint (same syntax as for a sofia_reg_parse_auth event)
>> on the webserver.
>>
>> Should switch_xml_locate_user event receive a different syntax ?
>>
>> freeswitch at internal> user_exists accountcode gigaset toyos.nl
>> false
>>
>> XML returned from webserver:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <document type="freeswitch/xml">
>> <section name="directory">
>>   <domain name="toyos.nl">
>>     <user id="gigaset" mailbox="">
>>       <params>
>>         <param name="a1-hash"
>> value="a211336e29c4f3756e6af343ce6da27b"/>
>>         <param name="email-addr" value="test at test.com"/>
>>         <param name="vm-delete-file" value="true"/>
>>         <param name="vm-attach-file" value="true"/>
>>       </params>
>>       <variables>
>>         <variable name="accountcode" value="gigaset"/>
>>         <variable name="caller_id_name" value="gigaset"/>
>>         <variable name="caller_id_number" value="1000"/>
>>         <variable name="email_addr" value="test at test.com"/>
>>         <variable name="privacy" value="no"/>
>>         <variable name="process_cdr" value="true"/>
>>         <variable name="sip_secure_media" value="false"/>
>>         <variable name="country_code" value="31"/>
>>         <variable name="area_code" value="320"/>
>>       </variables>
>>     </user>
>>   </domain>
>> </section>
>> </document>
>>
>> thanks & regards,
>>
>> Leon
>>
>>
>> _______________________________________________
>> 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