Skip to content
Home » Blog » Paynow Integration Troubleshoot Guide

Paynow Integration Troubleshoot Guide

Unless you are of the lucky ones YOU WILL NOT GET YOUR INTEGRATION UP AND RUNNING AT FIRST ATTEMPT. There many errors you will encounter along the way. Here are some of the common ones and how to fix them.

Integration ID is in test mode Error

Markdown
"The integration ID specified is currently in test mode. The authemail used must belong to the company in control of the integration ID."

So how do we fix this

You have to do the following steps

  1. Make a test transaction.
  2. Request to be set live.
  3. Wait for Paynow response.
  4. Start accepting live payments.

1. Make a test transaction.

Paynow has test numbers which you can use to make fake transactions:

Success – 0771111111

Paynow will send a SUCCESS status update message 5 seconds after the transaction is initiated.

Delayed Success – 0772222222

Paynow will send a SUCCESS status update message 30 seconds after the transaction is initiated. This simulates the user taking a longer than normal amount of time to authorize the transaction from their handset

User Cancelled – 0773333333

Paynow will send a FAILED status update message 30 seconds after the transaction is initiated. This simulates the user cancelling the mobile money transaction.

Insufficient Balance – 0774444444

Paynow will immediately fail the transaction during initiation and return an “Insufficient balance” error message.

For number use one of the number mentioned above e.g 0771111111

For authemail use the email that you used to register for Paynow e.g joshua@example.com

Now make a test transaction

For PHP users:

PHP
$payment = $paynow->createPayment('Order #123', 'joshua@example.com');
...
...
...

$response = $paynow->sendMobile($payment, "0771111111", "ecocash");

For Python generals:

Python
payment = paynow.create_payment('Order #123', 'joshua@example.com')
...
...
...
response = paynow.send_mobile(payment, '0771111111', 'ecocash')

You will get this message in your email:

Markdown
Paynow Reference: XXXXXXXX
Status: Paid (TESTING: Faked Success)
Customer Email: joshua@example.com
Customer Name: Test Customer
Customer Phone: 263772222222
Amount: $200.00
Reference: Order #123

Once you have done this then you can request it to be set live

2. Request to be set live

  • Log in to Paynow (paynow.co.zw)
  • Go to Recieve Payments
  • Click Other Ways To Get Paid
  • Scroll down an click Create/Manage Shopping Carts
  • Scroll down again and click Advanced Integration(If you don’t have an integration) or click a Pencil icon on your right.
Select your integration
  • Now scroll down and click Request to be Set Live
Request to be Set Live

3. Wait for Paynow response.

Now you wait

You waiting for response

The time it takes to get your response is not personal 😂😂😂 and it should not take more than 3 days.

If it comes you will get “You integration has been set to live” message or something within these lines or some error message,. Basically error message come because you have skipped something.

4. Start accepting live payments.

Once live I love to test it again with small amounts just to make sure, You can test it on different platforms so you can get the feel of it.

Ok until we meet next time…

Image Credits: SecurionPay

Hash Mismatch Error

This is one of the most nastiest errors you will get when trying to create a Paynow payment.

It will throw something like this:

Bash
An error occured while initiating transaction Error: Hashes do not match!
     at Paynow.Paynow.parse (/home/takunda/Development/Personal/papapi/node_modules/paynow/src/paynow.ts:229:15)     
     at <anonymous> (/home/takunda/Development/Personal/papapi/node_modules/paynow/src/paynow.ts:193:19)
     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
     at Paynow.create (/home/takunda/Development/Personal/papapi/src/classes/paynow.ts:83:24)
     at createPayment (/home/takunda/Development/Personal/papapi/src/apis/paynow.ts:9:20)
     at <anonymous> (/home/takunda/Development/Personal/papapi/.wasp/out/sdk/wasp/server/utils.ts:26:5)

It doesn’t tell you exactly why the error is happening and it doesn’t give you any suggestions. Here is the other sweet thing: The Paynow team is very slow to respond and in some case they don’t respond.


Anyways here is how to fix

Fix #1: Specify Result URL and Return URL

When creating your Paynow object make sure result and return URL are specified

Fix #2: Authemail problem

If you are in testing make sure that the email you used to create your merchant account is the same with the email you are using to make the payment object

PHP
$payment = $paynow->createPayment('Order #123', 'joshua@example.com');
JavaScript
const payment = $paynow.createPayment('Order #123', 'joshua@example.com');
Python
payment = paynow.create_payment('Order #123', 'joshua@example.com');

Here your Paynow account email should also be………joshua@example.com