PHP code example of acut-fulfillment / wms

1. Go to this page and download the library: Download acut-fulfillment/wms library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

acut-fulfillment / wms example snippets




$wms = new AcutFulfillment\Wms\Wms(
    apiKey: 'YOUR_API_KEY',
    user: 'YOUR_USERNAME',
    password: 'YOUR_PASSWORD'
);

$req = $wms->getOrders();

if ($req->failed()) {
    echo "Request failed with status {$req->getStatus()} and message {$req->getMessage()}";
} else {
    $orders = $req->getResponse();

    foreach ($orders['data'] as $order) {
        // ...
    }
}

$req = $wms->getOrders([
    'current_status' => 1, // returns only open orders
    'page' => 1, // returns the first page
    'page_size' => 10 // returns max. 10 entries per page
]);