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

Did not get response for Card Payment(CORS Policy Error) #613

Open
Bratati14 opened this issue Oct 20, 2023 · 4 comments
Open

Did not get response for Card Payment(CORS Policy Error) #613

Bratati14 opened this issue Oct 20, 2023 · 4 comments

Comments

@Bratati14
Copy link

Hello,

For 2 weeks I have been stuck on a request that does not work whenever i use Maestro Card and Credit Card for payment(using Sandbox) . Its shows some CORS policy error.
I have send request but did not get any response so i simple print the error and i got this error message which is given below.
Error message
Access to XMLHttpRequest at 'https://api.sandbox.mangopay.com/Redirect/ACSWithValidation?token=1533b02f097c48ef879a3ec3bc236bb7&mgpsecureid=1533b02f097c48ef879a3ec3bc236bb7' (redirected from 'https://admin-test.next-commerce.io/buy-out-page-card') from origin 'https://admin-test.next-commerce.io/' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource.

So I connect the MangoPay support team by mail to find help but they reply me to connect to the developer through Github and told me to post my concern here.

Looking forward to your return.

Thanks in advance.

@fredericdelordm
Copy link
Contributor

Hello @Bratati14,

This issue is not with the PHP SDK right?

@Bratati14
Copy link
Author

Hello @fredericdelordm

Can you please let me know whats the exact issues if you say its not with the PHP SDK?

Because In your Documentation for Test Card Details Some Card payments are working(means return back me some response) and some are not working. Whats the exact issues and why some test card are working and some are not.

In our side the below cards are used for payment through sandbox

  1. CB/VISA/MC
    4970107111111119 (with response Payment Fail)
    4970105181818183 (with response errorCode=02625)
  2. Diners
    30123456789001 (with response Success Message)
  3. Maestro/BCMC
    5033951000000004 (did not give any response)- CORS Policy Errror

In our side we allow our server to get response without any restriction.

Looking forward to your return.

Thanks in advance.

@fredericdelordm
Copy link
Contributor

Could you explain me your process to create the request and process a payment? I would like to understand which request are made from the backend (and the PHP SDK) and which are made from the frontend

@Bratati14
Copy link
Author

For Card payment first i registered the card and get card_registration_id,card_registration_url,PreregistrationData,AccessKey. Then send this details with card info to PayIn Create to make the payment.
For Diners(30123456789001 (with response Success Message)) and CB/VISA/MC(4970107111111119 (with response Payment Fail),4970105181818183 (with response errorCode=02625)) I get response but for Maestro i get CORS Policy Errror. I used same function for all type of card payment but others are working except Maestro.
Even I go through our sandbox login and see the Events. In event our card is registered and after that it failed.
Here is the picture form Our sandbox account event.
screenshot-dashboard sandbox mangopay com-2023 11 04-11_02_02

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