Skip to content
This repository was archived by the owner on Jun 12, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
71ea1a4
fix(execute): make per-instruction retry state-aware after confirm ti…
bguillaumat-squads Jun 11, 2026
1b2589b
fix(import): parse raw import as wire transaction, not bare message
bguillaumat-squads Jun 11, 2026
6fde15c
fix(nft): derive metadata PDA in incoming authority retry pass
bguillaumat-squads Jun 11, 2026
5d71b8e
fix(assets): show wrapped SOL token accounts in vault inventory
bguillaumat-squads Jun 11, 2026
e1f5d6d
feat(menu): add direct open-by-address path for multisigs
bguillaumat-squads Jun 11, 2026
f863f4c
fix(nft): write bulk authority logs to a temp dir, not cwd
bguillaumat-squads Jun 11, 2026
6fc6dbe
fix(ux): state activate+approve side effects in helper prompts
bguillaumat-squads Jun 11, 2026
80d3b61
fix(packaging): allowlist published files and rebuild bin/ on prepack
bguillaumat-squads Jun 11, 2026
cb9c3fb
fix(integers): check integers for authority
sean-sqds Jun 11, 2026
0ba4003
fix(import): explicit approval for imports
sean-sqds Jun 11, 2026
09f4e1b
fix(confirmation): adjusted to confirmed for state change
sean-sqds Jun 11, 2026
28ad182
fix(authority-batches): fix for index check
sean-sqds Jun 11, 2026
af2eeed
fix(members): better scan for multisig members and direct access
sean-sqds Jun 11, 2026
2287c40
fix(nfts): safesign passes through failed nft authority transfers
sean-sqds Jun 11, 2026
c9c7195
fix(refresh): post-create refreshes stale state
sean-sqds Jun 11, 2026
8707397
fix(creator): display the creator
sean-sqds Jun 11, 2026
c0b38da
fix(threshold): enforce integer threshold input in create and change …
bguillaumat-squads Jun 11, 2026
c0b9ac0
fix(settings): bundle approval atomically to prevent PDA redirect
bguillaumat-squads Jun 11, 2026
c96e5eb
fix(assets): tag token label provenance in vault inventory
bguillaumat-squads Jun 11, 2026
4eec863
feat(vault/nft): let operators pick the authority index
bguillaumat-squads Jun 11, 2026
ad7c62e
fix(settings): reject semantic no-op member/threshold proposals
bguillaumat-squads Jun 11, 2026
e2ceaec
fix(program): verified on-chain state rather than a precomputed address
sean-sqds Jun 11, 2026
4ac7a71
fix(nfts): discerment via metaplex
sean-sqds Jun 11, 2026
5c45d33
fix(import): byte size and better builder handling
sean-sqds Jun 11, 2026
56dfcda
fix(confirm): better logic for failed tx
sean-sqds Jun 11, 2026
0c7c4db
fix(resume): partially executed transactions
sean-sqds Jun 11, 2026
6772a17
Merge pull request #43 from Squads-Protocol/feature/mul-782-squa1-18-…
sean-sqds Jun 11, 2026
6a35604
Merge pull request #50 from Squads-Protocol/feature/mul-792-squa1-24-…
sean-sqds Jun 11, 2026
8e95422
Merge pull request #37 from Squads-Protocol/feature/mul-771-squa1-26-…
sean-sqds Jun 11, 2026
34ebc78
Merge pull request #40 from Squads-Protocol/feature/mul-775-squa1-9-m…
sean-sqds Jun 11, 2026
895c30a
Merge pull request #36 from Squads-Protocol/feature/mul-781-squa1-23-…
sean-sqds Jun 11, 2026
1426e59
Merge pull request #49 from Squads-Protocol/feature/mul-790-squa1-8-p…
sean-sqds Jun 11, 2026
04bf78d
Merge pull request #41 from Squads-Protocol/feature/mul-779-squa1-11-…
sean-sqds Jun 11, 2026
f7d6259
Merge pull request #42 from Squads-Protocol/feature/mul-784-squa1-10-…
sean-sqds Jun 11, 2026
bf23be8
Merge pull request #38 from Squads-Protocol/feature/mul-786-squa1-21-…
sean-sqds Jun 11, 2026
cd4447d
Merge pull request #30 from Squads-Protocol/feature/mul-777-squa1-19-…
sean-sqds Jun 11, 2026
0e4c31b
Merge pull request #33 from Squads-Protocol/feature/mul-778-squa1-5-b…
sean-sqds Jun 11, 2026
eb400f5
Merge pull request #34 from Squads-Protocol/feature/mul-774-squa1-4-h…
sean-sqds Jun 11, 2026
67572fc
Merge pull request #53 from Squads-Protocol/feature/mul-798-squa1-22-…
sean-sqds Jun 11, 2026
1f98efd
Merge pull request #47 from Squads-Protocol/feature/mul-797-squa1-25-…
sean-sqds Jun 11, 2026
d9833b7
Merge pull request #28 from Squads-Protocol/feature/mul-783-squa1-14-…
sean-sqds Jun 11, 2026
394d048
Merge pull request #48 from Squads-Protocol/feature/mul-795-squa1-15-…
sean-sqds Jun 11, 2026
6a3c4e2
Merge branch 'major-v3-cli-patch-2026' into feature/mul-796-squa1-12-…
sean-sqds Jun 11, 2026
151957b
Merge pull request #44 from Squads-Protocol/feature/mul-796-squa1-12-…
sean-sqds Jun 11, 2026
4c3f28a
Merge branch 'major-v3-cli-patch-2026' into feature/mul-780-squa1-6-w…
sean-sqds Jun 11, 2026
885027e
Merge pull request #31 from Squads-Protocol/feature/mul-780-squa1-6-w…
sean-sqds Jun 11, 2026
99abc32
Merge pull request #46 from Squads-Protocol/feature/mul-799-squa1-3-v…
sean-sqds Jun 11, 2026
863a7b2
Merge branch 'major-v3-cli-patch-2026' into feature/mul-773-squa1-2-i…
sean-sqds Jun 11, 2026
5eef7fd
Merge pull request #35 from Squads-Protocol/feature/mul-773-squa1-2-i…
sean-sqds Jun 11, 2026
c0f0903
Merge pull request #29 from Squads-Protocol/feature/mul-776-squa1-16-…
sean-sqds Jun 11, 2026
8270c19
Merge branch 'major-v3-cli-patch-2026' into feature/mul-791-squa1-13-…
sean-sqds Jun 11, 2026
88efe99
Merge pull request #45 from Squads-Protocol/feature/mul-791-squa1-13-…
sean-sqds Jun 11, 2026
8576e04
Merge branch 'major-v3-cli-patch-2026' into feature/mul-785-squa1-1-p…
sean-sqds Jun 11, 2026
4e4b957
Merge pull request #32 from Squads-Protocol/feature/mul-785-squa1-1-p…
sean-sqds Jun 11, 2026
c8ceedb
Merge branch 'major-v3-cli-patch-2026' into feature/mul-772-squa1-20-…
sean-sqds Jun 11, 2026
53cc8b8
Merge pull request #39 from Squads-Protocol/feature/mul-772-squa1-20-…
sean-sqds Jun 11, 2026
aec0584
Merge branch 'major-v3-cli-patch-2026' into feature/mul-793-squa1-7-i…
sean-sqds Jun 11, 2026
fd668ba
Merge pull request #52 from Squads-Protocol/feature/mul-793-squa1-7-i…
sean-sqds Jun 11, 2026
2bb3405
fix(merge): resolve conflict
sean-sqds Jun 11, 2026
e562609
fix(cleanup): fix post PR noise
sean-sqds Jun 11, 2026
b4914e9
feat(updates): final pass and cleanup
sean-sqds Jun 11, 2026
a3eb063
feat(README): added extra information
sean-sqds Jun 11, 2026
4cb6768
feat(README): some extra info on the nft authority transfers
sean-sqds Jun 11, 2026
a2c6ece
chore(ci): bump to 22
sean-sqds Jun 11, 2026
711d92b
chore(deps): update from socket
sean-sqds Jun 11, 2026
1ad5dcb
chore(deps): update dependencies
sean-sqds Jun 11, 2026
31b49cf
fix(deps): dependency cleanup
sean-sqds Jun 12, 2026
562a655
chore(version): version bump
sean-sqds Jun 12, 2026
bc618e1
chore(readme): note about deprecation
sean-sqds Jun 12, 2026
155f257
chore: release 3.0.0
sean-sqds Jun 12, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: ci
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
- name: Install dependencies
run: npm ci
- name: Typecheck
run: npm run typecheck
- name: Lint
run: npm run lint
- name: Build from clean source
run: npm run build
# Runs prepack (verify-clean + rebuild) and validates the tarball contents
# against the committed source — the shipped bin/ is rebuilt here from a
# clean checkout, so published installs can't ship untracked local output.
- name: Verify package builds from committed source
run: npm pack --dry-run
11 changes: 5 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,15 @@
name: release-please
on:
push:
branches:
- main
pull_request:
branches:
- main
name: release-please
permissions:
contents: write
pull-requests: write
jobs:
release-please:
runs-on: ubuntu-latest
steps:
- uses: google-github-actions/release-please-action@v3
- uses: googleapis/release-please-action@v4
with:
release-type: node
package-name: release-please-action
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,7 @@ bin/
.idea/

transfer.json
yarn-error.log
yarn-error.log

authority-out-*.txt
authority-out-mints-*.json
142 changes: 132 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
> [!WARNING]
> **This package is deprecated and no longer actively maintained.** It remains functional for operating existing Squads **v3** multisigs, but no new features will be added. For current Squads tooling, see [squads.so](https://squads.so).

```
_____ ____ __ __ ___ ____ _____
/ ___/ / __ \ / / / / / | / __ \ / ___/
Expand All @@ -8,16 +11,135 @@
```

## Squads v3 CLI
Interact with Squads Protocol v3 via simple CLI.

An interactive, menu-driven CLI for operating [Squads Protocol v3](https://squads.so) multisigs from the terminal — create multisigs, review and vote on transactions, manage members and thresholds, transfer program upgrade authority, and run bulk NFT authority migrations.

> **Note:** This CLI targets the Squads **v3** program. It is a hands-on operator tool: every state-changing action is confirmed interactively before anything is signed or sent.

### Requirements
Nodejs version >= 16
### Installing the CLI tool
`npm install -g @sqds/cli`

### Running the tool
Running the simple command will start the tool and ask a few setup questions for the wallet and the network cluster.\
`squads-cli`
- Node.js **>= 16**
- npm **>= 8.19.2**
- A funded Solana wallet (keypair file or Ledger) to pay transaction fees and rent

### Installing

```sh
npm install -g @sqds/cli
```

Or run it without installing:

```sh
npx @sqds/cli
```

### Quick start

```sh
squads-cli
```

On launch the tool asks two setup questions:

1. **Wallet** — path to a Solana keypair file, or a Ledger device (see below). Press Enter to use the default `~/.config/solana/id.json`.
2. **Cluster** — choose `mainnet-beta`, `devnet`, `localnet`, or enter a custom RPC URL.

From there you navigate the menus with the arrow keys and Enter.

### Command-line flags

Any flag you pass skips the matching startup prompt. All are optional.

| Flag | Description |
| --- | --- |
| `--cluster <value>` | `mainnet-beta`, `devnet`, `localnet`, or a full `https://` RPC URL. Skips the cluster prompt. |
| `--computeUnitPrice <microLamports>` | Adds a priority fee (micro-lamports per compute unit) to every transaction this CLI signs. |
| `--programId <pubkey>` | Override the Squads v3 multisig program ID (advanced / non-default deployments). |
| `--programManagerId <pubkey>` | Override the program-manager program ID. |
| `--txMetaProgramId <pubkey>` | Override the transaction-metadata program ID used by bulk flows. |
| `--version`, `-v` | Print the installed CLI version. |
| `--help` | Print help. |

```sh
# Connect straight to mainnet with a priority fee
squads-cli --cluster https://api.mainnet-beta.solana.com --computeUnitPrice 5000
```

### Wallet options

- **Keypair file** — enter the path to a standard Solana keypair JSON (e.g. `~/.config/solana/id.json`). This wallet pays fees and rent and casts your approvals.
- **Ledger** — enter a `usb://ledger` URL. Plug in and unlock the device with the Solana app open first. The prefix is case-insensitive, and a derivation path may be appended to select a specific account.

### What you can do

- **Find your multisigs** — `View my Multisigs` lists multisigs that include your wallet. Because membership is permissionless, this discovered list can contain decoy/spam entries; use **Open multisig by address** to go straight to a specific multisig you trust.
- **Create a multisig** — set the create key, members, and approval threshold.
- **Vault & assets** — view SOL, wrapped SOL, and SPL token balances held by a vault. You can choose which **authority index** (vault) to inspect; index 1 is the default vault.
- **Transactions** — create a draft for a chosen authority, or **import** a base58-serialized transaction. The review screen shows the creator and decodes every attached instruction (program, accounts, data) so you can see exactly what you're approving. Actions: **Approve**, **Activate**, **Reject**, **Cancel**, **Add instruction**, and **Execute**.
- **Settings** — add a member, remove a member, or change the approval threshold. No-op proposals (adding an existing member, or re-setting the current threshold) are rejected up front because they would still advance the config and invalidate other pending settings proposals.
- **Program upgrade authority** — stage a safe transfer of a program's upgrade authority into or out of the vault.
- **Validator withdraw authority** — stage a transfer of a vote account's withdraw authority.
- **Bulk NFT authority migration** — move metadata update authority for many mints into or out of a vault, with an optional `safeSign` co-signer. Progress logs are written to a temporary directory (not your working directory).
- **Create ATA** — create an associated token account owned by a vault.

### NFT authority migration & the mint list file

The bulk NFT flows operate on a list of mints you supply as a `.json` file (the prompt asks for the file location). The format is a **plain JSON array of base58 mint address strings** — nothing more:

```json
[
"5j8...firstMintAddress",
"9Wg...secondMintAddress",
"Fz3...thirdMintAddress"
]
```

Rules the loader enforces:

- It must be a JSON **array** (not an object, not a CSV, not newline-delimited).
- Each entry is a **non-empty string** that is a valid **base58 public key**. Any entry that isn't aborts the load and names the offending index.
- Use the **mint addresses** themselves — not metadata PDAs and not keypairs. The CLI derives each mint's Metaplex metadata PDA for you.
- Duplicate entries are de-duplicated automatically.

There are two directions, and they behave differently:

- **Into the vault (incoming)** — used when your *connected wallet* is the current update authority. The CLI first validates that every mint's metadata exists and that your wallet really is its current update authority, shows the exact metadata PDAs to be reassigned, then signs the updates directly with your wallet. Mints your wallet doesn't control are reported up front rather than failing mid-run.
- **Out of the vault (outgoing)** — used when the *vault* is the current authority. Because the vault can only act through governance, this stages multisig transactions (batched across the mint list) that members then approve and execute. An optional **`safeSign`** mode adds the new authority as a required co-signer, and that co-signer is preserved on retries.

Progress and results are written to a log file in a temporary directory (not your working directory), so a large run can be audited afterward.

### Executing transactions: what to expect

The CLI executes a transaction in the most efficient way that still fits Solana's transaction size limit:

- **Atomic** — if all the proposal's instructions fit in a single transaction, they execute together, all-or-nothing.
- **Sequential (packed)** — if they don't fit, the CLI asks you to confirm non-atomic execution, then runs the instructions across the fewest transactions that fit. In this mode an earlier batch can land on-chain even if a later one fails, leaving the proposal **partially executed**.

If execution stops partway, the review screen labels the proposal as partially executed and shows how many instructions remain. Re-running **Execute** resumes from the next un-executed instruction. Multisig settings/governance proposals (authority index 0) always execute atomically.

### Safety notes

- **Send assets only to the vault address** shown in the header — never to the multisig account address.
- **Review instructions before approving or executing.** The review screen decodes them for you; treat any imported transaction as untrusted until you've inspected it.
- The discovered multisig list is **permissionless** — anyone can create a multisig that names your wallet. Prefer **Open multisig by address** for anything sensitive.

### Development

```sh
npm install
npm run build # compile TypeScript to bin/
npm run typecheck # tsc --noEmit
npm run lint # eslint over src/
```

The published entrypoint (`bin/`) is rebuilt from source on `prepack`, and `npm run verify-clean` fails packing/publishing if tracked source has uncommitted changes — so a published build always matches reviewed source.

### Links

- Squads Protocol: https://squads.so
- Source & issues: https://github.com/squads-protocol/squads-cli

### Disclaimer

### Cluster Option
Providing the cluster will bypass the question upon startup\
`squads-cli --cluster https://api.mainnet-beta.solana.com`
This tool signs and submits real on-chain transactions that can move funds and change control of programs and accounts. Use at your own risk, double-check every prompt, and test on `devnet` first when in doubt.
Loading
Loading