Skip to content

Commit ef363eb

Browse files
committed
updated readme
1 parent f02d7ec commit ef363eb

File tree

1 file changed

+52
-2
lines changed

1 file changed

+52
-2
lines changed

README.md

Lines changed: 52 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,52 @@
1-
# paystack-transaction-charges-to-cus-js
2-
Pass Paystack Transaction Charges To Customers JS Library
1+
# PASS PAYSTACK TRANSACTION CHARGE TO CUSTOMER
2+
3+
PaystackTransactionChargeToCustomer provides the implementation to the formula provided by the Paystack support team as regards passing the Paystack transaction charge to customers [Here's the article](https://support.paystack.com/hc/en-us/articles/360009973579-Can-I-pass-the-transaction-charges-to-my-customers-) .
4+
5+
## Before getting started
6+
This library currently only works with the Nigerian Paystack Charges
7+
8+
**Flat Fee - 100 Naira**
9+
|
10+
**Decimal Fee - 1.5%**
11+
12+
### Get Started
13+
This library would help you calculate the total amount to charge the customer including the Paystack charges. All you need to do is ...
14+
15+
[![Version](https://img.shields.io/npm/v/paystack-transaction-charges-to-cus.svg)](https://www.npmjs.com/package/paystack-transaction-charges-to-cus)
16+
[![Downloads](https://img.shields.io/npm/dm/paystack-transaction-charges-to-cus.svg)](https://www.npmjs.com/package/mathjs)
17+
[![Build Status](https://github.com/josdejong/mathjs/workflows/Node.js%20CI/badge.svg)](https://github.com/josdejong/mathjs/actions)
18+
[![Maintenance](https://img.shields.io/maintenance/yes/2021.svg)](https://github.com/josdejong/mathjs/graphs/commit-activity)
19+
20+
21+
## Usage
22+
23+
paystack-transaction-charges-to-cus.js can be used in both node.js and in the browser.
24+
25+
Install paystack-transaction-charges-to-cus.js using [npm](https://www.npmjs.com/package/paystack-transaction-charges-to-cus):
26+
27+
npm install paystack-transaction-charges-to-cus
28+
29+
30+
31+
```js
32+
import {
33+
calculateTotalPrice
34+
} from 'paystack-transaction-charges-to-cus'
35+
36+
// functions and constants
37+
calculateTotalPrice(100) // 101
38+
39+
```
40+
41+
42+
#### Constants
43+
44+
|Name | Type | Required | Default Value | Description |
45+
|-----------------------|----------------|---------------------|---------------------|---------------------|
46+
| `DECIMAL_FEE ` | `Double` | true | 0.0150 |
47+
| `FEE_CAP ` | `int` | true | 2000 |
48+
| `FLAT_FEE` | `int` | true | 100 |
49+
50+
51+
## Done
52+
Checkout Paystack [API](https://paystack.com/docs/)

0 commit comments

Comments
 (0)