For Open edX payment integration, this structure is partially correct, but it looks a bit mixed between Tutor plugin files, ecommerce Django app, and templates.
A few suggestions:
tutorrazorpay/ should only contain Tutor plugin logic (plugin.py, settings, hooks). The actual payment processor code usually shouldn’t live there.
The Razorpay payment processor should ideally be a proper Django app under ecommerce* , similar to existing processors:
ecommerce/extensions/payment/processors/razorpay/
with apps.py, processor.py, urls.py, and views.py.
The build/ directory generally shouldn’t be committed or manually structured like this—it’s normally generated during packaging.
Templates can be simplified and placed under:
templates/ecommerce/razorpay/
so Django’s template loader can find them cleanly.
If you follow the structure of existing ecommerce payment processors (like PayPal or CyberSource), it becomes much easier to register Razorpay in PAYMENT_PROCESSORS and wire it into ecommerce correctly.
Hope this helps — happy to clarify further if needed.