Download the PHP package pricemotion/sdk without Composer
On this page you can find all versions of the php package pricemotion/sdk. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download pricemotion/sdk
More information about pricemotion/sdk
Files in pricemotion/sdk
Package sdk
Short Description Provides logic shared between Pricemotion integrations for PHP e-commerce systems
License MIT
Informations about the package sdk
Pricemotion SDK
This SDK is used internally for Pricemotion's integrations with different e-commerce systems. It may also be used by customers to integrate with custom or unsupported systems.
Currently this SDK does not provide a complete interface for Pricemotion's API. What it does contain is logic for handling webhook requests, and for processing the XML returned by the Pricemotion API.
Links:
Getting started
Installation is easy, whether you use Composer or not.
With Composer
Run:
composer require pricemotion/sdk
Make sure that vendor/autoload.php
is require
d in your scripts.
Without Composer
Download the source code from the Releases page on GitHub.
Extract it.
Require autoload.php
in your scripts.
Dependency injection
If you use a framework that supports automatic dependency injection (autowiring) such as Symfony, or have manually integrated a dependency container such as PHP-DI in your project, you should be able to use it to automatically initialize most of the classes in this SDK.
Handling webhooks
A cache is required for storing Pricemotion's public keys, so that they do not have to retrieved on each request. Any cache that implements Symfony's cache contract is supported.
For example, you might install symfony/cache
using Composer and initialize it
as follows:
With the cache ready, you can decode incoming webhook requests as follows:
Using product data
Getting the EAN:
Getting the product name:
Getting the price statistics:
Getting the offers ranked from lowest to highest price:
All versions of sdk with dependencies
ext-json Version *
ext-sodium Version *
ext-dom Version *
ext-curl Version *