GithubHelp home page GithubHelp logo

Comments (5)

leungkinghin avatar leungkinghin commented on June 16, 2024

@satyam21041997 Thank you for your reporting.

I believe that the error is about CORS issue (Cross Origin Resource Sharing). You can check more details here
https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS/Errors

There would be 2 possible solutions here

  1. Setup a proxy with the same domain as front-end page, so that front-end page can send request to this proxy server and redirect REST API call to Adyen.
  2. Use pre-built UI options supported by Adyen in your front-end page instead of making API call by yourself. For details, please check out here
    https://docs.adyen.com/online-payments/prebuilt-ui#components

from adyen-commercetools.

satyam21041997 avatar satyam21041997 commented on June 16, 2024

Hi @leungkinghin ,
Can you please help me to provide more detail for the solution you have provided.

I also tried to add a localhost server to adyen account for allowed origin.
image

Please find the attached code for your reference.
PaymentMethod.txt

from adyen-commercetools.

leungkinghin avatar leungkinghin commented on June 16, 2024

Hello @satyam21041997
I think setting localhost as allowed origin would not help as it is not the actual domain URL of your page. Adyen platform cannot recognise where localhost is located.

Also, after i checked your attached code, you are adapting Adyen SDK to make API request. I would suggest you to raise a support ticket to Adyen directly in this case. Here we are supporting the integration between Commercetools and Adyen platform. Hope you could understand.

from adyen-commercetools.

satyam21041997 avatar satyam21041997 commented on June 16, 2024

Hi @leungkinghin ,
Thanks for your response. I think you are right we can't use localhost URL as allowed origin.
Now my this issue is fixed I am calling Adyen payments API from AWS API gateway and it is working fine.
Can you please help me to add this integration to CommerceTools Sunrise application?
I am using AWS lambda for this.

from adyen-commercetools.

leungkinghin avatar leungkinghin commented on June 16, 2024

Hi @satyam21041997
Thank you for your feedback.
I understand that you are trying to communicate with Adyen payment platform with application powered by the CT Sunrise.
Here are two possible strategies :

  1. Communicate to Adyen API directly (I suppose it is the approach you are working on)
  2. Persist your data into Commercetools platform plus this Integration.

Regarding point 2, you need to access and administrate one Commercetools project. And then setup API extension in it which would trigger synchronous call to this integration on AWS lambda when you update Commercetools payment

For more details how the entire flow works between this integration, CT platform and Adyen platform, please refer to our documentations below :
Overview
Integration Guide

from adyen-commercetools.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.