POSTBACK - The remote server returned an error: (405) Method Not Allowed.

POSTBACK - The remote server returned an error: (405) Method Not Allowed.

  

Hi all

-platform Version 10.0.200.0

-cloud



i create the postback(rest api) on test server

with the ff.config

also create a method POST


but encountered some issue on postback.during testing.

i only have error log on dragonpay (admin access). 

outsystems has no error. 



i also tried testing the api using the postman 


what's the possible cause for this error. do i miss something on configuration.

or any solutions may offer


Regards,

Sherwin





Hi Sherwin,

You'll need to provide a bit more details for us to help you. Also, you didn't add the Postman image, but the Service Studio image twice. Let's see if I understand correctly what you did:

  1. You exposed a REST API, which is an API that's called by an external service provider (DragonPay).
  2. The soul method of this API, PaymentPortalReturn, has its HTTP Method set to POST.
  3. On calling the method, DragonPay encounters an error, 405, indicating that your REST API refuses the method.
  4. You also used Postman to simulate the DragonPay call, with unknown result (you forgot to add the right image).

Now, in order to trace this, I'd advise you to go to Service Center, find the eSpace that exposes the REST API, go to the Integrations tab and set the Logging Level to Full (to do so, click the name of the API, and select "Full" from the drop down, then click "Apply"). This will allow you to see the way that DragonPay (or Postman) calls your API, and also any error messages.

P.S. You've also got a typo in "ApplicantDetails".



Kilian Hekhuis wrote:

Hi Sherwin,

You'll need to provide a bit more details for us to help you. Also, you didn't add the Postman image, but the Service Studio image twice. Let's see if I understand correctly what you did:

  1. You exposed a REST API, which is an API that's called by an external service provider (DragonPay).
  2. The soul method of this API, PaymentPortalReturn, has its HTTP Method set to POST.
  3. On calling the method, DragonPay encounters an error, 405, indicating that your REST API refuses the method.
  4. You also used Postman to simulate the DragonPay call, with unknown result (you forgot to add the right image).

Now, in order to trace this, I'd advise you to go to Service Center, find the eSpace that exposes the REST API, go to the Integrations tab and set the Logging Level to Full (to do so, click the name of the API, and select "Full" from the drop down, then click "Apply"). This will allow you to see the way that DragonPay (or Postman) calls your API, and also any error messages.

P.S. You've also got a typo in "ApplicantDetails".



Hi sir Kilian Hekhuis,

yes sir that was i did,


the logging level was alreay 'Full', but no errors log from outsystems 

sorry this was the Post man result    

im testing the postback(rest api) via postman but get some error

is there other way to test my rest api.

or if to know if i miss some configuration?. 

like http access/permission etch


im not expert on serverside/connections configurations

Regards,

Sherwin











Hi Sherwin,

The Postman message is "The requested resource does not support http method 'POST'". This means that the end point you connect to is not configured to accept a POST. For each REST method you expose, you need to set the HTTP method; by default this is GET:

You need to set the "HTTP Method" property to POST for your PaymentPortalReturn method.

Kilian Hekhuis wrote:

Hi Sherwin,

The Postman message is "The requested resource does not support http method 'POST'". This means that the end point you connect to is not configured to accept a POST. For each REST method you expose, you need to set the HTTP method; by default this is GET:

You need to set the "HTTP Method" property to POST for your PaymentPortalReturn method.

hi sir Kilian Hekhuis

it was set to post already.

sorry, it should be on the pix above but didnt upload correctly




Solution

Hi Sherwin,

If it is already set to POST, and Postman gives that error, and in Service Center there's no logging, the only thing I can conclude is that you use a wrong URL.

Solution

Kilian Hekhuis wrote:

Hi Sherwin,

If it is already set to POST, and Postman gives that error, and in Service Center there's no logging, the only thing I can conclude is that you use a wrong URL.

Hi Sir Killian,

The error has been resolve, the postback URL is incorrect. we request to update the postback url to dragonpay.

I've miss the "/PaymentPortalReturn" method when calling the postback by dragonpay

Before

After Postback URL Update

Thank you very much.

Regards,

Sherwin

Hi Sherwin,

Good to hear you found the problem, and thanks for the update.