IPN Testing and Troubleshooting

After you implement your listener and start it running on your web server, you can use the IPN Simulator in Test Tools to send IPN messages to the URL at which your listener is running. This tool allows you to verify that you are receiving IPN messages correctly.

Testing Your Listener

The first level of testing is to ensure that your IPN listener receives messages and handles them appropriately. This level of testing requires you to have your IPN listener running at your notification URL; however, it does not require you to set up the listener in the Wallet Settings.

You must be logged in to the OKPAY to use the IPN Simulator. To set up and send an IPN message using the simulator:

  1. Log in and click on Profile under My Account.
  2. Click the Test Tools link under Merchant preferences.
  3. On the Test Tools page click on the IPN Simulator link.
  4. Select wallet from the drop-down list, then enter the URL to receive the notification and the kind of notification you want to test on the following screen:

    Figure 1. Selecting an IPN kind.

    IPN Simulator

    When you select the kind of transaction that you want to test and click Next, a form containing test data appears:

    Figure 2. Filling in the IPN details.

    IPN Sumulator Form

  5. Keep or modify the values of fields that you want to include in the IPN.

    Important: The simulator does not check the validity of the fields that you change.

  6. Click Send Test IPN.

    The IPN message is sent to the specified URL and the results of the operation are displayed at the top of the page.

If your IPN listener receives a message, you know that it is properly installed on your web server. The default messages sent by the IPN simulator are valid, thus, if your listener responds correctly to the message, it should receive a TEST message (for real messages you will receive VERIFIED). If you do not receive any message or if you receive an INVALID message after responding to the original message from OKPAY, you will need to troubleshoot your listener.

IPN Troubleshooting Tips

IPN failures fall into three categories: not receiving any IPN messages from OKPAY, receiving some but not all IPN messages, and receiving INVALID messages from OKPAY after responding to a message.

If you do not receive any IPN messages from OKPAY

  • Check the IPN Messaging History page on OKPAY. It tells you whether OKPAY sent the IPN message and whether your listener responded to it. It may also provide information about the status of the server on which your listener is running. If necessary, from this page you can also request OKPAY to resend the IPN message.
  • Check that the path to your IPN listener is correct and you are using that path correctly in your IPN notification URL. For example, the file path is often similar to, but not the same as, the URL.
  • Verify that your firewall settings are not blocking HTTP POST messages from OKPAY.
  • If the logs for your web server are available, check them to confirm that messages are being sent to your web server and check for any errors that may have occurred.

If you receive some messages but not others

  • Verify that your IPN listener is responding to all messages, even those you do not intend to process.

If you receive an INVALID message

  • Check that you are posting your response to the correct URL, which is "https://www.okpay.com/ipn-verify.html".
  • Verify that your response contains exactly the same IPN variables and values in the same order, preceded by "ok_verify=true".
  • Ensure that you are encoding your response string and using the same character encoding as the original message.

Note: If you receive multiple IPN messages for the same transaction or if messages appear to be out of order, this is not necessarily an indication that your listener is malfunctioning. For example, if you do not respond in time, OKPAY resends the message. You should investigate these situations because they could be caused by logic errors or performance problems as well.

OKPAY RSS
OKPAY Forum
OKPAY on Facebook
OKPAY on Livejournal
OKPAY on Twitter
OKPAY on VK
OKPAY on Linkedin
OKPAY on Youtube