PHP code example of valbeat / trackingmore-php-client

1. Go to this page and download the library: Download valbeat/trackingmore-php-client 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/ */

    

valbeat / trackingmore-php-client example snippets




use TrackingMore\Client;

$apiKey = 'your-api-key';
$client = new Client($apiKey);

// Create a tracking
$trackingData = [...];
$response = $client->createTracking($trackingData);

// Get tracking details
$trackingNumber = 'tracking-number';
$trackingDetails = $client->getTracking($trackingNumber);

// Update tracking details
$updateData = [...];
$response = $client->updateTracking($trackingNumber, $updateData);

// Delete tracking
$response = $client->deleteTracking($trackingNumber);

// And more...
bash
composer