safaricom/LNMOnlineAndroidSample

No response received at callback url endpoint

Closed this issue · 18 comments

Aleqi commented

Hi, everything is working perfectly well with the api on the android side but the callback endpoint at the server is not receiving any response. Please help

@Aleqi any luck with this? I having the same problem

@Aleqi @nellycheboi12 You need to define your own callback URL inorder to receive the callbacks. Use this tutorial on how you can use firebase and PHP for that https://www.androidhive.info/2012/10/android-push-notifications-using-google-cloud-messaging-gcm

Aleqi commented
Aleqi commented

@nellycheboi12 No luck yet

Aleqi commented

@Aleqi I have the same issue, which kind a bug was it, cant get responses on my callback url. Like the c2b urls, are we suppose to register this STK callback url?

I came to notice that there are some servers that have a problem with this and after several times of retrying Mpesa drop the response

I think thats the reason for my case, I will try changing server

hello @Aleqi

what kind of bug you were getting at api side ? I am implementing Lipa Na Mpesa STK push and I am not getting response at my callback url after transaction .

please help

it's strange. I simply cannot get any response from Safaricom through the callbackurl despite all systems working fine previously. What kind of a bug is this @Aleqi? Hey @nellycheboi did you resolve yours?

Any luck @itsKirk ?

yeah @em-manuel it turned out to be a bug and it was only on sandbox environment. After two days I got a response from Daraja API guys and confirmed the same but all is well now.

This issue is still there. Sometimes it works, most of the time the endpoint doesn't get the response from Safaricom. Frustrating really.

@angwandi,
I have resolved to going straight to production environment to avoid the massive time wastage on the sandbox environment.

@angwandi, I have resolved to going straight to production environment to avoid the massive time wastage on the sandbox environment.

This is the best possible solution

@ngangavic @em-manuel I think I will do the same then. Thank you.

But what's the point of offering a sandbox test account that doesn't work?

Still a problem

Well someone can get the result of the test transaction by querying mpesa with the CheckoutRequestID (this is returned in the body of initial sdk ).One can make a post request to https://sandbox.safaricom.co.ke/mpesa/stkpushquery/v1/query.
I found how to query by login->select APIs->click on query button in the M-Pesa Express card.
Hope this helps those in test env but I would suggest one moves to production to avoid the many hustle of dealing with CheckoutRequestIDs