All gift card id checks are against string and not numeric.
Add missing checks for card status, card amount value, card amount
currency in any buy card checks.
Add epiration date regex check for buy card
Add request cancled card check.
Test file does not run any tests automatically but they need to be
triggered with the _GET parameters.
A full phpunit test has been added for the full functionality
The method "decodeExceptionMessage" previous located in the
AmazonIncentives\AmazonIncentives main class has been moved to the
AmazonIncentives\Exceptions\AmazonErrors where it logically belongs.
A deprecation phpdoc message has been added for the current version.
Update error messages in curl error part and remove double spaces.
Instead of direct calling Client class and AWS class add a wrapper
method to call those so we can quicker replace under elements and
also do proper testing
Turn on mock tests on AWS side in normal test file
Config setup works with null data if no data is set.
Debugger is now launched in the AamzonIncentive class at the beginning
Debugger id/debug flag set is now one static call
Debugger methods all have proper PHPdoc documentationn added
Fixed Client/Curl error messages to include the original error message
too. Also made sure that a possible null endpoint is not throwing errors
If the exception json is not a json, return the array with message set
to the original string.
Updated the Client error result:
If Rate Exceeded error, set special T001 with RESEND status
Else set normal and ifn othing set to E999 with FAILURE
Because status RESEND/FAILURE has to be checked we also add this to the
Exception return json string.
Also handle unset errors (eg when we get an Rate Limit error)
Move the _ENV check into mtheod
test now has some basic mock tests