1. Go to this page and download the library: Download goldnead/statamic-offers 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/ */
$basket = Basket::make($offer, amountCent: (int) $request->input('amount_cent'));
// throws AmountNotAccepted (an InvalidArgumentException with buyerMessage()) outside the bounds;
// without an amount, the suggestion is used