Skip to content
PagSeguro integration for django-oscar e-commerce
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.


Pagseguro package for django-oscar

This package provides integration between django-oscar and Pagseguro

It's only on early development

It depends on django_pagseguro2 library

It works by adding the Pagseguro API call to the handle_successful_order method, so it finalizes the order before redirecting the user to Pagseguro because it needs to use the order number as reference for the order.

Pagseguro assumes that the order is completed when it's called, which is different from django-oscar, where it's possible to use the success of the payment as a confirmation for order placement.

The payment status are sent afterwards and dealt with using a view provided by django_pagseguro2 library, the signals are then used for order status changing in


  • Add the pagseguro package to the INSTALLED_APPS:

  • Add the following url to the of the django-oscar project:

    url(r'^', include('oscar_pagseguro.urls')),
  • And have a oscar order status pipeline that matches Pagseguro one:

        'Aguardando pagamento': ('Paga', u'Em analíse', 'Cancelada'),
        u'Em analíse': ('Paga', 'Cancelada'),
        'Paga': ('Em disputa', 'Devolvida', u'Disponível', 'Cancelada'),
        u'Disponível': ('Devolvida', 'Em disputa'),
        'Em disputa': (u'Disponível', 'Devolvida', 'Paga'),
        'Devolvida': (),
        'Cancelada': (),
  • Configure Pagseguro with fix redirection page (Página de redirecionamento

fixa) para:

  • Configure Pagseguro with transaction notification (Notificação de transação),

to the following URL:



Drop the status pipeline matching by making the status used by the django_pagseguro2 configurable

You can’t perform that action at this time.