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

Setting an invalid shopper country code on payment session breaks checkout #2643

Open
eamonn-convious opened this issue Apr 14, 2024 · 3 comments
Labels
API issue Relates to the API rather than AdyenWeb dependencies Issue with a project dependency or associated system Progress: on hold

Comments

@eamonn-convious
Copy link

eamonn-convious commented Apr 14, 2024

Describe the bug
A payment session can be created using an invalid country code e.g. GBUK instead of UKGB. In this case the create session endpoint returns 200 success.
When trying to load the payment options form for the session the Adyen widget makes a call to https://checkoutshopper-live.adyen.com/checkoutshopper/v1/sessions/$SESSION_ID/setup and a 500 error is returned.

To Reproduce
Steps to reproduce the behavior:

  1. Create a payment session on api version 1.9.6 POST /checkout/v40/paymentSession with countryCode: "GB" countryCode: "UK"
  2. Adyen returns 200 sucess
  3. Load payment methods using the Adyen frontend widget. A call is made to https://checkoutshopper-live.adyen.com/checkoutshopper/v1/sessions/$SESSION_ID/setup
  4. 500 error is returned and checkout cannot continue

Expected behavior
Either the initial call to create payment session should return an error, or, the invalid country code should be ignored and reverted to default.

Additional context
The documentation states that the countryCode parameter is optional. I'm not entirely clear what the parameter does, or why it can put the checkout to get into a bad state https://docs.adyen.com/api-explorer/Checkout/69/post/sessions#request-countryCode

@sponglord
Copy link
Contributor

@eamonn-convious - just to be clear I find the opposite to be true. If I make a sessions call with GB everything works fine.
However if I use UK then the situation you describe arises: the initial /sessions call works but the subsequent /setup call fails.

But I take you point... I'll pass on your question to our API team

@eamonn-convious
Copy link
Author

@sponglord my mistake. You are correct GB works and UK doesn't.

Thanks for picking this up!

@sponglord
Copy link
Contributor

sponglord commented Apr 16, 2024

The API team has created a ticket for this...

(Internal ref: COAPI-408)

@sponglord sponglord added Progress: on hold dependencies Issue with a project dependency or associated system and removed To be investigated labels Apr 16, 2024
@sponglord sponglord added the API issue Relates to the API rather than AdyenWeb label May 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API issue Relates to the API rather than AdyenWeb dependencies Issue with a project dependency or associated system Progress: on hold
Projects
None yet
Development

No branches or pull requests

2 participants