0
I’m trying to integrate Pagseguro with this lib:
https://github.com/rochacbruno/python-pagseguro
But, I can’t access the notification data that Pagseguro sends me. I’m using the following code:
notification_code = request.POST['notificationCode']
pg = PagSeguro(email="[email protected]", token="token")
notification_data = pg.check_notification(notification_code)
print notification_data['status']
On the last line I get the bug:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'PagSeguroNotificationResponse' object has no attribute '__getitem__'