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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@pwrjs/core

v0.13.6

Published

PWRJS is a javasrcipt library for interacting with the PWR network.

Downloads

375

Readme

PWRJS

PWRJS is a JavaScript library for interacting with the PWR blobkchain. It provides an interface for wallet management and sending transactions on PWR.

Pull Requests welcome

Installation

install the package according to your environment. (nodejs or browser)

# latest official release (main branch)
$ npm install @pwrjs/core

# for latest pre-release version (develop branch)
$ npm install @pwrjs/core@next

# for latest beta release version (beta branch)
$ npm install @pwrjs/core@beta

🌐 Documentation

How to Guides 🔜 & API 💻

Play with Code Examples 🎮

💫 Getting Started

Import the library:

import PWRJS from "@pwrjs/core";
import Wallet from "@pwrjs/core/wallet";

// or
const PWRJS = require('@pwrjs/core');
const Wallet = require('@pwrjs/core/wallet');

Create a new instance

const pwrjs = new PWRJS('https://pwrrpc.pwrlabs.io');

Generate a new random wallet:

const wallet = Wallet.newRandom(12);

Import wallet by Seed Phrase:

const seedPhrase = "your seed phrase here";
const wallet = Wallet.fromSeedPhrase(seedPhrase);

Get wallet address:

const address = wallet.getAddress();

Get wallet seed phrase:

const seedPhrase = wallet.getSeedPhrase();

Get wallet balance:

const balance = await wallet.getBalance();

Transfer PWR tokens:

const recipientAddress = '0x...';
const pwrAmount = '1000000000'; // 1 PWR = 10^9
await wallet.transferPWR(recipientAddress, BigInt(pwrAmount));

Sending a transcation to the PWR Chain returns a Response object, which specified if the transaction was a success, and returns relevant data. If the transaction was a success, you can retrieive the transaction hash, if it failed, you can fetch the error.

try {
    const response = await wallet.transferPWR(recipientAddress, BigInt(pwrAmount));

    if (response.sucess) {
        console.log('Transcation Hash: ' + response.hash);
    }
} catch (e) {
    console.log(e);
}

Send data to a vida:

const vidaId = BigInt('123');
const data = new TextEncoder().encode('Hello world');

try {
    const response = await wallet.sendVidaData(vidaId, data);
    if (response.sucess) {
        console.log('Transcation Hash: ' + response.hash);
    }
} catch (e) {
    console.log(e);
}

Other Static Calls

Get RPC Node Url:

Returns currently set RPC node URL.

const url = await pwrjs.getRpcNodeUrl();

Get Fee Per Byte:

Gets the latest fee-per-byte rate.

const fee = await pwrjs.getFeePerByte();

Get Balance Of Address:

Gets the balance of a specific address.

const balance = await pwrjs.getBalanceOfAddress('0x...');

Get Nonce Of Address:

Gets the nonce/transaction count of a specific address.

const nonce = await pwrjs.getNonceOfAddress('0x...');

Broadcast Txn:

Broadcasts a signed transaction to the network.

const signedTransaction = '...';
const broadcast = await pwrjs.broadcastTxn(signedTransaction);

✏️ Contributing

If you consider to contribute to this project please read CONTRIBUTING.md first.

You can also join our dedicated channel for pwrjs on the PWR Chain Discord

📜 License

Copyright (c) 2025 PWR Labs

Licensed under the MIT license.