Hi all,
I am implementing accept hosted via php. I have followed https://developer.authorize.net/api/reference/features/accept_hosted.html and successfully getting payment form. I am using redirect method for getting form. As per the reference guide i can get response on provided response url but have no idea how to do that.
Since the response is POST type and in order to use the response i must know its variable name. So what is its variable name???
Please help.
โ05-18-2017 03:55 AM
If the showReceipt parameter is true, system will display a receipt page after the transaction, with a "Continue" button that points back to the url provided in the url parameter.
Else if the value of the showReceipt parameter is false, the browser will return directly to the return URL.
When showReceipt is false, a return URL must be provided in the url parameter. Otherwise the receipt page will be shown.
โ05-18-2017 08:08 AM - edited โ05-18-2017 08:09 AM
In both cases, when showReceipt is set to true or false, i am getting default receipt page https://test.authorize.net/payment/payment with continue button redirecting to the url i have specified in hostedPaymentReturnOptions.
However this is not the problem for me. In https://developer.authorize.net/api/reference/features/accept_hosted.html it is mentioned that
---------------------------------------------------
"With any of the form integration methods, information specific to the customer can be passed back to the merchantโs server by embedding it in the continue/return URL or the cancel URL. By embedding information into the URL that is provided in the token request, the merchant server can identify the specific customer and transaction that has been processed when the customer returns. Any name-value pairs embedded in the URL should be URL-encoded to ensure correct processing in the form request."
------------------
I need to know how i can embedd the response in continue/return url???
Although i was digging into the problem and found out an alternate. When i specify an url in SILENT POST URL section of authorize.net account section. i get the response on that url after every transaction.
I want that response on the continue url. How can i get that? Advance thanks for any help.
โ05-19-2017 12:23 AM
When not using an IFrame, the continue/return URL and cancel URL create buttons that when clicked cause the browser to perform a simple GET request to that URL. No other information about the transaction is provided directly. When using the redirect method, an Authorize.Net generated receipt will be shown and cannot be disabled.
Instead of the Silent Post method, you should use Webhooks, which will enable you to enroll in the events of your choice and designate a URL to receive the notifications as they occur.
โ05-19-2017 01:10 AM - edited โ05-19-2017 01:12 AM
Is Webhooks the only way i can get transaction response when using redirect method???
โ05-19-2017 03:35 AM
It's not the only way, but it is the best way.
โ05-19-2017 09:28 AM
Here is the working source code: https://github.com/mvkotekar/Authorize.Net-Hosted.git
I also have similar issue, I have used the webhooks sample code to listen to the transactions. However webhook project runs on different port like 9000. HOw do I ensure I get the response in my application itself rather than seperate listening port ?
โ11-30-2018 11:24 PM
โ12-01-2018 01:53 PM
Thanks for your response. All am trying to do is, use the webhook notifications inside my asp.net application. However, the examples mentioned in authroize.net, It had to run with nodejs on other port like 9000.
In your php application, do you have both authorize.net payment logic and also subscribed to all transaction events ? if Yes, am trying to achieve the same thing in C#/ASP.net.
Any help from C#/ASP.net please ?
โ12-02-2018 08:54 AM
โ12-02-2018 07:21 PM