1. Go to this page and download the library: Download flex/express 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/ */
flex / express example snippets
use Flex\Express\Express100;
$express = new Express100('app_id','app_key');
$info = $express->track($tracking_code, $shipping_code, $phone); //快递单号 物流公司编号 收件人手机号(顺丰必填 其他快递选填)
use Flex\Express\ExpressBird;
$express = new ExpressBird('app_id','app_key');
$info = $express->track($tracking_code, $shipping_code,$order_code); //快递单号 物流公司编号 订单编号(选填)
use Flex\Express\Express;
$express = new Express($app_id,$app_key,$type); //$type支持类型'express100'、'expressbird'
//快递鸟$additional=['order_code'=>111111] 快递100 $additional=['phone'=>'18899996666']
$info = $express->track($tracking_code, $shipping_code,$additional); ////查询物流 快递单号 额外参数