From efd1a4330be1b12cebcb6fd4bcb58c2d4b84f9a6 Mon Sep 17 00:00:00 2001 From: Marcus Salinas <12.marcus.salinas@gmail.com> Date: Sun, 9 May 2021 15:24:34 -0500 Subject: [PATCH] Updating based on API Changes Shippo_Shipment no longer accepts the 'parcels' key and instead only 'parcel' The $shipment key is now 'rates_list' --- examples/get-rates-to-show-customer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/get-rates-to-show-customer.php b/examples/get-rates-to-show-customer.php index a8751da..b239c1e 100644 --- a/examples/get-rates-to-show-customer.php +++ b/examples/get-rates-to-show-customer.php @@ -80,12 +80,12 @@ array( 'address_from'=> $from_address, 'address_to'=> $to_address, - 'parcels'=> array($parcel), + 'parcel'=> $parcel, 'async'=> false, )); // Rates are stored in the `rates` array inside the shipment object -$rates = $shipment['rates']; +$rates = $shipment['rates_list']; // You can now show those rates to the user in your UI. // Most likely you want to show some of the following fields: