Response error after integration


#1

and after doing the integration we are getting this error

this is code
function pay()
{
$paynow = new Paynow(
INTEGRATION_ID,
INTEGRATION_KEY,
BASEURI,
// The return url can be set at later stages. You might want to do this if you want to pass data to the return url (like the reference of the transaction)
BASEURI
);
$payment = $paynow->createPayment(‘Invoice 35’, ‘pkarn@live.in’);
$payment->add(‘Test’, 1);
$response = $paynow->sendMobile($payment, ‘0263772336987’, ‘ecocash’);
$this->save_json_file($response);
if($response->success()) {
// Get the poll url (used to check the status of a transaction). You might want to save this in your DB
$pollUrl = $response->pollUrl();

        // Get the instructions
        $instrutions = $response->instructions();
    }
}

and this is response
{“success”:false,“status”:“error”}


#2

Advice on how to go about this error


#3

Try this first: Kindy remove 0263 and only pass 07772336987

Hi for a comprehensive error kindly print $response->data; you should be able to see full error message


#4

Is this the live environment or you are still testing in dev? if youre testing you need to get the approved phone numbers to test with. Also remove the 0263 and replace it with just a single 0 (zero).