Download the PHP package appoly/shopwired-php-sdk without Composer

On this page you can find all versions of the php package appoly/shopwired-php-sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package shopwired-php-sdk

ShopWired PHP SDK

PHP library to interact with ShopWired - https://www.shopwired.co.uk/

Usage

Installation

Authentication

If using .env to handle environment variables, add:

If not:

Let's do something

To get all products:

Documentation

The classes and methods are based wholly on the endpoints available in the API: https://help.shopwired.co.uk/api/introduction/api-home

Each class will have (up to) the following available functions:

Throttling (Enabled by default)

NOTE: THIS CAN CAUSE THREAD BLOCKING

(https://help.shopwired.co.uk/api/introduction/api-rate-limiting)

We use the leaky bucket algorithm as a controller.

The leaky bucket algorithm allows for infrequent bursts of calls to the API, and allows your APP to continue to make an unlimited amount of calls over time.

The bucket size is 40 and this cannot be exceeded at any given time. The leak rate is 2 calls per second that continually empty the bucket.

If your APP averages 2 calls per second then it will never trip the 429 too many requests error.

API calls will be processed almost instantaneously as long as there is room in your bucket. You can make quick bursts of API calls that exceed the leak rate as long as your average call rate does not exceed 2 calls per second.

This package, by default, will throttle your requests based on this algorithm and these parameters. This uses sleep to time requests once the limits are hit, will mean that thread may run slowly.

Requirements

The throttling requires redis, to implement the limit between different sessions.

Disable

Warning: Disabling the throttling may cause the request to fail with 429 too many requests.

To disable the throttling use:


All versions of shopwired-php-sdk with dependencies

PHP Build Version
Package Version
Requires guzzlehttp/guzzle Version ^6.5 || ^7.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package appoly/shopwired-php-sdk contains the following files

Loading the files please wait ....