Pesapal.com

Forum

Welcome, Guest
Username
Password:
 

Querying transaction status from pesapal
(1 viewing) (1) Guest
Welcome to the Pesapal integration forum!

This forum discusses everything about Pesapal integration on your web site. Having any problems? This is the right place to post a question and we are sure you will get an answer
  • Page:
  • 1
  • 2

TOPIC: Querying transaction status from pesapal

Querying transaction status from pesapal 12 years, 8 months ago #243

  • Ayobra
  • OFFLINE
  • Fresh Boarder
  • Posts: 2
Hi I have tried using this developer.pesapal.com/media/kunena/attachments/48/Pesapal_Sandbox.zip to query status but it does not return any value..Is it me who is not doing the right thing?..
This is what i did after downloading and unzipping the pesapal_sandbox file;

  • In pesapal-iframe.php I did put the $callback_url to the page i want the user to be redirected to
  • I then changed $consumer_secret and $consumer_key to the values i was given and uploaded the files to my server. When the page redirects no it echo only thank you message,,any help plz

The following link is my redirection page www.kehlhosting.com/redirect.php/?pesapa...erchant_reference=45

Re: Querying transaction status from pesapal 12 years, 7 months ago #264

  • Bergman
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
I realised that the pesapal migrated to a new api uri for developer sandbox, and totally forgoe the support for old forks likes us, the new uri is

demo2.pesapal.com/api/

back from

demo.pesapal.com/api/

But still the problem persists

When i use the old uri, demo.pesapal.com/api/ i get a responseText


Object Moved

This document may be found here


But the new one keeps on redirecting with no end, am assuming Yes this is a problem at the pesapal end

Re: Querying transaction status from pesapal 12 years, 7 months ago #265

  • lazro
  • OFFLINE
  • Administrator
  • Pesapal
  • Posts: 404
Hi Bergman,

We are still using the demo.pesapal.com URL. You need not to change the iframe URL to demo2. Is the application you are working on online? I would like to have a look at the "Object Moved" error you are getting when fetching the pesapal status.

Regards,
Lazaro.
Regards,

Lazaro Ong'ele
Web Developer

Skype: Lazrotep
+254-020-249-5438 ; +254-706-191-729
Dagoretti Lane, Off Naivasha Road.

Facebook: www.facebook.com/pesapal
Twitter: twitter.com/PesaPal
Helpdesk: support.pesapal.com
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.

Re: Querying transaction status from pesapal 12 years, 7 months ago #270

  • Bergman
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Hi, i know this is a late reply, buh hoping to get help soon....i am currently using demo for my test and this is what i have



am getting the above error, when i post a payment, you can try it for yourself and see how it is working from here

Now again when i query for a transaction status, i get the following error


You can also try for yourself and see from here

I am using my merchant secret keys and consumer keys, but am stuck from here, before i was posting transactions to my account and it was working like charm, but now since today, its neither posting nor querying for data from pesapal.

You can download the files am using for my test from here

Please assist me, where possible.

Thank you.

Re: Querying transaction status from pesapal 12 years, 7 months ago #271

  • lazro
  • OFFLINE
  • Administrator
  • Pesapal
  • Posts: 404
Hi Bergman,

Sorry about this. Your system should be Ok, Just did a test on the url you posted and it works fine.
Please confirm this.

Regards,
Lazaro
Regards,

Lazaro Ong'ele
Web Developer

Skype: Lazrotep
+254-020-249-5438 ; +254-706-191-729
Dagoretti Lane, Off Naivasha Road.

Facebook: www.facebook.com/pesapal
Twitter: twitter.com/PesaPal
Helpdesk: support.pesapal.com
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.

Re: Querying transaction status from pesapal 12 years, 7 months ago #272

  • Bergman
  • OFFLINE
  • Fresh Boarder
  • Posts: 4
Hi Lazro,

yeah the posting works now thnx alot, but still need help when querying for the transactions, it doesnt work for me. You can download the files and test.

I still get that Object moved error.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1801

  • evan
  • OFFLINE
  • Fresh Boarder
  • Posts: 7
Hi lazro,

We are currently expereincing this problem while doing the tests. It was initially working ok up until 2 weeks ago.
Below is a sample code that's returned when you one pays

"""
HTTP/1.1 302 Found\r\n
Cache-Control: private\r\n
Content-Type: text/html; charset=utf-8\r\n
Location: demo.pesapal.com/api/querypaymentstatus?...%2B&oauth_nonce={DC73E20E-C2E1-AC22-740E-907DF2F36F64}&oauth_signature=EgMHJXpulKLiQsnvchjJr1rvTRY%3D&oauth_signature_method=HMAC-SHA1&oauth_timestamp=1456929400&oauth_version=1.0&pesapal_merchant_reference=OMdmByxyfwjBOhDZIUbw25d4xW5KlVw5mL8X0X0pxrMfYGbwuWThmN05Ju8Y8oRd&pesapal_transaction_tracking_id=edc4f025-6d5e-4790-a249-b36fb318da73\r\n
Server: Microsoft-IIS/8.5\r\n
Set-Cookie: ASP.NET_SessionId=zeiwauflsisqbbyb1abgnml3; path=/; HttpOnly\r\n
X-AspNetMvc-Version: 5.0\r\n
X-AspNet-Version: 4.0.30319\r\n
Date: Wed, 02 Mar 2016 14:36:40 GMT\r\n
Content-Length: 587\r\n
\r\n
<html><head>Object moved</head><body>\r\n
<h2>Object moved to <a href="demo.pesapal.com/api/querypaymentstatus?...amp;amp;oauth_nonce={DC73E20E-C2E1-AC22-740E-907DF2F36F64}&amp;oauth_signature=EgMHJXpulKLiQsnvchjJr1rvTRY%3D&amp;oauth_signature_method=HMAC-SHA1&amp;oauth_timestamp=1456929400&amp;oauth_version=1.0&amp;pesapal_merchant_reference=OMdmByxyfwjBOhDZIUbw25d4xW5KlVw5mL8X0X0pxrMfYGbwuWThmN05Ju8Y8oRd&amp;pesapal_transaction_tracking_id=edc4f025-6d5e-4790-a249-b36fb318da73">here</a>.</h2>\r\n
</body></html>\r\n
"""
 

Re: Querying transaction status from pesapal 9 years, 7 months ago #1802

  • lazro
  • OFFLINE
  • Administrator
  • Pesapal
  • Posts: 404
Hi Evan,

Have you made the changes on HTTPS as suggested here: developer.pesapal.com/forum/6-announceme...-sandbox-application
Regards,

Lazaro Ong'ele
Web Developer

Skype: Lazrotep
+254-020-249-5438 ; +254-706-191-729
Dagoretti Lane, Off Naivasha Road.

Facebook: www.facebook.com/pesapal
Twitter: twitter.com/PesaPal
Helpdesk: support.pesapal.com
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1822

Hi. I am new to pesapal and have just finished integration with the php files on the site, but I have one question, how do I use the IPN-listener and the callback url. PS:Everything else is working fine.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1823

Hi alfy,

Check out this link which has a step by step tutorial on how to implement IPN.

developer.pesapal.com/how-to-integrate/ipn

Re: Querying transaction status from pesapal 9 years, 7 months ago #1824

Hi Odhiambo...I have read and re-read that page like 4 times. I still dont get it. Haha maybe im that slow.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1825

Where are you having issues?

Re: Querying transaction status from pesapal 9 years, 7 months ago #1826

I dont usnderstand what the call back url and IPN listener are for. Well I understand that I can use the listener to query results or changes in my transactions but I cant figure out what to do exactly.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1827

  • lazro
  • OFFLINE
  • Administrator
  • Pesapal
  • Posts: 404
Greetings alfy,

- The callback URL is the page PesaPal will redirect a user to after they make the payment.
- The IPN (Instant Payment Notification) URL is the URL PesaPal will execute whenever there is a status change. It alerts you that the status of transaction X has changed for you to take the appropriate action.

Whenever PesaPal executes the Callback and IPN URLs, it appends the merchant reference (unique ID which originates from your system) transaction ID (unique ID on PesaPal). Using these two values (or the merchant reference only) you then query the status of the payment. We do not append the status on the URL for security reason hence you have to securely query the status using the various APIs provided.

In addition to the above, when the IPN is executed, an additional parameter is appended. This is the notification type. In this case, the value will the CHANGED. Signifying that the IPN was executed by a status change call.

Why is IPN important? Take an example where by a user made a payment using mobile money. By the time the user is redirected to the callback URL, your status query may return a PENDING state (possibly because PesaPal is yet to receive the status of that payment for the 3rd party payment service). This such an instance, the client may decide to log off your system. How will you then get to know the final status of the payment? This is where IPN is important. Immediately a confirmation from the 3rd party payment provider is received, PesaPal will executed the IPN link you provided alerting you of a status changed hence prompting you to query the actual status and taking further actions.

Please refer to the following documentations and examples. In particular, study the PHP example given:
Regards,

Lazaro Ong'ele
Web Developer

Skype: Lazrotep
+254-020-249-5438 ; +254-706-191-729
Dagoretti Lane, Off Naivasha Road.

Facebook: www.facebook.com/pesapal
Twitter: twitter.com/PesaPal
Helpdesk: support.pesapal.com
This e-mail address is being protected from spambots. You need JavaScript enabled to view it.
Last Edit: 9 years, 7 months ago by lazro.

Re: Querying transaction status from pesapal 9 years, 7 months ago #1828

Okay Lazro thanks. If I have any more questions, I will ask them in this thread.
  • Page:
  • 1
  • 2