@spectratools/assembly-cli 0.6.0 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -0
- package/dist/cli.js +1009 -283
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -33,6 +33,29 @@ assembly-cli mcp add
|
|
|
33
33
|
| `ABSTRACT_RPC_URL` | No | Abstract RPC URL override (default from package client) |
|
|
34
34
|
| `ASSEMBLY_INDEXER_URL` | No | Optional member snapshot endpoint for `members list` (falls back to on-chain `Registered` events with a warning if unavailable) |
|
|
35
35
|
|
|
36
|
+
## Shared tx integration pattern (`@spectratools/tx-shared`)
|
|
37
|
+
|
|
38
|
+
`assembly-cli` write flows are powered by `@spectratools/tx-shared` (`executeTx` lifecycle + structured `TxError`s).
|
|
39
|
+
|
|
40
|
+
If you're building a consumer CLI command (or extending Assembly write behavior), use the shared pattern:
|
|
41
|
+
|
|
42
|
+
1. Parse signer flags/env via `toSignerOptions(...)`
|
|
43
|
+
2. Resolve signer with `resolveSigner(...)`
|
|
44
|
+
3. Build write request (`address`, `abi`, `functionName`, `args`/`value`)
|
|
45
|
+
4. Execute with `executeTx(...)` and handle `dryRun` + `TxError.code`
|
|
46
|
+
|
|
47
|
+
Reference wiring:
|
|
48
|
+
|
|
49
|
+
- Assembly example: [`src/examples/tx-shared-register.ts`](./src/examples/tx-shared-register.ts)
|
|
50
|
+
- tx-shared docs: [`../tx-shared/README.md`](../tx-shared/README.md)
|
|
51
|
+
- tx-shared assembly-style example: [`../tx-shared/src/examples/assembly-write.ts`](../tx-shared/src/examples/assembly-write.ts)
|
|
52
|
+
|
|
53
|
+
Current `assembly-cli` write commands require `PRIVATE_KEY`, but tx-shared supports broader provider setup for consumer CLIs:
|
|
54
|
+
|
|
55
|
+
- private key (`PRIVATE_KEY`)
|
|
56
|
+
- keystore (`--keystore` + `--password` or `KEYSTORE_PASSWORD`)
|
|
57
|
+
- Privy (`PRIVY_APP_ID`, `PRIVY_WALLET_ID`, `PRIVY_AUTHORIZATION_KEY`; implementation tracked in [#117](https://github.com/spectra-the-bot/spectra-tools/issues/117))
|
|
58
|
+
|
|
36
59
|
## Command Group Intent Summary
|
|
37
60
|
|
|
38
61
|
- `members` — Membership state, counts, and registry fee settings
|