This GIST will help you implement PayPal v2 API with your Django app and handle payment statuses. I will use: Class-Based FormView and Django template system. To proceed you have to obtain valid PAYPAL_CLIENT_ID, PAYPAL_CLIENT_SECRET /have PayPal business account - production or sandbox/
Steps to complete:
-
Get PayPal SDK - pip install paypal-checkout-serversdk
-
Create a FormView with the payment data - amount, currency, description and cliend_id