# roqqupay-nodejs

> Library for integrating roqqu apis using nodejs

Latest version **0.0.5** (published 2021-04-22) · ISC license · 0 weekly downloads

## Install

```sh
npm install roqqupay-nodejs
pnpm add roqqupay-nodejs
yarn add roqqupay-nodejs
bun add roqqupay-nodejs
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.5 |
| Published | 2021-04-22 |
| First published | 2021-03-20 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 22.3 KB |
| Known vulnerabilities | 0 (+23 in 1 direct dependencies) |
| Install scripts | no |
| Author | chibuokem |
| Maintainers | roqqu |

## Links

- npm: https://www.npmjs.com/package/roqqupay-nodejs
- Repository: https://github.com/RoqquPay/roqqupay-nodejs
- Homepage: https://github.com/RoqquPay/roqqupay-nodejs#readme
- Issues: https://github.com/RoqquPay/roqqupay-nodejs/issues
- npm.io page: https://npm.io/package/roqqupay-nodejs

## Dependencies (1)

- [axios](https://npm.io/package/axios.md) ^0.21.1

## Recent versions

- 0.0.5 (latest) — 2021-04-22
- 0.0.4 — 2021-03-20
- 0.0.3 — 2021-03-20
- 0.0.2 — 2021-03-20
- 0.0.1 — 2021-03-20

## README

# roqqupay-nodejs
A library for integrating roqqupay apis using nodejs

#installation
You can install the package via npm :
```bash
npm install roqqupay-nodejs
```

#Usage

```javascript
   //Get all token prices
   const RoqquPay = require('roqqupay-nodejs');
   (async function(){
   const RoqquPayClass = new RoqquPay();
   const priceInfo = await RoqquPayClass.prices.getPrices();
   console.log(priceInfo);
 })();
```

```javascript
   //Get a specific token price
   const RoqquPay = require('roqqupay-nodejs');
   (async function(){
       const RoqquPayClass = new RoqquPay();
       //This is the token symbol of the token you intend to retrieve data for
       const token = 'btc';
       const priceInfo = await RoqquPayClass.prices.getPrice(token);
       console.log(priceInfo);
 })();
```

```javascript
   //Get price history
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       const RoqquPayClass = new RoqquPay();
       //This is the token symbol of the token you intend to retrieve data for
      const token = 'btc';
       const priceHistory = await RoqquPayClass.prices.getPriceHistory(token);
       console.log(priceHistory);
 })();
```

```javascript
   //Get wallet data
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       const RoqquPayClass = new RoqquPay();
       //this is the token for the wallet address you want to retrieve data for
        const token = 'btc';
       //this is the wallet address you want to retrieved data for
       const walletAddress = 'wallet address'
      const addressData = await RoqquPayClass.wallet.getWalletData(token, walletAddress);
      console.log(addressData);
 })();
```

```javascript
   //Generate wallet address
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
      //this is the token for the wallet address you want to generate
       const token = 'btc';
       const addressData = await RoqquPayClass.wallet.generateWalletAddress(token);
       console.log(addressData);
 })();
```

```javascript
   //Get wallet addresses
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
      //this is the token for the wallet address you want to generate
       const token = 'btc';
       const walletAddresses = await RoqquPayClass.wallet.getWalletAddresses(token);
       console.log(walletAddresses);
 })();
```

```javascript
   //Get wallet addresses
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
      //this is the token for the wallet address you want to generate
       const token = 'btc';
       const walletAddresses = await RoqquPayClass.wallet.getWalletAddresses(token);
       console.log(walletAddresses);
 })();
```

```javascript
   //delete wallet addresses
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
      //this is the token for the wallet address you want to generate
       const token = 'btc';
       const walletAddress = 'wallet address you want to delete'
       const deleteWalletAddress = await RoqquPayClass.wallet.deleteWalletAddress(token, walletAddress);
       console.log(deleteWalletAddress);
 })();
```

```javascript
   //get data bundles
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       const RoqquPayClass = new RoqquPay();
       const provider = 'mtn';
       const dataBundles = await RoqquPayClass.vtu.getDataBundes(provider);
       console.log(dataBundles);
 })();
```

```javascript
   //recharge airtime
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
      const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
      const RoqquPayClass = new RoqquPay(secretKey);
      const phoneNumber = 'phone number you want to recharge';
      const amount = 'amount you want to recharge'
      const rechargeAirtime = await RoqquPayClass.vtu.rechargeAirtime(phoneNumber, amount);
      console.log(rechargeAirtime);
 })();
```

```javascript
   //get data bundles
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
       const RoqquPayClass = new RoqquPay();
       const provider = 'mtn';
       const dataBundles = await RoqquPayClass.vtu.getDataBundes(provider);
       console.log(dataBundles);
 })();
```

```javascript
   //get cable bundles
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       //This is the provider of the cable, dstv, gotv and startimes currently enabled
       const provider = 'dstv';
       const cableBundles = await RoqquPayClass.vtu.getCableBundes(operator);
       console.log(cableBundles);
 })();
```

```javascript
   //get account detail
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const getAccountData = await RoqquPayClass.account.getAccountDetail();
       console.log(getAccountData);
 })();
```

```javascript
   //verify bvn
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const bvn = 'bvn digits';
       const verifyBvn = await RoqquPayClass.account.bvnVerify(bvn);
       console.log(verifyBvn);
 })();
```

```javascript
   //get banks
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const banks = await RoqquPayClass.account.getBanks();
       console.log(banks);
 })();
```

```javascript
   //verify account detail
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const accountNumber = 'bank account number';
       const bankName = 'This is the name of the bank gotten from the bank list api';
       const resolveAccount = await RoqquPayClass.account.accountResolve(accountNumber, bankName);
       console.log(resolveAccount);
 })();
```

```javascript
   //get roqqu account detail
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const account = await RoqquPayClass.account.getAccountDetail();
       console.log(account);
 })();
```

```javascript
   //get roqqu transactions
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const transactions = await RoqquPayClass.account.getTransactions();
       console.log(transactions);
 })();
```

```javascript
   //verify NIN
   const RoqquPay = require('roqqupay-nodejs');
  (async function(){
      //your roqqu secret key
       const secretKey = 'Bearer RQ-SEC-XXXXXXXXX';
       const RoqquPayClass = new RoqquPay(secretKey);
       const nin = 'NIN digits';
       const verifyNin = await RoqquPayClass.account.verifyNin(nin);
       console.log(verifyNin);
 })();
```

---
_Source: https://npm.io/package/roqqupay-nodejs · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
