This page introduces the Callback function, a powerful feature that allows you to receive automatic transaction status updates from Netaxept, helping to ensure that payments are processed accurately and efficiently.
Definition and use cases
Sometimes, crucial payment information does not reach all parties involved, or it remains unclear. This can occur due to issues like communication interruptions during the payment process or customers closing their web browsers prematurely.
In many cases, customers receive payment confirmation, but the same information does not reach you as the merchant. Consequently, customers may not receive their ordered products, despite the payment being deducted from their accounts.
To avoid these scenarios, we strongly recommend implementing the Callback function, especially if you have already implemented direct bank payments.
Efficient payment verification with callback
The Callback serves as an alternative to the Query call polling method for transaction status verification. When implemented, Netaxept automatically queries the respective payment method service provider for status updates.
As the transaction status changes to authorized, captured, credited, or annulled, Netaxept sends this information to the Callback URL that you designated. Netaxept will continue querying the status until it reaches the merchant-defined timeout value. Furthermore, Netaxept will also perform one last try 24 hours after the timeout. If the transaction status remains unchanged within this timeframe, Netaxept considers the transaction abandoned or completed, ceasing further status checks.
Benefits of using Callbacks
Callbacks help you ensure that payments are processed reliably - Even if there are network or other temporary problems, Netaxept will keep sending the callback events until you acknowledge them with a "200 HTTP" status code.
Callbacks save time and resources - Instead of having to constantly check with Netaxept for transaction status updates, callbacks send you updates automatically.
Callbacks help you track all payment events, even if your customer leaves your site - This is especially helpful for payment methods like direct banks and mobile wallets, which may not guarantee that the customer will return to your checkout page after completing the payment.
Implementation of the Callback
To be able to use the Callback, you need to set the Callback URL and timeout value in the Netaxept Admin Options tab. The Callback URL must start with "https" and we recommend using a signed SSL certificate during the communication. If your Callback URL is protected by a username and password, these need to be added to the Options tab as well. Read more about the Callback settings in Netaxept Admin Portal guide.
Handling Callback messages from Netaxept
Your server must reply to the Netaxept Callback message with HTTP 200, otherwise Netaxept will retry to send the same Callback message numerous times to the merchant-defined Callback URL.
The Callback message sent by Netaxept will only include a unique transaction ID for that particular transaction, as a JSON format in the request body. Based on this, you need to send the Query call to Netaxept to find out the new status and to be able to get more detailed information about the transaction.
For further information, take a lok at the Query call page.
Example of a Callback URL sent by Netaxept
If you need to open your firewall for the Callback messages from Netaxept, the following are the applicable outgoing IP addresses:
- Production: 184.108.40.206/28
- Test: 220.127.116.11, 18.104.22.168, 22.214.171.124/30