Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CheckoutStateDataValidator does not allow RequestedTestAcquirerResponseCode for testing purposes #531

Closed
AndreasA opened this issue Aug 2, 2023 · 2 comments

Comments

@AndreasA
Copy link

AndreasA commented Aug 2, 2023

Describe the bug
According to Adyen documentation and my own tests the additionalData with RequestedTestAcquirerResponseCode can be used to test error responses.

However, the current implementation of https://github.com/Adyen/adyen-php-api-library/blob/develop/src/Adyen/Service/Validator/CheckoutStateDataValidator.php

does not allow RequestedTestAcquirerResponseCode to be used in that array, so e.g. the Shopware 6 Adyen plugin will remove that property if added to the payment request data.

On the other hand for live environments that option really is invalid, so to be perfectly safe it should only be available on the sandbox. However, I don't think that property is used by the production endpoint (at least I hope so), so submitting it shouldn't be an issue then either.

I also created an issue for Shopware 6 plugin, to provide a way to easily provide that code. These two issues are a bit related (though not the same): Adyen/adyen-shopware6#210

To Reproduce

Use CheckoutStateDataValidator to sanitize data and provide RequestedTestAcquirerResponseCode in additional data. As even additional data does not seem to be allowed.

@wboereboom
Copy link
Contributor

Hi @AndreasA ,

Thanks for raising this issue, and apologies for the belated response.

The stateDateValidatoer is marked as deprecated, and will be removed in a future major release.
Therefore we don't recommend its use any longer.

Kind Regards,
Wouter
Adyen

@AndreasA
Copy link
Author

created a corresponding issue for Shopwate 6 Adyen/adyen-shopware6#424 and with that I close this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants