kanjo

0.2.0 • Public • Published

kanjo

NPM version NPM downloads Build Status Coverage Status Dependency Status DevDependency Status License

Summarize AWS Billing

Installation

npm install kanjo

Usage

import Kanjo from 'kanjo';
 
const kanjo = new Kanjo({
  account: 'ACCOUNT_ID',
  bucket: 'BUCKET_NAME',
  region: 'us-east-1'
});
 
kanjo.fetch(2015, 9).then(report => {
  console.log(report);
});
 
// Output ->
// { bills:
//    { total:
//       { accountId: 'xxxxxxxxxx',
//         accountName: 'account foo',
//         isPayer: true,
//         totalCost: 1360.57,
//         products: [Object] },
//      'xxxxxxxxxx':
//       { accountId: 'xxxxxxxxxx',
//         accountName: 'account foo',
//         isPayer: false,
//         totalCost: 1148.807296,
//         products: [Object] },
//      'yyyyyyyyyy':
//       { accountId: 'yyyyyyyyyy',
//         accountName: 'account bar',
//         isPayer: false,
//         totalCost: 211.706951,
//         products: [Object] } } }

Related

Todo

  • Add tests
  • Support weekly summary
  • Support daily summary
  • Support monthly forecast

Readme

Keywords

Package Sidebar

Install

npm i kanjo

Weekly Downloads

0

Version

0.2.0

License

MIT

Last publish

Collaborators

  • moqada