1.0.20 • Published 8 months ago

scash-nodejs v1.0.20

Weekly downloads
-
License
MIT
Repository
-
Last release
8 months ago

Scash-nodejs

Scash-nodejs is a js-based library allowing you to integrate more easily our payment integrator

Installation

Use the package manager pip to install scash-nodejs.

npm i scash-nodejs

Use the package manager yarn to install scash-nodejs.

yarn add scash-nodejs

Usage

import { openScashWidget, addScashListener, closeWidget } from 'scash-nodejs';

# open payment iframe
openScashWidget({
    amount: 50,
    reference: 'ref-scash-00033',
    publicKey: 'SCASH-......',
    phoneNumber: '0777865857',
    errorUrl: "https://www.s-cash.co",
    successUrl: "https://www.s-cash.co"
})

# listen payment response 
addScashListener()
    .subscribe(
        (data: any) => {
            console.log('payment response :::> ', data)
    }
)

# close widget
closeWidget()

Payment Status

  • PENDING
  • FAILURE
  • SUCCESSFUL
1.0.20

8 months ago

1.0.19

8 months ago

1.0.18

8 months ago

1.0.17

8 months ago

1.0.16

8 months ago

1.0.15

8 months ago

1.0.14

8 months ago

1.0.13

8 months ago

1.0.11

8 months ago

1.0.1

8 months ago

1.0.0

8 months ago