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

@altheia-xyz/recover

v0.0.2

Published

AI agents you can fire — operator recovery CLI. Withdraws every asset from an Altheia agent's smart-account back to your wallet using only your local keypair. No Altheia backend required.

Downloads

220

Readme

@altheia-xyz/recover

AI agents you can fire — operator recovery CLI.

📖 Docs: docs.altheia.xyz

Withdraws every asset from an Altheia agent's Swig smart-account back to your operator wallet, using only your local keypair. Does NOT talk to the Altheia backend at all. Proves the non-custody claim end-to-end: even if altheia.xyz disappeared overnight, an operator with their keypair can recover their funds in one command.

Use

npx -y @altheia-xyz/recover \
  --keypair-path ~/.config/solana/id.json \
  --swig-account <Swig PDA from your dashboard> \
  --cluster mainnet

What it does, in order:

  1. Reads your keypair from --keypair-path
  2. Connects to your --rpc-url (default: mainnet public RPC)
  3. Fetches the Swig smart-account on-chain
  4. Finds the Role 0 (root) authority that matches your keypair
  5. Calls Swig's built-in getTransferAssetsInstructions(role=0) (the TransferAssetsV1 helper) — this transfers every SPL token in the smart-account back to the role's authority, which is your wallet
  6. Signs locally with your keypair, sends to Solana, prints the Solscan link

Total HTTP calls to non-Solana hosts: zero. No altheia.xyz, no telemetry, no backdoor.

Where the inputs come from

| Argument | Where to find it | |---|---| | --keypair-path | Your operator Phantom wallet, exported as a Solana CLI keypair JSON (solana-keygen export-from-phantom or write the byte array yourself). This MUST be the wallet you registered the agent with — it's Role 0 on the Swig smart-account. | | --swig-account | altheia.xyz/agents/<pda> → On-chain references → "Swig smart-account" address. Or: agent.substrate_account_pubkey from the API. | | --rpc-url | Any Solana RPC. Helius, Triton, or the public default. |

Why this exists

The Altheia trust pitch is "AI agents you can fire." The implicit promise: you can always get your money back, regardless of what happens to us. This CLI is the proof. If you're an operator evaluating Altheia and the question "can they hold me hostage?" matters to you, this binary is your answer.

Run it as a dry-run first to confirm the tx shape:

npx -y @altheia-xyz/recover --keypair-path ~/.config/solana/id.json --swig-account <addr> --dry-run

What it can NOT do

  • Recover SOL held by the Swig PDA itself (account rent). For that you'd close the swig entirely via getCloseSwigInstructions — separate operation, distinct from "withdraw all assets."
  • Recover funds from sub-accounts. Sub-accounts have their own withdraw helpers (getWithdrawFromSubAccount*Instructions).
  • Help if your operator wallet keypair is lost. There is no recovery from a lost root authority — that's how Solana wallets work.

Status

v0.0.1 — alpha. Same trust model as @altheia-xyz/sdk.

License

Apache-2.0.