npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

heroku-usage-plugin

v1.4.5

Published

Simple plugin to provide app / addon / dyno heroku usage for users / teams / enterprise accounts

Downloads

5

Readme

heroku-usage-plugin

Simple plugin to provide app / addon / dyno heroku usage for users / teams / enterprise accounts

oclif Version Downloads/week License

Usage

Install through heroku plugins:install heroku-usage-plugin

Commands

heroku usage:daily

Usage for an Enterprise Account / Team at a Daily resolution.

USAGE
  $ heroku usage:daily

OPTIONS
  -a, --account=account        Enterprise Account Id
  -b, --begin=begin            Inclusive Start YYYY-MM-DD to ask from
  -e, --end=end                Inclusive End YYYY-MM-DD to ask until
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              Heroku Team Id

DESCRIPTION
  Team: Name of the Enterprise Account / Team
  App: Application Name
  Date: Date of the usage
  Addons: Total add-on credits used
  Dynos: Dyno credits used
  Data: Add-On credits used for first party add-ons
  Partner: Add-On credits used for third party add-ons
  Space: Private Space credits used

  https://devcenter.heroku.com/articles/platform-api-reference#enterprise-account-daily-usage

See code: src/commands/usage/daily.js

heroku usage:list:apps

Determines the list of apps available: by user or team.

USAGE
  $ heroku usage:list:apps

OPTIONS
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or id or self

DESCRIPTION
  (If no user or term is specified, then the apps available to the current user is provided)

See code: src/commands/usage/list/apps.js

heroku usage:monthly

Usage for an Enterprise Account / Team at a Monthly resolution.

USAGE
  $ heroku usage:monthly

OPTIONS
  -a, --account=account        Enterprise Account Id
  -b, --begin=begin            Inclusive Start YYYY-MM to ask from
  -e, --end=end                Inclusive End YYYY-MM to ask until
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              (required) Heroku Team Id

DESCRIPTION
  Team: Name of the Enterprise Account / Team
  App: Application Name
  Date: Date of the usage
  Addons: Total add-on credits used
  Connect: Heroku Connect rows managed
  Dynos: Dyno credits used
  Data: Add-On credits used for first party add-ons
  Partner: Add-On credits used for third party add-ons
  Space: Private Space credits used

  For more information, please see: 
  https://devcenter.heroku.com/articles/platform-api-reference#enterprise-account-monthly-usage

See code: src/commands/usage/monthly.js

heroku usage:pg:extra

Wrapper for running a heroku-pg-extras plugin with additional output options.

USAGE
  $ heroku usage:pg:extra

OPTIONS
  -a, --app=app                (required) App to run the command against
  -c, --command=command        (required) The pg:[COMMAND] to run. (ex: seq-scans, size-table, etc.)
  -f, --format=human|json|csv  [default: human] format of output

DESCRIPTION
  For example: human readible format, csv and JSON.

  (Note that this assumes that the pg-extras)

  For more information, please see:
  https://github.com/heroku/heroku-pg-extras

See code: src/commands/usage/pg/extra.js

heroku usage:pg:query

Performs a query against the postgres database of a specific app.

USAGE
  $ heroku usage:pg:query

OPTIONS
  -a, --app=app                (required) App to run the command against
  -c, --command=command        SQL command to run
  -f, --format=human|json|csv  [default: human] format of output
  -l, --file=file              Path to file with SQL command to run

DESCRIPTION
  (Note: this is intended to be similar to pg:psql - with the added ability to export as JSON)

See code: src/commands/usage/pg/query.js

heroku usage:status

Current add-on / attachment / dyno / app status.

USAGE
  $ heroku usage:status

OPTIONS
  -a, --app=app                comma separated list of app names or ids
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or user id

DESCRIPTION
  (Please note that if neither a team or user is specified, all apps for the current user are determined)

  This includes the add-ons status, attachment status, dynos status, and app status commands.

  Please see those commands for more detail.

See code: src/commands/usage/status/index.js

heroku usage:status:addon

Add-Ons leveraged for a set of Heroku Apps.

USAGE
  $ heroku usage:status:addon

OPTIONS
  -a, --app=app                comma separated list of app names or ids
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or user id

DESCRIPTION
  The number of Attached Add-Ons are currently limited to the Applications retrieved.
  To get a truly representative list of Apps using the Add-Ons,
  it is recommended that a wider net of Applications be requested.

  The full list of applications that leverage the attachment is the
  'attachmentApplications' list provided within --format JSON.

  (Please note that if neither a team or user is specified, all apps for the current user are considered)

  The ListPrice of the Add-On is likely not the price being paid.
  However, this price can often directionally which Add-Ons are more expensive than others.

  App Name: Name of the Heroku Application
  Add-On Name: Specific name for this add-on
  Service: Name of the Add-On Service
  Attachments: # of apps this Add-On is attached to
  Plan: Name of the Plan this Add-On is using.
  ListPrice: List Price this Add-On would normally cost.
  Unit: The frequency that the Add-On cost would occur (ex: monthly)
  Updated At: Date/Time the Application was last updated
  Created At: Date/Time the Application was created

  For more information, please see:
  https://devcenter.heroku.com/articles/platform-api-reference#add-on

See code: src/commands/usage/status/addon.js

heroku usage:status:app

Status for a set of heroku apps.

USAGE
  $ heroku usage:status:app

OPTIONS
  -a, --app=app                comma separated list of app names or ids
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or user id

DESCRIPTION
  (Please note that if neither a team or user is specified, all apps for the current user are considered)

  App Name: Name of the Heroku Application
  Region: Region of the Heroku Application
  Maintenance: Whether the app is under maintenance mode (true) or not (false)
  Repo Size: Size of the repository for the Application
  Slug Size: Size of the Slug used for the Application
  Space: Name of the Private Space used
  Updated At: Date/Time the Application was last updated
  Created At: Date/Time the Application was created

  For more information, please see:
  https://devcenter.heroku.com/articles/platform-api-reference#app

See code: src/commands/usage/status/app.js

heroku usage:status:attachment

List of Add-Ons at the attachment level.

USAGE
  $ heroku usage:status:attachment

OPTIONS
  -a, --app=app                comma separated list of app names or ids
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or user id

DESCRIPTION
  (Please note that if neither a team or user is specified, all apps for the current user are considered)

  Attachment Name: Unique name for this add-on attachment to this app
  Add-On Name: Globally unique name of the Add-On
  Relationship: whether the attachment is owned by a different app (attached) or directly by the app (direct)
  Owning App: Name of the singular app that owns the Add-On
  Attached App: Name of the app that this add-on is attached to
  Created At: the date the attachment was created
  Updated At: the date the attachment was updated

  For more information, please see:
  https://devcenter.heroku.com/articles/platform-api-reference#add-on-attachment

See code: src/commands/usage/status/attachment.js

heroku usage:status:dyno

Dynos leveraged for a set of heroku apps.

USAGE
  $ heroku usage:status:dyno

OPTIONS
  -a, --app=app                comma separated list of app names or ids
  -f, --format=human|json|csv  [default: human] format of output
  -t, --team=team              team name or id
  -u, --user=user              account email or user id

DESCRIPTION
  (Please note that if neither a team or user is specified, all apps for the current user are considered)

  The ListPrice of the Dyno is likely not the price being paid.
  However, this price can often directionally which Dynos are more expensive than others.

  App Name: Name of the Heroku Application
  Dyno Name: Name of the process on this dyno
  Size: Dyno Size (ex: 'standard-1X')
  State: Current status of the process (ex: crashed, up, down, etc.)
  Type: Type of process
  Units: Number of units incurred for this Dyno Size type
  ListPrice: List Price this Dyno would normally cost.
  Unit: The frequency that the Dyno cost would occur (ex: monthly)
  Updated At: Date/Time the Application was last updated
  Created At: Date/Time the Application was created

  For more information, please see:
  https://devcenter.heroku.com/articles/platform-api-reference#dyno

See code: src/commands/usage/status/dyno.js