@codegame.dev/wallet-cli

1.1.13 • Public • Published

Wallet CLI - Multi-Blockchain Wallet Management Tool

Wallet CLI is a powerful command-line tool for managing multi-blockchain wallets. It allows you to generate public keys, manage balances, transfer funds, and estimate transaction fees with ease. The tool supports a wide range of blockchains and tokens, making it an essential utility for developers and blockchain enthusiasts.


Installation

Install the @codegame.dev/wallet-cli globally using npm:

npm install -g @codegame.dev/wallet-cli

This makes the wallet-cli command accessible from anywhere on your system.


Features

  • Generate public keys for multiple blockchains from an existing or new mnemonic.
  • View wallet balances in real-time.
  • Perform secure and efficient transfers.
  • Estimate transaction fees for supported networks.
  • Wallet creation is supported for most major blockchains, but other features are currently supported for these blockchains: Ethereum, Binance Smart Chain, Polygon, Tron, Ton. In the future, other chains will be added.

Commands Overview

General Options

  • -V, --version: Display the version number.
  • -h, --help: Show help for any command.

Commands

coin-list

Display a list of all supported coins.

Options:

  • -s <text>: Search for a specific coin.
  • --json: Output results in JSON format.

Example:

wallet-cli coin-list -s bitcoin

get-address

Retrieve the public address for a specific coin.

Options:

  • --mnemonic <mnemonic>: Specify an existing mnemonic.
  • --coin <coin>: Name of the coin (based on Trust Wallet Core).
  • --coingecko-platform <platform>: Platform name (based on CoinGecko API).
  • --json: Output results in JSON format.

Example:

wallet-cli get-address --mnemonic "your mnemonic" --coin ethereum

create-wallet

Generate a new mnemonic and wallet.

Options:

  • --coin <coin>: Name of the coin (based on Trust Wallet Core).
  • --coingecko-platform <platform>: Platform name (based on CoinGecko API).
  • --json: Output results in JSON format.

Example:

wallet-cli create-wallet --coin bitcoin

get-balance

Check the balance of a wallet for a coin or token.

Options:

  • --coin <coin>: Name of the coin (based on Trust Wallet Core).
  • --coingecko-platform <platform>: Platform name (based on CoinGecko API).
  • --address <address>: Wallet address.
  • --token-address <token-address>: Contract address of the token.
  • --json-rpc-provider <url>: URL of the JSON-RPC provider.
  • --http-provider <url>: URL of the HTTP provider.
  • --json: Output results in JSON format.
  • --testnet: Use the testnet provider.

Example:

wallet-cli get-balance --coin ethereum --address 0xYourAddress

transfer

Send coins or tokens to another wallet.

Options:

  • --mnemonic <mnemonic>: Specify an existing mnemonic.
  • --coin <coin>: Name of the coin (based on Trust Wallet Core).
  • --coingecko-platform <platform>: Platform name (based on CoinGecko API).
  • --address <address>: Recipient wallet address.
  • --amount <amount>: Amount to transfer.
  • --token-address <token-address>: Contract address of the token.
  • --json-rpc-provider <url>: URL of the JSON-RPC provider.
  • --json: Output results in JSON format.
  • --testnet: Use the testnet provider.

Example:

wallet-cli transfer --mnemonic "your mnemonic" --coin ethereum --address 0xReceiverAddress --amount 0.1

estimate-fee

Estimate the fees for a coin or token transfer.

Options:

  • --mnemonic <mnemonic>: Specify an existing mnemonic.
  • --coin <coin>: Name of the coin (based on Trust Wallet Core).
  • --coingecko-platform <platform>: Platform name (based on CoinGecko API).
  • --address <address>: Recipient wallet address.
  • --amount <amount>: Amount to transfer.
  • --token-address <token-address>: Contract address of the token.
  • --json-rpc-provider <url>: URL of the JSON-RPC provider.
  • --json: Output results in JSON format.
  • --testnet: Use the testnet provider.

Example:

wallet-cli estimate-fee --mnemonic "your mnemonic" --coin ethereum --address 0xReceiverAddress --amount 0.1

Supported Networks

The following networks are supported for get-balance, transfer, and estimate-fee commands:

  • Ethereum (ETH)
  • Binance Smart Chain (BSC)
  • Polygon POS (POL)
  • Tron (TRX)
  • Ton (TON) - static estimate-fee

Acknowledgements

Wallet CLI leverages the following libraries:

Special thanks to these projects for their contributions to the blockchain ecosystem.


License

This project is licensed under the MIT License. See the LICENSE file for details.

/@codegame.dev/wallet-cli/

    Package Sidebar

    Install

    npm i @codegame.dev/wallet-cli

    Weekly Downloads

    12

    Version

    1.1.13

    License

    MIT

    Unpacked Size

    124 kB

    Total Files

    38

    Last publish

    Collaborators

    • dev.codegames
    • syblock