This package, pi-sdk-django, helps you quickly scaffold, configure, and integrate all
necessary components for using Pi Network payments, authentication,
and user flows with a Next.js project. It is designed for modern
Django apps that want a working,
idiomatic Pi payment and authentication experience with minimal
boilerplate.
The pi-sdk-django
package
is part of the “Ten Minutes to Transactions” effort described in this
video.
If you are planning to use the Django framework for your app, it is highly suggested that you use this package rather than implement transaction processing by hand with the core Pi SDK. The three way handshake between client, server, and the Pi servers required is provded for you.
While this process is covered in the Getting Started Guide, here is a brief reminder of the steps you need to take. Application registration is also discussed in the video.
http://localhost:3000. The actual port is between you and your development server.pi-sdk-django as a dependency in your Django projectpip install pi-sdk-djangopi-sdk-django-installThis will generate:
routes/pi_payment/ directory with individual route handlersroutes/pi_payment/index.ts - Router that exports all routesapp.example.ts - Example Django app setup