Skip to content

[Bug]: GRAPHQL - Payment canceled with multiple payment attempts #2999

@dimitriBouteille

Description

@dimitriBouteille

Description

Payment canceled with multiple payment attempts

Steps to reproduce

  1. Make a first payment attempt that is refused
  2. Then make a second payment attempt which is accepted

Actual behavior

When a customer makes a first payment attempt that fails, then makes a second attempt that works, the order is sometimes canceled because the webhook of the first attempt is executed.

Here is an example of the bug :

  • at 7:07 - X5BDWNSMTT5FBHG6 : the customer makes a first payment which is refused because fraud
  • at 7:07 : Adyen send webhook AUTHORISATION for PSP X5BDWNSMTT5FBHG6 with success=false in body
  • at 7:10 - G632MTL5G45BS6H3 : the client makes a new payment again which is accepted
  • at 7:10 : Adyen send webhook AUTHORISATION for PSP G632MTL5G45BS6H3 with success=true in body
  • at 7:12 : The notification for PSP G632MTL5G45BS6H3 is executed
  • at 7:19 : The notification for PSP X5BDWNSMTT5FBHG6is executed
  • at 7:19 : Order is canceled with /cancel request to

Image

Image

Image

Expected behavior

In this case, the order should not have been canceled since the second payment is valid.

When canceling the order, I think it is necessary to check that the PSP associated with the last payment is identical to the PSP used in the webhook.

Code snippet or screenshots (if applicable)

No response

Adyen Magento Plugin version

9.18.1

Magento version

2.4.7-p6

Operating System

None

Browser (if applicable)

No response

Additional context and logs

No response

Metadata

Metadata

Assignees

Labels

Bug reportIndicates that issue has been marked as a possible bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions