1

enter image description here

we are using Vercel for making development fast . in our react app , after payment page when payment redirect to our given url it gives 405 http error, how can we handle this?

Amir Doreh
  • 1,369
  • 1
  • 13
  • 25

2 Answers2

0

I finally found the problem , it is coming from PayTabs's side followings are the logic they are handling wrong:

enter image description here

  1. when nothing is received from callback url , they should not redirect us with given redirect url
  2. when we are giving an invalid callback url it make a GET request to given redirect url
  3. when we are giving an valid callback url which returns 200 to them it make a POST request to given redirect url which is not supported by browser.
Amir Doreh
  • 1,369
  • 1
  • 13
  • 25
0

This error happens when your page does not use next js serverside rendering. I had same issue but solved it by converting the page from a static page to a server rendered page using getServerSideProps

sultan
  • 9
  • 1
  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Dec 19 '22 at 08:51