2017 © Pedro PelĂĄez
 

library sharpspring-api

image

colling-media/sharpspring-api

  • Wednesday, November 9, 2016
  • by darkgoldblade01
  • Repository
  • 1 Watchers
  • 0 Stars
  • 1,414 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 2 Versions
  • 11 % Grown

The README.md

SharpSpring API

Super-simple SharpSpring API v1 wrapper, in PHP., (*1)

Let's improve your website with Marketing Automation and Inbound Marketing., (*2)

by Angelo PĂșblio, (*3)

Declare your accountID and secretKEY

if ( !defined('SHARPSPRING_ACCOUNTID') )
    define('SHARPSPRING_ACCOUNTID', 'YOUR-ACCOUNT-ID');

if ( !defined('SHARPSPRING_SECRETKEY') )
    define('SHARPSPRING_SECRETKEY', 'YOUR-SECRET-KEY');

Include the lib

Example using the folder '/lib/sharpspring-api/src/' inside the WordPress' theme folder, (*4)

if (!class_exists('AngeloPublio\SharpSpring'))
    require_once(get_template_directory().'/lib/sharpspring-api/src/SharpSpring.php');

Calling the API

Example calling getLeads, (*5)

$SharpSpring = new \AngeloPublio\SharpSpring(SHARPSPRING_ACCOUNTID, SHARPSPRING_SECRETKEY);

$limit = 500;                                                                         
$offset = 0;    

$result = $SharpSpring->call('getLeads', 
                array('where' => array('emailAddress' => 'email-to-filter@test.com'), 'limit' => $limit, 'offset' => $offset)
            );
print_r($result);

Example calling getFields, (*6)

$SharpSpring = new \AngeloPublio\SharpSpring(SHARPSPRING_ACCOUNTID, SHARPSPRING_SECRETKEY);

$limit = 500;                                                                         
$offset = 0;    

$result = $SharpSpring->call('getFields', 
                array('where' => array(), 'limit' => $limit, 'offset' => $offset)
            );
print_r($result);

The Versions

09/11 2016

dev-master

9999999-dev

  Sources   Download

09/11 2016

v0.0.1

0.0.1.0

  Sources   Download