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 🙏

© 2025 – Pkg Stats / Ryan Hefner

@btr-supply/swap-cli

v1.44.0

Published

Command-line interface for the BTR Swap SDK

Downloads

2

Readme

BTR Swap CLI

Command-line interface for the BTR Swap SDK.

Installation

npm install -g @btr-supply/swap-cli

Usage

btr-swap quote [options]

Options

--input <token>            Required. Input token details <chainId:address:symbol:decimals>
--input-amount <amount>    Required. Amount in wei (e.g., 1000000000000000000 or 1e18).
--output <token>           Required. Output token details <chainId:address:symbol:decimals>
--payer <address>          Required. Payer address.
--receiver <address>       Optional. Receiver address. Defaults to payer address.
--max-slippage <bps>       Maximum slippage tolerance in basis points (e.g., 50 for 0.5%, default: 500).
--aggregators <ids>        Comma-separated aggregator IDs (e.g. LIFI,UNIZEN).
                          Defaults to LIFI,SOCKET,UNIZEN,RANGO,SQUID.
--api-keys <json>          JSON string for multiple API keys: '{"RANGO":"key1","SOCKET":"key2",...}'.
--referrer-codes <json>    JSON string for referrer codes/addresses: '{"RANGO":"ref1","ONE_INCH":123,...}'.
--integrator-ids <json>    JSON string for per-aggregator integrator IDs: '{"LIFI":"custom-id-1","SQUID":"custom-id-2"}'.
--fees-bps <json>          JSON string for integrator fee basis points: '{"LIFI":20,"SOCKET":30}'.
--display <modes>          Comma-separated display modes: ALL,BEST,ALL_COMPACT,BEST_COMPACT,RANK.
--serialization <mode>     Serialization mode: JSON,CSV,TABLE.
--env-file <path>          Path to custom .env file to load environment variables from.
-h, --help                 Display this help message.

Examples

Same-chain ETH -> DAI on Ethereum via 1inch:

btr-swap quote \
  --input 1:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE:ETH:18 \
  --output 1:0x6B175474E89094C44Da98b954EedeAC495271d0F:DAI:18 \
  --input-amount 1e18 \
  --payer 0xYourAddressHere \
  --aggregators LIFI

Cross-chain ETH (Eth) -> DAI (Optimism) via LiFi & Squid with a custom .env file:

btr-swap quote \
  --input 1:0xEeeeeEeeeEeEeeEeEeEeeEEEeeeeEeeeeeeeEEeE:ETH:18 \
  --output 10:0xDA10009cBd5D07dd0CeCc66161FC93D7c9000da1:DAI:18 \
  --input-amount 1e18 \
  --payer 0xYourAddressHere \
  --aggregators LIFI,SQUID \
  --serialization TABLE \
  --display RANK,ALL_COMPACT \
  --env-file ./custom.env

Using API keys and integrator IDs:

btr-swap quote \
  --input 137:0x...:ETH:18 \
  --output 1:0x...:DAI:18 \
  --input-amount 5e17 \
  --payer 0x... \
  --aggregators RANGO,LIFI \
  --integrator-ids '{"LIFI":"integrator-id"}' \
  --api-keys '{"RANGO":"api-key"}' \
  --serialization TABLE

Environment Variables

You can use a .env file in the current directory or specify a custom .env file with the --env-file option.

License

MIT