What is the Return Response?



The return URL is the URL that ClickPay will redirect the customer to after he finishes with the payment process (whether it's authenticated or not). It will redirect the customer with a POST response that is sent with the client/cardholder redirection through his browser containing the basic transaction information once the payment process came to an end (whether the customer cancels, paid, or failed to pay). It depends on the customer's actions, which means if the customer closes the browser right after the payment without waiting to be redirected back to your system you will not receive this response.


What is the Callback Response?



The callback response is a server-to-server POST response that is sent (to a pre-defined HTTPS URL) with the full detailed transaction information once the payment process came to an end (whether the customer cancels, paid, or failed to pay). It doesn't depend on the customer's actions, the response will be sent anyway.



The differences between the "return" vs "callback"

Both are parameters that passed during the request payload as shown below




Return URL
Callback URL
Both URLs are optional to add to your request payload. 
Since it's a browser redirection it can be on localhost, both private and public addresses will work
Must be URLs must be public and reachable
Should be HTTPS otherwise, no data will be returned.
Should be HTTPS otherwise, no data will be returned.
This is a browser redirection request.
This is a Server-to-Server request. The client's browser is not involved.
The returned value will be in the form-data format (key=value&), click here for a sample payload.
The returned value will be in JSON format, click here for a sample payload.
Port Numbers are allowed in the URL.
Port Numbers are NOT allowed in the URL.


Receiving an empty response or no response at all in one/both of them? Kindly check our "(E): Recieve a blank response (or no response at all) via return/callback URLs" solution article to troubleshoot the issue.



It's a common case that sometimes customers may just close the payment page after the transaction is done and before being redirected back to your system. Which in this case, your system will not be aware of the succeeded transaction.

So we highly recommend using/depend on the callback response to update the order status on your system, and pass the return URL only for the user interface redirections.


For more information about "callback" and "return" URLs and what are the different transaction responses, kindly check our "What are the Five (5) ways of receiving transaction response? " solution article.