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

@basis-theory-labs/cli

v1.10.0

Published

Basis Theory CLI tool

Downloads

38

Readme

Basis Theory CLI

Version Release

Basis Theory CLI tool

Make sure to either have a BT_MANAGEMENT_KEY env var exported or pass a management-key flag to the commands.

Usage

$ npm install -g @basis-theory-labs/cli
$ bt COMMAND
running command...
$ bt (--version)
@basis-theory-labs/cli/1.10.0 linux-x64 node-v18.19.0
$ bt --help [COMMAND]
USAGE
  $ bt COMMAND
...

Commands

bt applications

List Applications. Requires application:read Management Application permission

USAGE
  $ bt applications -x <value> [-p <value>]

FLAGS
  -p, --page=<value>            [default: 1] Applications list page to fetch
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  List Applications. Requires `application:read` Management Application permission

EXAMPLES
  $ bt applications

See code: dist/commands/applications/index.ts

bt applications create

Creates a new Application. Requires application:create Management Application permission

USAGE
  $ bt applications create -x <value> [-n <value>] [-p <value>] [-t private|public|management] [-z <value>]

FLAGS
  -n, --name=<value>            name of the Application
  -p, --permission=<value>...   permission(s) to use in the Application
  -t, --type=<option>           type of the Application
                                <options: private|public|management>
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy
  -z, --template=<value>        template ID to create the application with

DESCRIPTION
  Creates a new Application. Requires `application:create` Management Application permission

EXAMPLES
  $ bt applications create

bt applications delete ID

Deletes a Application. Requires application:delete Management Application permissions

USAGE
  $ bt applications delete ID -x <value> [-y]

ARGUMENTS
  ID  Application id to delete

FLAGS
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy
  -y, --yes                     auto confirm the operation

DESCRIPTION
  Deletes a Application. Requires `application:delete` Management Application permissions

EXAMPLES
  $ bt applications delete 03858bf5-32d3-4a2e-b74b-daeea0883bca

bt applications update ID

Updates a new Application. Requires application:update Management Application permission

USAGE
  $ bt applications update ID -x <value> [-n <value>] [-p <value>]

ARGUMENTS
  ID  Application id to update

FLAGS
  -n, --name=<value>            name of the Application
  -p, --permission=<value>...   permission(s) to use in the Application
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Updates a new Application. Requires `application:update` Management Application permission

EXAMPLES
  $ bt applications update

bt proxies

List Proxies. Requires proxy:read Management Application permission

USAGE
  $ bt proxies -x <value> [-p <value>]

FLAGS
  -p, --page=<value>            [default: 1] Proxies list page to fetch
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  List Proxies. Requires `proxy:read` Management Application permission

EXAMPLES
  $ bt proxies

See code: dist/commands/proxies/index.ts

bt proxies create

Creates a new Pre-Configured Proxy. Requires proxy:create Management Application permission

USAGE
  $ bt proxies create -x <value> [-n <value>] [-u <value>] [-q <value>] [-s <value>] [-i <value>] [-c <value>] [-a]

FLAGS
  -a, --[no-]require-auth                whether the Proxy requires Basis Theory authentication to be invoked. Default:
                                         true
  -c, --configuration=<value>            path to configuration file (.env format) to use in the Proxy
  -i, --application-id=<value>           application ID to use in the Proxy
  -n, --name=<value>                     name of the Proxy
  -q, --request-transform-code=<value>   path to JavaScript file containing a Request Transform code
  -s, --response-transform-code=<value>  path to JavaScript file containing a Response Transform code
  -u, --destination-url=<value>          URL to which requests will be proxied
  -x, --management-key=<value>           (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Creates a new Pre-Configured Proxy. Requires `proxy:create` Management Application permission

EXAMPLES
  $ bt proxies create

bt proxies delete ID

Deletes a Proxy. Requires proxy:delete Management Application permissions

USAGE
  $ bt proxies delete ID -x <value> [-y]

ARGUMENTS
  ID  Proxy id to delete

FLAGS
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy
  -y, --yes                     auto confirm the operation

DESCRIPTION
  Deletes a Proxy. Requires `proxy:delete` Management Application permissions

EXAMPLES
  $ bt proxies delete 03858bf5-32d3-4a2e-b74b-daeea0883bca

bt proxies logs [ID]

Display live Proxy Transform logs output. Requires proxy:update Management Application permissions

USAGE
  $ bt proxies logs [ID] -x <value> [-p <value>]

ARGUMENTS
  ID  Proxy id to connect to

FLAGS
  -p, --port=<value>            [default: 8220] port to listen for incoming logs
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Display live Proxy Transform logs output. Requires `proxy:update` Management Application permissions

EXAMPLES
  $ bt proxies logs

  $ bt proxies logs 03858bf5-32d3-4a2e-b74b-daeea0883bca

  $ bt proxies logs 03858bf5-32d3-4a2e-b74b-daeea0883bca -p 3000

bt proxies update ID

Updates an existing Pre-Configured Proxy. Requires proxy:update Management Application permission

USAGE
  $ bt proxies update ID -x <value> [-n <value>] [-u <value>] [-q <value>] [-s <value>] [-i <value>] [-c <value>]
    [-a] [-w] [-l]

ARGUMENTS
  ID  Proxy id to update

FLAGS
  -a, --[no-]require-auth                whether the Proxy requires Basis Theory authentication to be invoked. Default:
                                         true
  -c, --configuration=<value>            path to configuration file (.env format) to use in the Proxy
  -i, --application-id=<value>           application ID to use in the Proxy
  -l, --logs                             Start logs server after update
  -n, --name=<value>                     name of the Proxy
  -q, --request-transform-code=<value>   path to JavaScript file containing a Request Transform code
  -s, --response-transform-code=<value>  path to JavaScript file containing a Response Transform code
  -u, --destination-url=<value>          URL to which requests will be proxied
  -w, --watch                            Watch for changes in informed files
  -x, --management-key=<value>           (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Updates an existing Pre-Configured Proxy. Requires `proxy:update` Management Application permission

EXAMPLES
  $ bt proxies update 03858bf5-32d3-4a2e-b74b-daeea0883bca

  $ bt proxies update 03858bf5-32d3-4a2e-b74b-daeea0883bca --destination-url https://echo.basistheory.com

  $ bt proxies update 03858bf5-32d3-4a2e-b74b-daeea0883bca --request-transform-code ./myRequestTransform.js

  $ bt proxies update 03858bf5-32d3-4a2e-b74b-daeea0883bca --configuration ./.env.proxy

bt reactorFormulas

[Deprecated] List Reactor Formulas. Requires reactor:read Management Application permission

USAGE
  $ bt reactorFormulas -x <value> [-p <value>]

FLAGS
  -p, --page=<value>            [default: 1] Reactors formulas list page to fetch
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  [Deprecated] List Reactor Formulas. Requires `reactor:read` Management Application permission

EXAMPLES
  $ bt reactorFormulas

See code: dist/commands/reactorFormulas/index.ts

bt reactorFormulas update ID

[Deprecated] Updates an existing Reactor Formula. Requires reactor:update Management Application permission

USAGE
  $ bt reactorFormulas update ID -x <value> -n <value> -s <value> -c <value> -p <value> [-d <value>] [-i <value>] [-w]

ARGUMENTS
  ID  Reactor Formula id to update

FLAGS
  -c, --configuration=<value>       (required) path to configuration definition to use in the Reactor Formula
  -d, --description=<value>         description of the Reactor Formula
  -i, --icon=<value>                icon of the Reactor Formula
  -n, --name=<value>                (required) name of the Reactor Formula
  -p, --request-parameters=<value>  (required) path to request params definition to use in the Reactor Formula
  -s, --code=<value>                (required) path to JavaScript file containing code
  -w, --watch                       Watch for changes in informed files
  -x, --management-key=<value>      (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  [Deprecated] Updates an existing Reactor Formula. Requires `reactor:update` Management Application permission

EXAMPLES
  $ bt reactorFormulas update 03858bf5-32d3-4a2e-b74b-daeea0883bca

  $ bt reactorFormulas update 03858bf5-32d3-4a2e-b74b-daeea0883bca --code ./formula.js

  $ bt reactorFormulas update 03858bf5-32d3-4a2e-b74b-daeea0883bca --code ./formula.js -w

bt reactors

List Reactors. Requires reactor:read Management Application permission

USAGE
  $ bt reactors -x <value> [-p <value>]

FLAGS
  -p, --page=<value>            [default: 1] Reactors list page to fetch
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  List Reactors. Requires `reactor:read` Management Application permission

EXAMPLES
  $ bt reactors

See code: dist/commands/reactors/index.ts

bt reactors create

Creates a new Reactor. Requires reactor:create Management Application permission

USAGE
  $ bt reactors create -x <value> [-n <value>] [-c <value>] [-i <value>] [-r <value>]

FLAGS
  -c, --configuration=<value>   path to configuration file (.env format) to use in the Reactor
  -i, --application-id=<value>  application ID to use in the Reactor
  -n, --name=<value>            name of the Reactor
  -r, --code=<value>            path to JavaScript file containing the Reactor code
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Creates a new Reactor. Requires `reactor:create` Management Application permission

EXAMPLES
  $ bt reactors create

bt reactors delete ID

Deletes a Reactor. Requires reactor:delete Management Application permissions

USAGE
  $ bt reactors delete ID -x <value> [-y]

ARGUMENTS
  ID  Reactor id to delete

FLAGS
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy
  -y, --yes                     auto confirm the operation

DESCRIPTION
  Deletes a Reactor. Requires `reactor:delete` Management Application permissions

EXAMPLES
  $ bt reactors delete 03858bf5-32d3-4a2e-b74b-daeea0883bca

bt reactors logs [ID]

Display live Reactor logs output. Requires reactor:update Management Application permissions

USAGE
  $ bt reactors logs [ID] -x <value> [-p <value>]

ARGUMENTS
  ID  Reactor id to connect to

FLAGS
  -p, --port=<value>            [default: 8220] port to listen for incoming logs
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Display live Reactor logs output. Requires `reactor:update` Management Application permissions

EXAMPLES
  $ bt reactors logs

  $ bt reactors logs 03858bf5-32d3-4a2e-b74b-daeea0883bca

  $ bt reactors logs 03858bf5-32d3-4a2e-b74b-daeea0883bca -p 3000

bt reactors update ID

Updates an existing Reactor. Requires reactor:update Management Application permission

USAGE
  $ bt reactors update ID -x <value> [-n <value>] [-c <value>] [-i <value>] [-r <value>] [-w] [-l]

ARGUMENTS
  ID  Reactor id to update

FLAGS
  -c, --configuration=<value>   path to configuration file (.env format) to use in the Reactor
  -i, --application-id=<value>  application ID to use in the Reactor
  -l, --logs                    Start logs server after update
  -n, --name=<value>            name of the Reactor
  -r, --code=<value>            path to JavaScript file containing the Reactor code
  -w, --watch                   Watch for changes in informed files
  -x, --management-key=<value>  (required) management key used for connecting with the reactor / proxy

DESCRIPTION
  Updates an existing Reactor. Requires `reactor:update` Management Application permission

EXAMPLES
  $ bt reactors update 03858bf5-32d3-4a2e-b74b-daeea0883bca

  $ bt reactors update 03858bf5-32d3-4a2e-b74b-daeea0883bca --code ./reactor.js

  $ bt reactors update 03858bf5-32d3-4a2e-b74b-daeea0883bca --configuration ./.env.reactor