2017 © Pedro Peláez
 

library databowl-php

Databowl PHP Library

image

databowl/databowl-php

Databowl PHP Library

  • Tuesday, August 19, 2014
  • by Tomdarkness
  • Repository
  • 1 Watchers
  • 0 Stars
  • 9 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

Databowl PHP Library

PHP Library for interacting with the Databowl Leadgen Platform., (*1)

Requirements

  • PHP 5.4+

Installation

We recommend you use Composer to install the library., (*2)

# Install Composer
curl -sS https://getcomposer.org/installer | php

Then, add the Databowl Library to your project's composer.json:, (*3)

{
    "require": {
        "databowl/databowl-php": "0.1.*"
    }
}

Examples

Submitting Leads

/* Create a client, passing the name of the instance to use */
$client = new Databowl\Client('instance-name');
/* Create a new Lead with a campaign ID of 1 and a supplier ID of 5 */
$lead = new Databowl\Leads\Lead(1, 5);

/* Create an array of lead data in the format <fieldName> => <value> */
$data = [
    'f_18_title' => '[title]',
    'f_19_firstname' => '[firstname]',
    'f_20_lastname' => 'Jones',
    'f_17_email' => '[email]',
];

/* Set the lead data */
$lead->getData()->exchangeArray($data);

/* Submit the lead, it returns a new lead */
$newLead = $client->submitLead($lead);

/* Fetch the lead ID and result */
$leadId = $newLead->getLeadId();
$result = $newLead->getResult()->getMessage();

The Versions

19/08 2014

dev-master

9999999-dev

Databowl PHP Library

  Sources   Download

BSD

The Requires

 

by Tom Pryor

19/08 2014

0.1.1

0.1.1.0

Databowl PHP Library

  Sources   Download

BSD

The Requires

 

by Tom Pryor