Composer based Vtiger Web Services Client.
The recommended way to install vtwsphpclib is with Composer. Composer is a dependency management tool for PHP.
Specify vtwsphpclib as a dependency in your composer.json file:
{
"require": {
"vdespa/vtiger": "0.1"
}
}
In case you are new to Composer, you need to include the file /vendor/autoload.php
file.
use Vdespa\Vtiger\WSClient;
$url = 'http://example.com/';
$config = [
'auth' => [
'username' => 'YOURVTIGERUSERNAME',
'accesskey' => 'YOURVTIGERACCESSKEY'
]
];
$wsclient = new WSClient($url, $config);
If an operation fails, the return value will be false. No error will be displayed unless you call
echo $wsclient->getLastError();
$create = $wsclient->createObject('Accounts', array('accountname' => 'Test account'));
Get a list of Vtiger objects that are available when using the API.
$availableModules = $wsclient->getAvailableModules();
-- Work in progress --
Licensed using the MIT license. See LICENSE.
- Build with Guzzle 4.*
- Inspired by vtwsclib – vtiger CRM Web Services Client Library version 1.4