uw-rafiki
v0.0.53
Published
Under writing for personal loan
Downloads
172
Readme
uw-rafiki
description
Installation
This is a Node.js module available through the
npm registry. It can be installed using the
npm
or
yarn
command line tools.
npm install uw-rafiki --save
# for Pay day loan
const { default: UW } = require('uw-rafiki');
const { PDL } = UW;
const uw = new PDL({
# employmentType can be 'SALARIED', FARMER, CASUAL_WORKER, SELF_EMPLOYED
employmentType: 'SALARIED',
awb: 10002 ,
dailyAverageBalance: 10002,
# accomodationType can be 'SELF_OWNED', PG_ACCOMODATION, RENTAL_LIVING_ALONE, RENTAL_LIVING_WITH_FAMILY, PARENTAL, OTHERS
accomodationType: 'SELF_OWNED',
# maritalStatus can be 'MARRIED_WITH_NO_DEPENDENT', MARRIED_WITH_DEPENDENT, UNMARRIED_WITH_DEPENDENT, UNMARRIED_WITH_NO_DEPENDENT, OTHERS
maritalStatus: 'MARRIED_WITH_NO_DEPENDENT',
age: 31,
# scoreCategory can be 'NO-SCORE', RISK, SEVERE, PRIME, ULTIMATE, ELITE
scoreCategory: 'NO-SCORE',
averageWalletCreditToAwb: 1.01,
mobileWalletVintage: 16,
minimumNoOfDebitPerMonth: 22,
minimumNoOfCreditPerMonth: 10,
# walletMnoReportStatus can be 'NEGATIVE', POSITIVE
walletMnoReportStatus: 'POSITIVE',
# rafikiScoreCategory can be 'LOSS', DOBBTFUL, SUBSTANDARD, CURRENT, NEW_CUSTOMER, ESPECIALLY_MENTIONED
rafikiScoreCategory: 'CURRENT'
});
console.log(uw.interestRate);
console.log(uw.scorecard);
console.log(uw.isEligibile());
console.log(uw.isEligibile(88000));
console.log(uw.loans);
# for instant monthly loan
const { default: UW } = require('uw-rafiki');
const { IPL } = UW;
const uw = new IPL({
# employmentType can be 'SALARIED', FARMER, CASUAL_WORKER, SELF_EMPLOYED
employmentType: 'SALARIED',
awb: 10002 ,
dailyAverageBalance: 10002,
# accomodationType can be 'SELF_OWNED', PG_ACCOMODATION, RENTAL_LIVING_ALONE, RENTAL_LIVING_WITH_FAMILY, PARENTAL, OTHERS
accomodationType: 'SELF_OWNED',
# maritalStatus can be 'MARRIED_WITH_NO_DEPENDENT', MARRIED_WITH_DEPENDENT, UNMARRIED_WITH_DEPENDENT, UNMARRIED_WITH_NO_DEPENDENT, OTHERS
maritalStatus: 'MARRIED_WITH_NO_DEPENDENT',
age: 31,
# scoreCategory can be 'NO-SCORE', RISK, SEVERE, PRIME, ULTIMATE, ELITE
scoreCategory: 'NO-SCORE',
averageWalletCreditToAwb: 1.01,
mobileWalletVintage: 16,
minimumNoOfDebitPerMonth: 22,
minimumNoOfCreditPerMonth: 10,
# walletMnoReportStatus can be 'NEGATIVE', POSITIVE
walletMnoReportStatus: 'POSITIVE',
# rafikiScoreCategory can be 'LOSS', DOBBTFUL, SUBSTANDARD, CURRENT, NEW_CUSTOMER, ESPECIALLY_MENTIONED
rafikiScoreCategory: 'CURRENT'
});
console.log(uw.interestRate);
console.log(uw.scorecard);
console.log(uw.isEligibile());
console.log(uw.isEligibile(88000));
console.log(uw.loans);
Tests
npm install
npm test
Usage
Reference
To get better vision about the response structure for 4.x.x series and 5.x.x series check the following link. HTTP response structure
Dependencies
None
Dev Dependencies
- chai: BDD/TDD assertion library for node.js and the browser. Test framework agnostic.
- mocha: simple, flexible, fun test framework
- sinon: JavaScript test spies, stubs and mocks.
License
MIT