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

@azguardwallet/aztec-wallet

v3.0.0-devnet.20251212

Published

Azguard Wallet client fully compatible with Aztec.js' Wallet interface

Downloads

37

Readme

@azguardwallet/aztec-wallet

GitHub License NPM Version NPM Downloads

Azguard Wallet client fully compatible with Aztec.js' Wallet interface, enabling seamless integration.

How to use

Install the package:

npm install @azguardwallet/aztec-wallet

Connect the wallet:

import { AztecWallet } from "@azguardwallet/aztec-wallet";

// the simplest way
const wallet = await AztecWallet.connect();

// or you can additionally provide the dapp metadata and the chain
const wallet = await AztecWallet.connect(
    {
        name: "My Dapp",
        description: "The best dapp in the world",
        logo: "...",
        url: "..."
    },
    "devnet" // or "sandbox", or CAIP-string like "aztec:1654394782"
);

Then use this wallet for interaction with Aztec.js:

import { AztecAddress } from '@aztec/aztec.js/addresses';
import { SponsoredFeePaymentMethod } from '@aztec/aztec.js/fee';
import { createAztecNodeClient } from '@aztec/aztec.js/node';
import { TokenContract, TokenContractArtifact } from '@aztec/noir-contracts.js/Token';

const accounts = await wallet.getAccounts();
const address = accounts[0].item;

const tokenAddress = AztecAddress.fromString("0x...");
const tokenContract = await TokenContract.at(tokenAddress, wallet);

// register token contract in user's PXE

const node = createAztecNodeClient("https://next.devnet.aztec-labs.com");
const tokenInstance = await node.getContract(tokenAddress);
await wallet.registerContract(tokenInstance, TokenContractArtifact);

// get token private balance

const prvBalance = await tokenContract.methods
    .balance_of_private(address)
    .simulate({from: address});

console.log("Private balance", prvBalance);

// get token public balance

const pubBalance = await tokenContract.methods
    .balance_of_public(address)
    .simulate({from: address});

console.log("Public balance", pubBalance);

// send token

const feeOptions = {
    paymentMethod: new SponsoredFeePaymentMethod(
        AztecAddress.fromString("0x..."),
    ),
};

const txReceipt = await tokenContract.methods
    .transfer(AztecAddress.fromString("0x..."), 100000000n)
    .send({from: address, fee: feeOptions})
    .wait();

console.log("Tx hash", txReceipt.txHash);

That's pretty much it! See more Aztec.js examples at https://docs.aztec.network.

Connection state

When Azguard user confirms connection from a dapp (AztecWallet.connect()), a dapp session is opened, and while this session is active, the dapp is allowed to interact with the wallet. If the dapp session is expired or closed (either by the dapp or by the user), the interaction is no longer allowed.

Even though the AztecWallet client reconnects automatically, you might want to additionally track the connection state. You can do the following:

// connect the wallet
// (it's lazily called under the hood, so you don't have to call it manually,
// unless you want to connect immediately)
await wallet.connect();

// check if the wallet is connected
console.log(wallet.connected);

// track connection/disconnection events
wallet.onConnected.addHandler(() => console.log("Azguard connected"));
wallet.onDisconnected.addHandler(() => console.log("Azguard disconnected"));

// in the end you can disconnect and close the session
await wallet.disconnect();

Support channels

If you have any questions, feel free to contact us in:

  • Telegram: https://t.me/azguardwallet
  • Twitter: https://twitter.com/AzguardWallet

Cheers! 🍺