Both sides previous revision
Previous revision
Next revision
|
Previous revision
|
docs:xmlrpc [07-12-2013 23:32] cwacha |
docs:xmlrpc [10-10-2019 23:30] cwacha |
| |
===== Getting Started ===== | ===== Getting Started ===== |
- Download an XML-RPC Client such as this one here: http://www.ditchnet.org/xmlrpc/ | {{ :docs:xmlrpc_example.png?nolink&500|}} |
| |
| - Download an XML-RPC Client such as this one here: http://www.ditchnet.org/xmlrpc/ or use the example python script provided here https://svn.code.sf.net/p/iaddressbook/code/trunk/docs/xmlrpc.py |
- Enable the XML-RPC in config.php (HINT: ''$conf['xmlrpc_enable'] = 1'') | - Enable the XML-RPC in config.php (HINT: ''$conf['xmlrpc_enable'] = 1'') |
- Uncomment/setup an XML RPC user in auth.php | - Setup an XML RPC user in auth.php (HINT: uncomment 'abcd' api_key for testing) |
- Set the Endpoint URI to your installation: http://yourdomain.com/your_address_book/xmlrpc.php | - Set the Endpoint URI to your installation: http://yourdomain.com/your_address_book/xmlrpc.php |
- Choose method: ''version'' | - Choose method: ''version'' |
| |
^ Method Name ^ Parameters ^ Return value ^ Description ^ | ^ Method Name ^ Parameters ^ Return value ^ Description ^ |
| | system.listMethods | | array of available methods | Returns all supported methods by iAddressBook XMLRPC | |
| | system.methodSignature | method | signature of method | Returns the method signature for the specified method | |
| | system.methodHelp | method | help string of method | Returns the Parameters and return values for the given method | |
| version | api_key | version string | Returns the iAddressBook version (i.e. "1.0") | | | version | api_key | version string | Returns the iAddressBook version (i.e. "1.0") | |
| get_contact | api_key, contact id | contact | Returns the contact with the given id | | | get_contact | api_key, contact id | contact | Returns the contact with the given id | |
| get_contacts | api_key, search string, limit, offset | contacts | Returns contacts that match search string (or all if string is empty) starting from offset (max. limit contacts) | | | get_contacts | api_key, search string, limit, offset | contacts | Returns contacts that match search string (or all if string is empty) starting from offset (max. limit contacts) | |
| set_contact | api_key, contact | contact id | Adds or modifies a contact, returns insert id | | | set_contact | api_key, contact | contact id | Adds or modifies a contact, returns insert id | |
| count_contact | api_key, search string | number of id's | Returns the number of contacts that match the search string | | | count_contacts | api_key, search string | number of id's | Returns the number of contacts that match the search string | |
| delete_contact | api_key, contact id | success or error | Deletes the contact with the given id, returns success or error | | | delete_contact | api_key, contact id | success or error | Deletes the contact with the given id, returns success or error | |
| import_vcard | api_key, vcard as string | success or error | Imports a vCard into the addressbook, returns success or error | | | import_vcard | api_key, vcard as string | success or error | Imports a vCard into the addressbook, returns success or error | |
| export_vcard | api_key, contact id's | vcards as string | Exports all contacts matching the id's as one vCard string | | | export_vcard | api_key, contact id's | vcards as string | Exports all contacts matching the id's as one vCard string | |
| |
| |