Summary
Upgrade @pkcprotocol/pkc-js from 0.0.40 to 0.0.41 and expose the new community export API (pkcprotocol/pkc-js#100) in the CLI.
Plan
1. Upgrade pkc-js
npm install --save-exact @pkcprotocol/pkc-js@0.0.41
2. New command: bitsocial community export [ADDRESS]
Triggers an export on the RPC server, streams progress, downloads the finished SQLite snapshot via GET /exports/<exportId>, and verifies its sha256 against the export record.
Flags:
ADDRESS arg + --name / --publicKey — community lookup (same trio as community get)
-o, --path — local destination file (default: ./<address>.sqlite)
--includePrivateKey — ask the RPC server to include the community signer's private key in the export
--force — overwrite an existing file at the destination
--quiet — suppress progress output (only print the final file path)
- Ctrl+C cancels the in-flight export via
cancelExport()
3. New daemon flag: --allowPrivateKeyExport
Server-side policy passed to the pkc-js WS server options, controlling whether RPC clients may request includePrivateKey exports.
4. Tests
- Export command: happy path, lookup variants,
--includePrivateKey, overwrite protection / --force, sha256 mismatch failure
- Daemon flag plumbing
Progress
Summary
Upgrade
@pkcprotocol/pkc-jsfrom 0.0.40 to 0.0.41 and expose the new community export API (pkcprotocol/pkc-js#100) in the CLI.Plan
1. Upgrade pkc-js
npm install --save-exact @pkcprotocol/pkc-js@0.0.412. New command:
bitsocial community export [ADDRESS]Triggers an export on the RPC server, streams progress, downloads the finished SQLite snapshot via
GET /exports/<exportId>, and verifies its sha256 against the export record.Flags:
ADDRESSarg +--name/--publicKey— community lookup (same trio ascommunity get)-o, --path— local destination file (default:./<address>.sqlite)--includePrivateKey— ask the RPC server to include the community signer's private key in the export--force— overwrite an existing file at the destination--quiet— suppress progress output (only print the final file path)cancelExport()3. New daemon flag:
--allowPrivateKeyExportServer-side policy passed to the pkc-js WS server options, controlling whether RPC clients may request
includePrivateKeyexports.4. Tests
--includePrivateKey, overwrite protection /--force, sha256 mismatch failureProgress
community exportcommanddaemon --allowPrivateKeyExportflag