@mvault/pay
v1.1.67
Published
MVault pay module
Downloads
32
Readme
Mvault Pay
Mvault pay offer you an easiest way to manage your payment by using two ways charge and transaction bellow you should learn more about it
API Reference
NOTICE
By using charge you can create only a charge Otherwise if you use Transaction you can create one or multiple charges
1. Charge use cases
Create Charge
charge.create({amount, order, merchant, transaction, method, card, role, app, company}) <Promise>
| Parameter | Type | Description |
| :-------- | :------- | :------------------------- |
| amount
| integer
| Required. amount in cents|
| method
|string
| Required. ["card","card-present","cash"]|
| app
| string
| Required.|
| transaction
| string
| Required only use for multiple payments|
| role
| string
| Required only if role different than merchant and terminal|
| others
| ------
|Optional|
Refund
charge.refund({charge, amount, role, company}) <Promise>
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| amount
| integer
| Required. amount in cents|
| role
| string
| Required only if role different than merchant and terminal|
GET
charge.get({from, to, limit, offset, merchant, method, status, role, company, transaction}) <Promise>
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| limit
| integer
|Required|
| others
| ------
|Optional|
Charge
charge.charges()
Return charges
2. Transaction use cases
Create
transaction.create({total,merchant,order,company,role}) <Promise>
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| total
| integer
|Required|
| role
| string
|Required|
| others
| ------
|Optional|
GET
transaction.get({from, to, limit, offset, merchant, status, role, company}) <Promise>
| Parameter | Type | Description |
| :-------- | :------- | :-------------------------------- |
| limit
| integer
|Required|
| others
| ------
|Optional|
Transaction
transaction.transactions()
Return transactions