vikas-tuteja / paymentgatewayintegration Goto Github PK
View Code? Open in Web Editor NEWPackage to Integrate payumoney payment gateway with your django app
Package to Integrate payumoney payment gateway with your django app
Project: Payment Gateway Integration (Tested only for payUMoney) Author: Vikas Tuteja Date: 11 Nov, 2017 PREREQUISITES * django 1.6 or above * drf 3.6.1 or above INSTALLING * copy the paymentgateway folder in your Base directory * include paymentgateway in your installed apps settings * activate your virtualenv * ./paymentgateway/setup OVERVIEW * This package is used to integrate the payment gateway with your django application. * P.S: It supports payUMoney as of now, can be evolved to work with other payment gateways. * MODELS 1. Configuration - Contains the payment gateway service provider's basic configuration- merchant name, key, success & failure urls, etc 2. Transaction Request - All the transaction requests sent to the payment gateway are stored here. 3. Transaction Response - All the transaction response received from the payment gateway must be saved in this model. * API's 1. Url: /paymentgateway/transactionrequest/add/?format=json method: POST Usage: This API should be called before a user is redirected to the payUMoney website. It will create a transaction request object, along with the required hash key and unique txn id. A list of form inputs needs to be sent to this API as well as the payment gateway in order to initate the transaction. refer sample input form template - paymentgateway/templates/sampleinputform.html 2. Url: /paymentgateway/transactionresponse/<status>/ - where status can be success/failure method: GET Usage: This is a callback API used by payUmoney to redirect the user back to our website after the payment process. It saves an object of the response sent by payUMoney against its OneToOne mapping of the unique transaction id. sample response url: http://your_website.com/paymentgateway/transactionresponse/success/?txnid=b9404169e3bf33c46f509596cdc152&status=Completed& payuMoneyId=asd&hash=b12ddb717e03bcec420b23395396b0d00ab709eb568757d29a832d24414e0373a7c8ecd76b922953b8764fd4fe0529289ce2e0362eba8292033d4s& mode=CC&firstname=Vikas&amount=100.00&phone=9146166344&[email protected]&productinfo=xyz&payuMoneyId=123qwe&format=json sample response template - paymentgateway/templates/pay_response.html P.S: both API's return a json response ADDITIONAL FEATURE * You may map each transaction request to payU with any entity of your application, by simply passing the following 2 params to the transaction add API:- content_type - which is an id of your model and object id - which is the id of the object to which a transaction needs to be mapped.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.