Catalog npm
Back to packageRELEASE DETAILS

0.10.12

npm

0xweb

Contract package manager and other web3 tools

auto-generationcli walletcontractsevmweb3cli
Published30 Oct 2023
Direct dependencies31
Transitive dependenciesNot calculated

README

Current package documentation

0xweb - Contract package manager and CLI Web3 Toolkit


Website Link Documentation Link NPM version CircleCI

  • Generate TypeScript or ES6 classes for contracts fetched from Etherscan and Co.
  • CLI commands to query the contracts or to submit transactions
  • RESTful API for the installed contracts
  • Deploy and track deployed contracts with ease

Dequanto library 📦 is used for the wrapped classes

Here the example of generated classes: 0xweb-org/0xweb-sample 🔗

Install

$ npm i 0xweb -g

# Boostrap dequanto library in cwd
$ 0xweb init

# Download sources/ABI and generate TS classes
$ 0xweb install 0x5f4ec3df9cbd43714fe2740f5e3616155c5b8419 --name chainlink/oracle-eth

Use the --hardhat flag, if you want to develop|compile|deploy|test contracts: 0xweb init --hardhat

API Usage

Use autogenerated TypeScript classes for much safer and faster backend implementation

import { ChainlinkOracleEth } from '0xc/eth/chainlink/oracle-eth/oracle-eth';
import { Config } from 'dequanto/config/Config';
import { $bigint } from 'dequanto/utils/$bigint';

await Config.fetch();

let oracle = new ChainlinkOracleEth();
let decimals = await oracle.decimals();
let price = await oracle.latestAnswer();

console.log(`ETH Price`, $bigint.toEther(price, decimals));

CLI Usage

READ and WRITE to installed contracts directly from the command line

$ 0xweb contract chainlink/oracle-eth latestAnswer

WEB Usage

The package has the built-in web interface to make the blockchain analyze and interaction simpler.

  1. If you initialize the Transaction via CMD, you may want to sign the transaction with your browser wallet. For this, 0xweb spins up the HTTP server and redirects your browser to visit local page where the details of the transaction being shown, and you can sign and submit the transaction.

  2. Launch local server to view the validated contract in UI interface to interact with.

0xweb server start

Config

❗❣️❗ We include our default KEYs for etherscan/co and infura. They are rate-limited. Please, create and insert your keys. Thank you!

$ 0xweb config --edit

## optionally, you can provide the Nodes Endpoint with `--endpoint` flag
$ 0xweb COMMAND --endpoint https://my-node-url-here

Commands overview 🔗

Various Blockchain tools

Get the commands overview

$ 0xweb --help
$ 0xweb install --help

block

  1. Get current block info
$ 0xweb block get latest

token

  1. Get Token Price
$ 0xweb token price WETH

accounts

🔐 Wallet feature allows to store accounts in encrypted local storage. We use local machine KEY and provided PIN in arguments or environment to create cryptographically strong secrets 🔑 for account encryption.

When calling contracts WRITE methods, you should first add an account to the wallet, and then use PIN to unlock the storage

$ 0xweb account add --name foo --key the_private_key --pin foobar
$ 0xweb token transfer USDC --from foo --to 0x123456 --amount 20 --pin foobar

🏁


©️ MIT License.

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 31

Native requirements
31 direct targetsNot calculated transitive count
Package / targetRequirementRelationship
a-di
Environment
{
  "local_name": "a-di",
  "alias": false,
  "peer_metadata": null
}
^1.0.25runtime
alot
Environment
{
  "local_name": "alot",
  "alias": false,
  "peer_metadata": null
}
^0.3.4runtime
memd
Environment
{
  "local_name": "memd",
  "alias": false,
  "peer_metadata": null
}
^0.3.10runtime
appcfg
Environment
{
  "local_name": "appcfg",
  "alias": false,
  "peer_metadata": null
}
^0.4.68runtime
atma-io
Environment
{
  "local_name": "atma-io",
  "alias": false,
  "peer_metadata": null
}
^1.2.60runtime
everlog
Environment
{
  "local_name": "everlog",
  "alias": false,
  "peer_metadata": null
}
^1.0.9runtime
shellbee
Environment
{
  "local_name": "shellbee",
  "alias": false,
  "peer_metadata": null
}
^0.5.22runtime
atma-utils
Environment
{
  "local_name": "atma-utils",
  "alias": false,
  "peer_metadata": null
}
^0.2.60runtime
@scure/bip32
Environment
{
  "local_name": "@scure/bip32",
  "alias": false,
  "peer_metadata": null
}
^1.3.2runtime
@scure/bip39
Environment
{
  "local_name": "@scure/bip39",
  "alias": false,
  "peer_metadata": null
}
^1.2.1runtime
@noble/curves
Environment
{
  "local_name": "@noble/curves",
  "alias": false,
  "peer_metadata": null
}
^1.2.0runtime
@noble/hashes
Environment
{
  "local_name": "@noble/hashes",
  "alias": false,
  "peer_metadata": null
}
^1.3.2runtime
isomorphic-ws
Environment
{
  "local_name": "isomorphic-ws",
  "alias": false,
  "peer_metadata": null
}
^5.0.0runtime
atma-io-middleware-yml
Environment
{
  "local_name": "atma-io-middleware-yml",
  "alias": false,
  "peer_metadata": null
}
^1.1.25runtime
@solidity-parser/parser
Environment
{
  "local_name": "@solidity-parser/parser",
  "alias": false,
  "peer_metadata": null
}
^0.16.0runtime
@gnosis.pm/safe-core-sdk
Environment
{
  "local_name": "@gnosis.pm/safe-core-sdk",
  "alias": false,
  "peer_metadata": null
}
^2.1.0runtime
@gnosis.pm/safe-web3-lib
Environment
{
  "local_name": "@gnosis.pm/safe-web3-lib",
  "alias": false,
  "peer_metadata": null
}
^1.1.0runtime
@gnosis.pm/safe-service-client
Environment
{
  "local_name": "@gnosis.pm/safe-service-client",
  "alias": false,
  "peer_metadata": null
}
^1.1.2runtime
atma
Environment
{
  "local_name": "atma",
  "alias": false,
  "peer_metadata": null
}
^0.15.17development
hardhat
Environment
{
  "local_name": "hardhat",
  "alias": false,
  "peer_metadata": null
}
^2.18.0development
typedoc
Environment
{
  "local_name": "typedoc",
  "alias": false,
  "peer_metadata": null
}
^0.23.14development
atma-utest
Environment
{
  "local_name": "atma-utest",
  "alias": false,
  "peer_metadata": null
}
^0.21.31development
dts-bundle
Environment
{
  "local_name": "dts-bundle",
  "alias": false,
  "peer_metadata": null
}
^0.7.3development
typescript
Environment
{
  "local_name": "typescript",
  "alias": false,
  "peer_metadata": null
}
^4.8.2development
@types/node
Environment
{
  "local_name": "@types/node",
  "alias": false,
  "peer_metadata": null
}
^12.6.2development
app-bundler
Environment
{
  "local_name": "app-bundler",
  "alias": false,
  "peer_metadata": null
}
^0.1.10development
@0xweb/hardhat
Environment
{
  "local_name": "@0xweb/hardhat",
  "alias": false,
  "peer_metadata": null
}
^0.1.15development
atma-loader-ts
Environment
{
  "local_name": "atma-loader-ts",
  "alias": false,
  "peer_metadata": null
}
^1.1.18development
@nomiclabs/hardhat-web3
Environment
{
  "local_name": "@nomiclabs/hardhat-web3",
  "alias": false,
  "peer_metadata": null
}
^2.0.0development
@openzeppelin/contracts
Environment
{
  "local_name": "@openzeppelin/contracts",
  "alias": false,
  "peer_metadata": null
}
^4.9.3development
@nomiclabs/hardhat-ethers
Environment
{
  "local_name": "@nomiclabs/hardhat-ethers",
  "alias": false,
  "peer_metadata": null
}
^2.1.0development

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "shasum": "30be2fb502010e9caf6049c1e7ae657c06758252",
  "tarball": "https://registry.npmjs.org/0xweb/-/0xweb-0.10.12.tgz",
  "fileCount": 1264,
  "integrity": "sha512-vI/zxeIvzfODoG08Iv1NtW+4xy6WJMi1XcguL80Tu2Y+lxsoX8I7dlkIdzook3DqvM9E93L87XsLBDLVGqx7hg==",
  "signatures": [
    {
      "sig": "MEUCIQCBRv2UVlj5XQmdA0Qka2nk0auNbdoKvNI11SKl/knX2AIgAulSA8ZR73ES++roKj6+XTO0fWZZUrWvxYeoM+rDATU=",
      "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"
    }
  ],
  "unpackedSize": 26921318
}

Repository

PENDING
tenbits/0xweb

Shared repository data · GitHub

License detected in repository
Not collected

Repository

PENDING
0xweb-org/0xweb

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 17:54 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:99eaefcbdebdaf7dc5c7c7df3a6965db50e2714ff4abb53c0fb6a0fb6ba99a06

Other collected versions

0.11.112 Oct0.11.1017 Jun0.11.99 Apr0.11.83 Mar0.11.725 Feb0.11.222 OctView all collected versions →