2017 © Pedro Peláez
 

library api

SmartBuy api library

image

smartbuy/api

SmartBuy api library

  • Monday, July 23, 2018
  • by SmartBuyLV
  • Repository
  • 1 Watchers
  • 0 Stars
  • 12 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 11 Versions
  • 0 % Grown

The README.md

smartbuy-api

A PHP wrapper around the SmartBuy API, (*1)

Install

Install http://getcomposer.org/ and run the following command:, (*2)

php composer.phar require smartbuy/api

Examples

Methods

There are 2 common methods to communicate with api:, (*3)

Checks if have query parameter with affiliate ID and sets cookie, (*4)

$api = new Smartbuy\Api\Api($accessToken);
$api->init(); 

Register new order, (*5)


$products = [ [ 'title' => 'Product #1', 'price' => 10, 'quantity' => 1 ], [ 'title' => 'Product #2', 'price' => 4, 'quantity' => 2, 'rate' => 'SB1' ] ]; $api = new Smartbuy\Api\Api($accessToken); $api->orderRegister($orderUniqueNumber, $products);

Cancel existing order, (*6)

$api = new Smartbuy\Api\Api($accessToken);
$api->orderCancel($orderUniqueNumber);

Delete existing order, (*7)

$api = new Smartbuy\Api\Api($accessToken);
$api->orderDelete($orderUniqueNumber);

DEPRECATED Register order (Executes only if have detected affiliate ID), (*8)

$api = new Smartbuy\Api\Api($accessToken);
$api->registerOrder($orderUniqueNumber, $fullAmount, $rateId); // RateId is optional

The Versions

23/07 2018

1.1.3

1.1.3.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.3.0
  • lib-curl *
  • ext-json *

 

api smartbuy

23/07 2018

dev-master

9999999-dev

SmartBuy api library

  Sources   Download

The Requires

  • lib-curl *
  • ext-json *
  • php >=5.3.0

 

api smartbuy

16/05 2018

1.1.2

1.1.2.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.3.0
  • lib-curl *
  • ext-json *

 

api smartbuy

05/03 2018

1.1.1

1.1.1.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.3.0
  • lib-curl *
  • ext-json *

 

api smartbuy

05/03 2018

1.0.04

1.0.04.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.5.0
  • lib-curl *
  • ext-json *

 

api smartbuy

05/03 2018

1.0.4

1.0.4.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.5.0
  • lib-curl *
  • ext-json *

 

api smartbuy

05/03 2018

1.1.0

1.1.0.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.5.0
  • lib-curl *
  • ext-json *

 

api smartbuy

28/02 2018

1.0.3

1.0.3.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.5.0
  • lib-curl *
  • ext-json *

 

api smartbuy

21/02 2018

1.0.2

1.0.2.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.4.0
  • lib-curl *
  • ext-json *

 

api smartbuy

22/01 2018

1.0.1

1.0.1.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.3.0
  • lib-curl *
  • ext-json *

 

api smartbuy

14/01 2018

1.0.0

1.0.0.0

SmartBuy api library

  Sources   Download

The Requires

  • php >=5.3.0
  • lib-curl *
  • ext-json *

 

api smartbuy