1.0.0 • Published 5 years ago

@antoniogomez/bitconnect-interest-rate-api v1.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
5 years ago

BitConnect Interest Rate Parser API

npm-image version-image

Install


$ npm install @antoniogomez/bitconnect-interest-rate-api --save

Description


BitConnect price volatility accrued daily on a simple Node.js API.

Usage


const bitconnectInterest = require('@antoniogomez/bitconnect-interest-rate-api');

(async () => {

	const lastSixDays = await bitconnectInterest.lastSixDays();
	console.log(lastSixDays);
	/*
	[
		{ interest: '0.04%', date: '2017-12-27', status: 'Pending' },
		{ interest: '0.48%', date: '2017-12-26', status: 'Today' },
		{ interest: '1.20%', date: '2017-12-25', status: 'Applied' },
		{ interest: '1.28%', date: '2017-12-24', status: 'Applied' },
		{ interest: '0.52%', date: '2017-12-23', status: 'Applied' },
		{ interest: '1.34%', date: '2017-12-22', status: 'Applied' }
	]
	*/

	const latest = await bitconnectInterest.latest();
	console.log(latest);
	// -> { interest: '0.04%', date: '2017-12-27', status: 'Pending' }

	const lastSevenDays = await bitconnectInterest.lastSevenDaysAverage();
	console.log(lastSevenDays);
	// -> '0.91%'

	const lastThirtyDays = await bitconnectInterest.lastThirtyDaysAverage();
	console.log(lastThirtyDays);
	// -> '0.86%'

	const lastSixMonths = await bitconnectInterest.lastSixMonthsAverage();
	console.log(lastSixMonths);
	// -> '0.94%'

})();

Example


$ npm install
$ npm run example

Bitcoin Donations


Bitcoin: 1AUd5ytuM2DuP2VyF71g4vpfjApJqXy6fm

BitConnect referral

Changelog


1.0.0 (Dic 26 2017)

  • Added basic API methods:
  • lastSixDays
  • latest
  • lastSevenDaysAverage
  • lastThirtyDaysAverage
  • lastSixMonthsAverage

0.0.0 (Dic 25 2017)

  • Initial development.

License

MIT © Antonio Gomez

1.0.0

5 years ago