Skip to content

Updates the `wdk-wallet-spark` docs to align with release `beta.7` + Audit

Viet Tan Tran requested to merge github/fork/ihsraham/fix/spark-audit-beta-7 into main

Created by: ihsraham

Description

Updates the wdk-wallet-spark documentation to align with release v1.0.0-beta.7 and addresses existing quality issues.

Release Based Changes (v1.0.0-beta.7)

Updates reflecting changes in the SDK source code:

  • Moved verify method: Moved from WalletAccountSpark to WalletAccountReadOnlySpark to match SDK refactor.

  • Updated exitSpeed default: Updated documentation (types) to reflect that CoopExitRequest.exitSpeed defaults to 'MEDIUM'.

General Documentation Improvements

Fixes for issues found during verification (correcting previous documentation state):

  • API Reference (api-reference.md):

    • Added WalletAccountReadOnlySpark Section: Added dedicated section for read-only account methods (e.g., verify, getTransactionReceipt), aligning with EVM documentation style.
  • Usage Guide (usage.md):

    • Added ESM Hint: Added warning about ES Module syntax requirements.
    • Fixed Invalid Seed Phrases: Replaced placeholder phrases ('your twelve word seed phrase here') with valid BIP-39 test mnemonics.
    • Fixed Syntax Errors: Resolved duplicate const wallet variable declaration in the "Quick Start" example.
    • Fixed Type Errors: Corrected BigInt vs Number division in balance calculation examples.
  • Configuration (configuration.md):

    • Fixed Missing Definitions: Added missing seedPhrase definition to the "Complete Configuration Example".
  • README (README.md):

    • Added Installation Instructions: Added npm install command (previously missing).

Verification

  • Manual Verification: All code examples in usage.md and configuration.md verified to work successfully with blind copy-paste.
  • API Coverage: Verified documentation against @tetherto/wdk-wallet-spark SDK types via runtime inspection to ensure all exported methods are documented.

Merge request reports