wndr / logic4
Logic4 PHP-SDK
1.0.4
2024-02-23 12:17 UTC
Requires
- sammyjo20/saloon: ^2.0
README
This package is slim wrapper around the Logic4 API. It's an opinionated integration that uses Saloon as a client/wrapper and handles general tasks like authentication.
How to use
// Set configuration $connector = new \Wndr\Logic4\Connectors\Logic4Connector(); $connector->setAdministrationId('xx') ->setCompanyKey('xx') ->setPrivateKey('xx') ->setPublicKey('xx') ->setUsername('xx') ->setPassword('xx') ->authenticate($connector->getAccessToken()) // Create request $request = new \Wndr\Logic4\Requests\Orders\GetOrders([ 'Id' => 'xx', 'TakeRecords' => 1 ]); // Get results $response = $connector->send($request)->json();
Install
composer require wndr/logic4