nummus-pay-react v1.0.2
React Nummus Pay Checkout Component
Nummuspay is a Payment Service Provider https://nummuspay.com/ and the reason you should deploy them as a PSP is quite simply because they are a very good ALT to Stripe and friendly.
Henry Davison - Lead DEV @vshop.vadoo.co.uk
nummus-pay-react is at https://bitbucket.org/houseofdavison/nummuspayreact
An example of integration can be seen at vShop or see this in ReactJS
Status
Version 1.0.3 Beta
Installation
Get started by installing with npm
npm install nummus-pay-react
Code
import React from 'react'
import NummusPay from 'nummus-pay-react';
// BASIC usage
<NummusPay
publicID="100"
amount="99.99"
/>
// with COMMON OPTIONS
<NummusPay
publicID="100"
amount="99.99"
currency="GBP"
firstName="John"
lastName="Smith"
billingZIP="SW1A 1AA"
/>
// FUTURE OPTIONS
<NummusPay
...
onSuccess={this.onPayment.bind(this)}
onCancel={this.onCancelled.bind(this)}
/>
Basic Options
| publicID | your Client ID required |
| amount | to pay required as this is a Checkout only UI|
| currency | e.g. GBP, USD etc. optional |
Future Options
Within your payment-module, i.e. where you load <NummusPay / > you should have two functions with suggested names onPayment and onCancelled (up to you to marry with whatever names you use in <NummusPay / > as props):
onPayment (_data) {
/* Do Somthing */
console.log( _data );
}
onCancelled (_data) {
/* Do Something */
}
Most likely these will call your APIs to do whatever is required when a payment is received or cancelled.