Skip to content

Unhandled Promise Rejection: InvalidAccessError: Must create a new ApplePaySession from a user gesture handler. #3839

@thinkasany

Description

@thinkasany

Describe the bug
"@adyen/adyen-web": 5.28.1
When calling the API, an error message will be encountered.

Image
Unhandled Promise Rejection: InvalidAccessError: Must create a new ApplePaySession from a user gesture handler.

To Reproduce
I want to resolve the "adyen applepay token amount mismatch" issue by querying the latest price through a server-side API.

await getPrice();
import AdyenCheckout from '@adyen/adyen-web';
const checkout = new AdyenCheckout(configuration);

Smartphone (please complete the following information):

  • Device: [e.g. iPhone14 Pro]
  • OS: [e.g. iOS26]
  • Browser [e.g. stock browser, safari]

Additional context
The asynchronous request interface can only be executed normally within applyAppleSession, but this configuration is passed to the functions in the adyen SDK along with the price, which will cause the price to be different.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions