2017 © Pedro PelĂĄez
 

library dolist

A PHP5 library to interact with the API of Dolist CRM

image

mremi/dolist

A PHP5 library to interact with the API of Dolist CRM

  • Sunday, April 26, 2015
  • by mremi
  • Repository
  • 1 Watchers
  • 7 Stars
  • 698 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 5 % Grown

The README.md

Dolist library

SensioLabsInsight, (*1)

Build Status Total Downloads Latest Stable Version, (*2)

This library allows you to interact with the API of Dolist CRM., (*3)

Basic Docs, (*4)

, (*5)

Installation

Only 1 step:, (*6)

Download Dolist using composer

Add Dolist in your composer.json:, (*7)

{
    "require": {
        "mremi/dolist": "dev-master"
    }
}

Now tell composer to download the library by running the command:, (*8)

``` bash $ php composer.phar update mremi/dolist, (*9)


Composer will install the library to your project's `vendor/mremi` directory. <a name="add-contact"></a> ## Add/update a contact ```php <?php use Mremi\Dolist\Authentication\AuthenticationManager; use Mremi\Dolist\Authentication\AuthenticationRequest; use Mremi\Dolist\Contact\ContactManager; use Mremi\Dolist\Contact\FieldManager; $contactSoapClient = new \SoapClient('http://api.dolist.net/v2/ContactManagementService.svc?wsdl', array( 'soap_version' => SOAP_1_1, 'trace' => true, 'connection_timeout' => 2, // ... )); $authSoapClient = new \SoapClient('http://api.dolist.net/v2/AuthenticationService.svc?wsdl', array( 'soap_version' => SOAP_1_1, 'trace' => true, 'connection_timeout' => 2, // ... )); $authRequest = new AuthenticationRequest('YOUR_ACCOUNT_IDENTIFIER', 'YOUR_AUTHENTICATION_KEY'); $authManager = new AuthenticationManager($authSoapClient, $authRequest, 3); $contactManager = new ContactManager($contactSoapClient, $authManager, 3); $fieldManager = new FieldManager; $contact = $contactManager->create(); $contact->setEmail('test@example.com'); $contact->addField($fieldManager->create('firstname', 'Firstname')); $contact->addField($fieldManager->create('lastname', 'Lastname')); $ticket = $contactManager->save($contact); $saved = $contactManager->getStatusByTicket($ticket); if ($saved->isOk()) { // contact has been saved... } else { // something is wrong... echo sprintf('Returned code: %s, description: %s', $saved->getReturnCode(), $saved->getDescription()); }

, (*10)

Retrieve contacts

<?php

use Mremi\Dolist\Contact\GetContactRequest;

$request = new GetContactRequest;
$request->setOffset(50);
// ...
$contacts = $contactManager->getContacts($request);
// ...

, (*11)

Contribution

Any question or feedback? Open an issue and I will try to reply quickly., (*12)

A feature is missing here? Feel free to create a pull request to solve it!, (*13)

I hope this has been useful and has helped you. If so, share it and recommend it! :), (*14)

@mremitsme, (*15)

The Versions

26/04 2015

dev-master

9999999-dev https://github.com/mremi/Dolist

A PHP5 library to interact with the API of Dolist CRM

  Sources   Download

MIT

The Requires

 

by RĂ©mi Marseille

api soap crm dolist

19/07 2013

v1.0.0

1.0.0.0 https://github.com/mremi/Dolist

A PHP5 library to interact with the API of Dolist CRM

  Sources   Download

MIT

The Requires

 

by RĂ©mi Marseille

api soap crm dolist