Zimbra offers Open Source email server software and shared calendar for Linux and the Mac
 
Go Back   Zimbra - Forums > Zimbra Collaboration Suite > Users

Welcome to the Zimbra - Forums!
Welcome, if you would like to post a comment please register. We also encourage you to explore all things Zimbra with our team and members of the community.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-16-2007, 05:27 AM
Junior Member
 
Posts: 5
Default SOAP API get contacts matching given phone number

Hello Folks,

I want to query the zimbra contacts database.
I want to get the contacts from all zimbra users which have the phone number matching the number i provide in the query say something similiar to query like this
Select name,email,phoneno,mobileno from users where phoneno like '77686%' or mobileno like '768768%'
I am new to zimbra, although i went through the posts and found that zimbra is not storing the user contacts in LDAP however has a SOAP api to access the same.
Could some one help me how i can acheive what i want using the API.

Thanks
Bhavi
Reply With Quote
  #2 (permalink)  
Old 04-17-2007, 07:09 AM
Zimbra Employee
 
Posts: 4,784
Default

You'll want SearchRequest with the type set to contact.

http://zimbra.svn.sourceforge.net/vi...88&view=markup


See the query language in the above post that may help like the contact: operator.
__________________
Bugzilla - Wiki - Downloads - Offline Client
Reply With Quote
  #3 (permalink)  
Old 11-11-2007, 01:31 PM
Intermediate Member
 
Posts: 15
Default

Hi,

that is exactly what i am looking for, too. I just did some tests with the scripts i found here: SourceForge.net Repository - [zimbra] Index of /trunk/ZimbraServer/src/perl/soap

but i still have some questions:

1) query for a special contact details is not possible? workPhone=8888*
2) * is ignored at the beginning of a queryString? (*99*)

i want to make a script that get's started from asterisk phone and searches the corresponding name in the addressbook. What is the best way to do this?
Search with SOAP for <query>%number%</query> and then parse the xml response? Any other/better way?

Anyone made that before ?! (integration with asterisk)

Thanks
Martin
Reply With Quote
  #4 (permalink)  
Old 11-11-2007, 01:40 PM
Intermediate Member
 
Posts: 15
Default

Hi,

i want to make an integration with asterisk phone server and query the zimbra addressbok for the FullName to the CallerID.

i did some tests with the scripts found at SourceForge.net Repository - [zimbra] Index of /trunk/ZimbraServer/src/perl/soap

but i still have some questions:

1) search for a contact detail isn't possible? workPhone,email?
2) the * is ignored at a beginning of a query? "*99*" search for "99*"
3) build a soap query with the phone number and parse the response for FullName is the best way to get name to number? any other/better way?

has someone already implemented a script for asterisk agi to lookup the name in the zimbra adressbook? maybe he could share that with us

Thanks
Martin
Reply With Quote
Reply


Thread Tools
Display Modes


Similar Threads

Why Join?

Registering let's you ask questions, makes it easier to search, displays any files attached to posts, and notifies you about replies.

Zimbrablog.com




 

Search Engine Optimization by vBSEO 3.1.0