diff --git a/examples/build-moderation-log/.env.example b/examples/build-moderation-log/.env.example new file mode 100644 index 0000000..1501bab --- /dev/null +++ b/examples/build-moderation-log/.env.example @@ -0,0 +1,6 @@ +# Stellar Testnet Secret Key for signing audit receipts (starts with S) +# Generate one with: node -e "const { Keypair } = require('@stellar/stellar-sdk'); console.log(Keypair.random().secret())" +STELLAR_SECRET_KEY=SXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + +# Testnet Audit Node URL (public testnet, free, no API key required) +NIRIUM_NODE_URL=https://nirium-agent.fly.dev diff --git a/examples/build-moderation-log/.gitignore b/examples/build-moderation-log/.gitignore new file mode 100644 index 0000000..aa0926a --- /dev/null +++ b/examples/build-moderation-log/.gitignore @@ -0,0 +1,4 @@ +node_modules/ +dist/ +.env +*.log diff --git a/examples/build-moderation-log/README.md b/examples/build-moderation-log/README.md new file mode 100644 index 0000000..b42de8d --- /dev/null +++ b/examples/build-moderation-log/README.md @@ -0,0 +1,191 @@ +# Build with Nirium: Discord/Telegram Moderation Log Bot with Audit Trail Receipts + +A community moderation log bot that anchors every moderation action (warn, mute, message removal, kick, ban) to the **Nirium Audit Trail** testnet. Every decision receives an immutable cryptographic receipt so community members, appeal reviewers, and server owners can independently prove a decision was not rewritten or backdated after the fact. + +--- + +## Cryptographic Guarantees & Privacy + +### 1. Zero Raw Personal Data (Hash-Only Anchoring) +IPFS content is permanently immutable and cannot be deleted. Anchoring cleartext user identifiers or chat messages would create irreversible privacy violations. + +To prevent this: +- **Moderator IDs**, **Target User IDs**, and **Message Content** are salted with a 32-byte cryptographically secure random salt and hashed with SHA-256 (`hashWithSalt(val, salt)`). +- The public audit anchor payload contains **only** the action type, public server ID, public action ID, timestamp, and salted hashes. +- Raw personal data **never** leaves the local environment or enters the IPFS network. + +### 2. Community Key Attestation +Every anchored moderation record is attested by the community's own Stellar keypair: +- Statement format: `nirium-audit-v1:` +- Signed with Ed25519 (`Keypair.sign()`) +- Tag format: `wave11-moderation-log` (starts with `wave11-` as required by Nirium Wave 11 standard) + +### 3. What a Receipt Proves (and What It Doesn't) +- **What it proves:** + 1. **Proof of Non-Tampering:** The exact moderation record (action, reason, target hash, message hash) existed at the recorded time and has not been altered, rewritten, or deleted. + 2. **Proof of Authority:** The decision was signed and authorized by the specific community Stellar public key (`G...`). +- **What it does NOT prove:** + 1. It does **not** prove that the moderator's accusation was objectively true or fair. + 2. `anchoredAt` is the Nirium audit node's clock, not an on-chain Stellar consensus ledger timestamp. + +--- + +## Live Testnet Demo Server Records + +A demonstration community server (`guild_nirium_community_demo`) was created with 5 real moderation actions anchored to `https://nirium-agent.fly.dev/api/audit/log`: + +| Action ID | Action | Target User Hash (Salted) | Anchored CID | SHA-256 Hash | Anchored At | +| :--- | :--- | :--- | :--- | :--- | :--- | +| `mod-mwscienp-12r7` | **WARN** | `e6e969019b8df790...` | [`QmUrJezMWZw15CF8tsj4ZW7917oxi18sTCYqkrgrrMHChS`](https://ipfs.io/ipfs/QmUrJezMWZw15CF8tsj4ZW7917oxi18sTCYqkrgrrMHChS) | `e27363ab85489af99ee8974006ae09bfffe6c7c87e621ba9c2a05dd19854e9df` | `2026-11-22T21:25:14.764Z` | +| `mod-mwscilt0-2fk3` | **MUTE** | `68c347f71b960c16...` | [`QmSZaccongZ7trqq1LvH7BTfVx7uRLx8atd5uD9VT2pFEd`](https://ipfs.io/ipfs/QmSZaccongZ7trqq1LvH7BTfVx7uRLx8atd5uD9VT2pFEd) | `af43ef9ed18bbec4426f338eea900fedc0b14475f0c411e62860654f62ab68dd` | `2026-11-22T21:25:23.911Z` | +| `mod-mwscisr0-lz61` | **MESSAGE_REMOVAL** | `265c71da517bc582...` | [`QmQci6hVcRAX8GX4hN5LCHi5RPqqramQkf3N1Gw5FMxQZa`](https://ipfs.io/ipfs/QmQci6hVcRAX8GX4hN5LCHi5RPqqramQkf3N1Gw5FMxQZa) | `c37195c36455532cf3155ab418a99511e07ef84dea80b87ead1df8f35e805ded` | `2026-11-22T21:25:32.890Z` | +| `mod-mwscizvx-jgih` | **KICK** | `3f2347eb10526e85...` | [`QmY6fcPmTDKJc2Pt6AGyZQd1mAnvfGi49QVho1PqRrHaoc`](https://ipfs.io/ipfs/QmY6fcPmTDKJc2Pt6AGyZQd1mAnvfGi49QVho1PqRrHaoc) | `fb9eba9cb4771ec9d448b8993a2f8e6d2af8edabb3859ec9ea03de5903de5b50` | `2026-11-22T21:25:42.089Z` | +| `mod-mwscj71d-lxhe` | **BAN** | `ab40d2bb4fbda7ff...` | [`QmRem2Trtiy1uwqKzc6ahR6cxRLL3WLt5GFE1Y6KLnidNq`](https://ipfs.io/ipfs/QmRem2Trtiy1uwqKzc6ahR6cxRLL3WLt5GFE1Y6KLnidNq) | `b50e79b2d89ba9caa256dbd3868b0bddf4e635c0d79277309118ce42cdeb6520` | `2026-11-22T21:25:51.358Z` | + +**Community Signer Public Key:** `GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE` + +--- + +## Live Verification Evidence (`nirium-cli verify`) + +All CIDs are verifiable using the standard CLI (`npx nirium-cli verify --hash `): + +### Action 1 (`warn`): +```bash +$ npx nirium-cli verify QmUrJezMWZw15CF8tsj4ZW7917oxi18sTCYqkrgrrMHChS --hash e27363ab85489af99ee8974006ae09bfffe6c7c87e621ba9c2a05dd19854e9df +🔍 Nirium Audit Verifier +CID: QmUrJezMWZw15CF8tsj4ZW7917oxi18sTCYqkrgrrMHChS +-------------------------------------------------- +✔ HASH: MATCH (e27363ab85489af9...) [hash-only] +✔ SIGNATURE: VALID (Signed by GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE) + Statement: nirium-audit-v1:e27363ab85489af99ee8974006ae09bfffe6c7c87e621ba9c2a05dd19854e9df + Agent ID: moderation-log-bot +-------------------------------------------------- +✅ VERIFICATION PASSED +``` + +### Action 2 (`mute`): +```bash +$ npx nirium-cli verify QmSZaccongZ7trqq1LvH7BTfVx7uRLx8atd5uD9VT2pFEd --hash af43ef9ed18bbec4426f338eea900fedc0b14475f0c411e62860654f62ab68dd +🔍 Nirium Audit Verifier +CID: QmSZaccongZ7trqq1LvH7BTfVx7uRLx8atd5uD9VT2pFEd +-------------------------------------------------- +✔ HASH: MATCH (af43ef9ed18bbec4...) [hash-only] +✔ SIGNATURE: VALID (Signed by GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE) + Statement: nirium-audit-v1:af43ef9ed18bbec4426f338eea900fedc0b14475f0c411e62860654f62ab68dd + Agent ID: moderation-log-bot +-------------------------------------------------- +✅ VERIFICATION PASSED +``` + +### Action 3 (`message_removal`): +```bash +$ npx nirium-cli verify QmQci6hVcRAX8GX4hN5LCHi5RPqqramQkf3N1Gw5FMxQZa --hash c37195c36455532cf3155ab418a99511e07ef84dea80b87ead1df8f35e805ded +🔍 Nirium Audit Verifier +CID: QmQci6hVcRAX8GX4hN5LCHi5RPqqramQkf3N1Gw5FMxQZa +-------------------------------------------------- +✔ HASH: MATCH (c37195c36455532c...) [hash-only] +✔ SIGNATURE: VALID (Signed by GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE) + Statement: nirium-audit-v1:c37195c36455532cf3155ab418a99511e07ef84dea80b87ead1df8f35e805ded + Agent ID: moderation-log-bot +-------------------------------------------------- +✅ VERIFICATION PASSED +``` + +### Action 4 (`kick`): +```bash +$ npx nirium-cli verify QmY6fcPmTDKJc2Pt6AGyZQd1mAnvfGi49QVho1PqRrHaoc --hash fb9eba9cb4771ec9d448b8993a2f8e6d2af8edabb3859ec9ea03de5903de5b50 +🔍 Nirium Audit Verifier +CID: QmY6fcPmTDKJc2Pt6AGyZQd1mAnvfGi49QVho1PqRrHaoc +-------------------------------------------------- +✔ HASH: MATCH (fb9eba9cb4771ec9...) [hash-only] +✔ SIGNATURE: VALID (Signed by GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE) + Statement: nirium-audit-v1:fb9eba9cb4771ec9d448b8993a2f8e6d2af8edabb3859ec9ea03de5903de5b50 + Agent ID: moderation-log-bot +-------------------------------------------------- +✅ VERIFICATION PASSED +``` + +### Action 5 (`ban`): +```bash +$ npx nirium-cli verify QmRem2Trtiy1uwqKzc6ahR6cxRLL3WLt5GFE1Y6KLnidNq --hash b50e79b2d89ba9caa256dbd3868b0bddf4e635c0d79277309118ce42cdeb6520 +🔍 Nirium Audit Verifier +CID: QmRem2Trtiy1uwqKzc6ahR6cxRLL3WLt5GFE1Y6KLnidNq +-------------------------------------------------- +✔ HASH: MATCH (b50e79b2d89ba9ca...) [hash-only] +✔ SIGNATURE: VALID (Signed by GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE) + Statement: nirium-audit-v1:b50e79b2d89ba9caa256dbd3868b0bddf4e635c0d79277309118ce42cdeb6520 + Agent ID: moderation-log-bot +-------------------------------------------------- +✅ VERIFICATION PASSED +``` + +--- + +## Tamper Detection Evidence (Editing Stored Record Fails) + +If a moderator or rogue database admin attempts to alter an action record after the fact (e.g. changing the reason or modifying the penalized user), the recomputed hash diverges from the immutable IPFS receipt, and `/check` immediately rejects it: + +```bash +$ node --import tsx src/cli.ts tamper mod-mwscj71d-lxhe "Changed ban reason secretly" +[TAMPERED] Modified reason for "mod-mwscj71d-lxhe": + Old Reason: "Malicious impersonation of Nirium core team administrators" + New Reason: "Changed ban reason secretly" +Run 'check mod-mwscj71d-lxhe' to demonstrate tamper detection! + +$ node --import tsx src/cli.ts check mod-mwscj71d-lxhe +Checking action "mod-mwscj71d-lxhe" against anchored receipt... + +[CHECK FAILED / TAMPERED] Action does not match receipt! + Action ID: mod-mwscj71d-lxhe + Error: TAMPERED: Stored record hash (bc462b4356b33c80...) differs from anchored receipt hash (b50e79b2d89ba9ca...) +``` + +--- + +## Quick Start & CLI Usage + +### 1. Installation +```bash +npm install +``` + +### 2. Configuration (`.env`) +```bash +cp .env.example .env +``` +Fill in your Stellar testnet secret key (`STELLAR_SECRET_KEY=S...`). If omitted, the CLI automatically generates a transient testnet keypair. + +### 3. Log a Moderation Action +```bash +node --import tsx src/cli.ts log ban discord_user_9921 "Severe spam in announcements" "Buy tokens at fake.xyz" +``` + +### 4. Check a Decision Against Its Receipt (`/check `) +```bash +node --import tsx src/cli.ts check mod-mwscienp-12r7 +``` + +### 5. List All Stored Actions +```bash +node --import tsx src/cli.ts list +``` + +### 6. Run Offline Automated Tests +Tests execute with 100% mocked network calls: +```bash +npm test +``` +``` +▶ Moderation Log Bot with Nirium Receipts (#381) + ✔ TC1 - hashes all personal data (user IDs, message content) before anchoring (80.3ms) + ✔ TC2 - signs statement nirium-audit-v1: with community Stellar key (10.9ms) + ✔ TC3 - enforces wave11- tag prefix (2.4ms) + ✔ TC4 - confirms a stored action against its receipt using checkAction (5.4ms) + ✔ TC5 - editing or tampering with the stored record fails /check verification (8.9ms) +✔ Moderation Log Bot with Nirium Receipts (#381) (109.4ms) +ℹ tests 5 +ℹ suites 1 +ℹ pass 5 +ℹ fail 0 +``` diff --git a/examples/build-moderation-log/package-lock.json b/examples/build-moderation-log/package-lock.json new file mode 100644 index 0000000..ff63ae7 --- /dev/null +++ b/examples/build-moderation-log/package-lock.json @@ -0,0 +1,3211 @@ +{ + "name": "nirium-build-moderation-log-example", + "version": "0.1.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "nirium-build-moderation-log-example", + "version": "0.1.0", + "license": "Apache-2.0", + "dependencies": { + "@stellar/stellar-sdk": "^14.5.0", + "dotenv": "^17.2.3", + "nirium": "^0.19.6", + "nirium-cli": "^3.2.4" + }, + "devDependencies": { + "@types/node": "^20.19.30", + "tsx": "^4.21.0", + "typescript": "^5.9.3" + }, + "engines": { + "node": ">=22.12.0" + } + }, + "node_modules/@adraffy/ens-normalize": { + "version": "1.11.1", + "resolved": "https://registry.npmjs.org/@adraffy/ens-normalize/-/ens-normalize-1.11.1.tgz", + "integrity": "sha512-nhCBV3quEgesuf7c7KYfperqSS14T8bYuvJ8PcLJp6znkZpFc0AuW4qBtr8eKVyPPe/8RSr7sglCWPU5eaxwKQ==", + "license": "MIT" + }, + "node_modules/@cfworker/json-schema": { + "version": "4.1.6", + "resolved": "https://registry.npmjs.org/@cfworker/json-schema/-/json-schema-4.1.6.tgz", + "integrity": "sha512-YzVGTHXf4bzlyAL5KAvHYCdNbbt6zM5cYkAgxqxQPDQM6aZ4ShIIN5yJ+6q7YeonnevxT8k/LmD2tJi/jOiKkg==", + "license": "MIT" + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.28.2.tgz", + "integrity": "sha512-XExcO+dvLKvVtNTibSTBej1NCAbaGhWn9Ww1ZPx80qsahhPFe/8jgWP0IchNe0F3HwkU7n8ejhH8bjonqht8mQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.28.2.tgz", + "integrity": "sha512-kXXoiPVVGQcnIYGOeaovwOURpniDBpSq4A03qkQ+BMQqtGG6HYap3xne9C1O1yo4TR3qxlCX5IqqmX6fFo2Lqg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.28.2.tgz", + "integrity": "sha512-5YfKeeI8qWfBZIX+u2xZC3Zlb3Os/gLS2sbEKM+I4ZOcsWmHS2WLysCcQZDAFRslDUU5Oiq44gf6PYN1vGwG5A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.28.2.tgz", + "integrity": "sha512-O387ite7SzUyCcy3JQX4P4bLtEA7bLLkx+esve5JHnyYfNTxcVpXZo9jhdB0lTKN44gztELTdU7nS8Nr16Fs1Q==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.28.2.tgz", + "integrity": "sha512-n4KqkOQrraxHJcgjM1RvwbigfQKIKJVpM7xp+KsxiyUSrRdIXnt73VhrPAx0fV44hgfmIVKjxMN9J1t5jySVkw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.28.2.tgz", + "integrity": "sha512-uq6suIWYP37qzGddBKPw5QEQPi6HiLGsO7UmkpfyaYNQ3D+rN6w6WfwH+nuqcGXWvawGwxOEroO4YGnFh95azw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.28.2.tgz", + "integrity": "sha512-n+I0BTSRIoy+d6RPKnEVwql5UwBJolytvY4mAOIEJorKlqgPII8ix6slVVrfZ5Tnj7glIZvloylbB/EJPMWEXw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.28.2.tgz", + "integrity": "sha512-78XJTJkvPs0kz2w61301PJjXl4g7q3JqiYMZ/M/yVI73EHBrCRTgkhu9oqG7vPqq+a/yadEW8aD+agKlk5xrmg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.28.2.tgz", + "integrity": "sha512-XlDnu2q5yoqems+xay6wSAcg9DDD7K9RLKZEBOMZm3ckNpJBvOX20tSfby8KfrrhINDyv9V2YVZKY/SpoGJI8w==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.28.2.tgz", + "integrity": "sha512-pW4AC0P3it8c7do9MVM4p51FzHzdM/TZrerurgRcHJ2WTa1VQ1CIq18xncfpBJw4ojkiZZrKW2yIBWBP92j6Ug==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.28.2.tgz", + "integrity": "sha512-CYbnj78HsIeA+DhgUKgFCfvNsTHFhMMrinUrMZpDXJXKN8T3XViTZ/+wtHeVxEWY8ewSzTFN+nRmSwO2tZaLUQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.28.2.tgz", + "integrity": "sha512-buwkd8nsph4R+ajRvw0qM5Hja/TXQow3ptzWO2EbG/cqcIkHloRrdlBtQlshyYGTNFvfkfJ5tpPLVkY4DtsPfQ==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.28.2.tgz", + "integrity": "sha512-ZVykbDyk7519VwiNb9Lcj9m8XM6v5V9uKPvrEMkkEedVewf+0itkhahp4HDpgERXhwLRpWFypsGbG/J8s0QjJA==", + "cpu": [ + "mips64el" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.28.2.tgz", + "integrity": "sha512-CAXl+Dtd9UUuJd8pKKdwh6MLm3MUMiqMPmhZ3tTSXPqfyQ3vDl6R5hZdZ/kYojK4ofXtdfSv1tFq8XzWx3heNQ==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.28.2.tgz", + "integrity": "sha512-GeXCej4IQtU1B+QlDV8W/RRvbzI3O/Stss+/bCXv4lZls5WGRtu2a+3JkA3i4qIUlMXpcHebWpF8AkJhATowuA==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.28.2.tgz", + "integrity": "sha512-3H1weTYZPxt/WOhByszQZybS9w5lKzUn1FDMsgEChbHWQwHYQQRfBxgCcZvPhjHfKyJjIievvMmEUawJrdY9Dg==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.28.2.tgz", + "integrity": "sha512-4xTZr1FUmSoQW4XIWmit3tzQrUTZM+N3P0XV8xROKYF50XfI7xeO90+1bZvNwxIufQ9hDQVRJH5YhgPVF8A/HQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.28.2.tgz", + "integrity": "sha512-sSATRjPeDBg3pdgHoQfoYBob11Kk1FGa9lui5RIHZCoCkJa9QKlvl3/vKz2usCmYYjs7ymJR/2Nnsqe+Hjt5nw==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.28.2.tgz", + "integrity": "sha512-lqnzCV+mM0gIADaKihiCg6ifgfU2L3h5E33rNQBN1Y4MaVGnzryzmvvf7UHxprpQdE8hpqLolJ9Rl+SkIRDpyw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.28.2.tgz", + "integrity": "sha512-AL2qJILH7lNjrDmCQDvdxMfAUIv8KMNZOvrwAQ8i8//ntL9FflhOyMJ8OZSMBb8/AWXe3/5v5S20y3zCoZWKoQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.28.2.tgz", + "integrity": "sha512-QtiuPytchRyC4rwUKhexJdQKvDuZ6hWloi3igqPQNUJCS1/v9EiO3UTOXR6A3FoMo4fnAKbWJdqaIwhOzh8qEw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openharmony-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.28.2.tgz", + "integrity": "sha512-WkhYDmpTjLvGlScA1rwjRUmhl4k8oXR3cIbtqWmELgU/dFeHHlEllxDvdWcNJV9rbzCexB5vz8gtNewWLgCT7Q==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.28.2.tgz", + "integrity": "sha512-GPMSkTOtMnv2U2F8gxe4Io6qmVs+YKyp832Etqqxr0hFngmXQ3rzwytelm3GIn7T4VviRUlf3sOgBOiTdvaf7g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.28.2.tgz", + "integrity": "sha512-PIhhEkE9uPBleRBrQEJpUn7MBnibZzbGzYWPmY3x+YoVg/95zbjB4CxPPOQ8l5tYYM4mMaCthF8/1DIfBQQyWQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.28.2.tgz", + "integrity": "sha512-YmJbfTlvU7Sdn9BB+4PRES4oB6pxgS37MAONj+hBr/cpXS1aBPKXxNnDbu+QCWPj0o9dgyxeq79g6c5P8KeuYA==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.28.2.tgz", + "integrity": "sha512-5ebpxr3nWMzrL/rnUI755Jkuee0bHL/Gq0WTF9lvcpv73wAp5eu8MfBUgWK9bhWvZjj7yX8etf/8tI8Ney695g==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@exodus/bytes": { + "version": "1.16.0", + "resolved": "https://registry.npmjs.org/@exodus/bytes/-/bytes-1.16.0.tgz", + "integrity": "sha512-IcpW84uEn3N7ETtNZMlxKhfl6Pec8rUNGOTBtWbK1FKhJxIFAptZyVrvVRVBimAJxJCgc3PxepxkdWWG4DVzfA==", + "license": "MIT", + "engines": { + "node": "^20.19.0 || ^22.12.0 || >=24.0.0" + }, + "peerDependencies": { + "@noble/hashes": "^1.8.0 || ^2.0.0" + }, + "peerDependenciesMeta": { + "@noble/hashes": { + "optional": true + } + } + }, + "node_modules/@modelcontextprotocol/server": { + "version": "2.0.0-alpha.4", + "resolved": "https://registry.npmjs.org/@modelcontextprotocol/server/-/server-2.0.0-alpha.4.tgz", + "integrity": "sha512-/KEo3ZJ50HlagHp0lz2vPgfBZFtXHu6zTBXT9XqPc+4O9i4+IbBVWKq/a9yAfv/ifp0u3+mRo8SUk5kMKzhN8A==", + "license": "MIT", + "dependencies": { + "zod": "^4.2.0" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/@noble/ciphers": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/@noble/ciphers/-/ciphers-1.3.0.tgz", + "integrity": "sha512-2I0gnIVPtfnMw9ee9h1dJG7tp81+8Ob3OJb3Mv37rx5L40/b0i7djjCVvGOVqc9AEIQyvyu1i6ypKdFw8R8gQw==", + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/curves": { + "version": "1.9.7", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.7.tgz", + "integrity": "sha512-gbKGcRUYIjA3/zCCNaWDciTMFI0dCkvou3TL8Zmy5Nc7sJ47a0jtOeZoTaMxkuqRo9cRhjOdZJXegxYE5FN/xw==", + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/ed25519": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/@noble/ed25519/-/ed25519-3.2.0.tgz", + "integrity": "sha512-criDgRlnUA09hchYrTy/JUWPIEap5rZxQe6wDWzRx51oWWpDRcUpuNzlgPxDJaOK6AsW9c0wKcj3rKRv6t+bPQ==", + "license": "MIT", + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scalar/openapi-types": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/@scalar/openapi-types/-/openapi-types-0.8.0.tgz", + "integrity": "sha512-WmaxVSfvY5K/TwcG2B2TU1WOe1As1uc2s7myswtP6dBlcjU3hM08SApxv/jmyGaCE8t4gO5BBhmHY4pDUfmr2g==", + "license": "MIT", + "engines": { + "node": ">=22" + } + }, + "node_modules/@scure/base": { + "version": "1.2.6", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.2.6.tgz", + "integrity": "sha512-g/nm5FgUa//MCj1gV09zTJTaM6KBAHqLN907YVQqf7zC49+DcO4B1so4ZX07Ef10Twr6nuqYEH9GEggFXA4Fmg==", + "license": "MIT", + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip32": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.7.0.tgz", + "integrity": "sha512-E4FFX/N3f4B80AKWp5dP6ow+flD1LQZo/w8UnLGYZO674jS6YnYeepycOOksv+vLPSpgN35wgKgy+ybfTb2SMw==", + "license": "MIT", + "dependencies": { + "@noble/curves": "~1.9.0", + "@noble/hashes": "~1.8.0", + "@scure/base": "~1.2.5" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip39": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.6.0.tgz", + "integrity": "sha512-+lF0BbLiJNwVlev4eKelw1WWLaiKXw7sSl8T6FvBlWkdX+94aGJ4o8XjUdlyhTCjd8c+B3KT3JfS8P0bLRNU6A==", + "license": "MIT", + "dependencies": { + "@noble/hashes": "~1.8.0", + "@scure/base": "~1.2.5" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@signinwithethereum/siwe": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/@signinwithethereum/siwe/-/siwe-4.2.1.tgz", + "integrity": "sha512-CQEQhCIgN9blil1YpaGR+wvGPdsBVK6zed5DBu03s1IdbSO3kA/n7Zp+SAkZGiHy3HY6OJm1Su0/Bd33vKK6nQ==", + "license": "Apache-2.0", + "dependencies": { + "@signinwithethereum/siwe-parser": "^4.2.1" + }, + "peerDependencies": { + "ethers": "^5.7.0 || ^6.13.0", + "viem": "^2.7.0" + }, + "peerDependenciesMeta": { + "ethers": { + "optional": true + }, + "viem": { + "optional": true + } + } + }, + "node_modules/@signinwithethereum/siwe-parser": { + "version": "4.2.1", + "resolved": "https://registry.npmjs.org/@signinwithethereum/siwe-parser/-/siwe-parser-4.2.1.tgz", + "integrity": "sha512-GAdwNiBaRpUMTiFfPrbQ3e/RBhPbEhRRN1sZmDMLgLEZuKqKwO7V0ksVzCerE9l8HFKTNw5R/q3kPDCWJRz4zA==", + "license": "Apache-2.0", + "dependencies": { + "@noble/hashes": "^1.7.0", + "apg-js": "^4.4.0" + } + }, + "node_modules/@stellar/js-xdr": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/@stellar/js-xdr/-/js-xdr-3.1.2.tgz", + "integrity": "sha512-VVolPL5goVEIsvuGqDc5uiKxV03lzfWdvYg1KikvwheDmTBO68CKDji3bAZ/kppZrx5iTA8z3Ld5yuytcvhvOQ==", + "license": "Apache-2.0" + }, + "node_modules/@stellar/stellar-base": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/@stellar/stellar-base/-/stellar-base-14.1.0.tgz", + "integrity": "sha512-A8kFli6QGy22SRF45IjgPAJfUNGjnI+R7g4DF5NZYVsD1kGf7B4ITyc4OPclLV9tqNI4/lXxafGEw0JEUbHixw==", + "deprecated": "This package is now rolled into @stellar/stellar-sdk. Please use @stellar/stellar-sdk to continue receiving updates and support.", + "license": "Apache-2.0", + "dependencies": { + "@noble/curves": "^1.9.6", + "@stellar/js-xdr": "^3.1.2", + "base32.js": "^0.1.0", + "bignumber.js": "^9.3.1", + "buffer": "^6.0.3", + "sha.js": "^2.4.12" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@stellar/stellar-sdk": { + "version": "14.6.1", + "resolved": "https://registry.npmjs.org/@stellar/stellar-sdk/-/stellar-sdk-14.6.1.tgz", + "integrity": "sha512-A1rQWDLdUasXkMXnYSuhgep+3ZZzyuXJKdt5/KAIc0gkmSp906HTvUpbT4pu+bVr41tu0+J4Ugz9J4BQAGGytg==", + "license": "Apache-2.0", + "dependencies": { + "@stellar/stellar-base": "^14.1.0", + "axios": "^1.13.3", + "bignumber.js": "^9.3.1", + "commander": "^14.0.2", + "eventsource": "^2.0.2", + "feaxios": "^0.0.23", + "randombytes": "^2.1.0", + "toml": "^3.0.0", + "urijs": "^1.19.1" + }, + "bin": { + "stellar-js": "bin/stellar-js" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@toon-format/toon": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/@toon-format/toon/-/toon-2.3.1.tgz", + "integrity": "sha512-sWqEMeAJGMda9qRrfPKrX3C4c33CO9SJuvJzzrcBEn5sbDB+k6pSLkDsfN0rVnLQwR97MV3sDgVbcxQNsq8xVw==", + "license": "MIT" + }, + "node_modules/@types/json-schema": { + "version": "7.0.15", + "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", + "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", + "license": "MIT" + }, + "node_modules/@types/node": { + "version": "20.19.43", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.19.43.tgz", + "integrity": "sha512-6oYBAi5ikg4Pl+kGsoYtawUMBT2zZMCvPNF7pVLnHZfd1zf38DRiWn/gT01RYCdUqkv7Fhr+C9ot4/tb+2sVvA==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@x402/core": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@x402/core/-/core-2.32.0.tgz", + "integrity": "sha512-HyS8vbaR3XP79EIATKGMt8eL0Ql46yrfVDrtv1Inmlx4qJl4NU61cJmTh/pSGOCJIeb7ETNhWR/GQ4XsWZcQIA==", + "license": "Apache-2.0", + "dependencies": { + "zod": "^4.6.6" + } + }, + "node_modules/@x402/express": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@x402/express/-/express-2.32.0.tgz", + "integrity": "sha512-aPZDcDsSIAy6dz5YmcuosoBRy4t2VUCwzeZG/S5bxE7xZfxouyRbm3M+mlUNHymAjy4Z/lNqK6jummRe770AGw==", + "license": "Apache-2.0", + "dependencies": { + "@x402/core": "~2.32.0", + "@x402/extensions": "~2.32.0" + }, + "peerDependencies": { + "@x402/paywall": "^2.32.0", + "express": "^4.22.3 || ^5.3.0" + }, + "peerDependenciesMeta": { + "@x402/paywall": { + "optional": true + } + } + }, + "node_modules/@x402/extensions": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@x402/extensions/-/extensions-2.32.0.tgz", + "integrity": "sha512-bvhqNqCjmULkjCpjM1fJvDfoL8tzp1IFcMTXN7QJTwqM22ucNe8B4UefKeQOCpjJ3tuIEbp8k9A0fR0CiYtjrQ==", + "license": "Apache-2.0", + "dependencies": { + "@noble/curves": "^1.9.0", + "@scure/base": "^1.2.6", + "@signinwithethereum/siwe": "^4.1.0", + "@x402/core": "~2.32.0", + "ajv": "^8.18.0", + "jose": "^5.9.6", + "tweetnacl": "^1.0.3", + "viem": "^2.48.11", + "zod": "^4.6.6" + } + }, + "node_modules/@x402/fetch": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@x402/fetch/-/fetch-2.32.0.tgz", + "integrity": "sha512-MxDqmBxQz6I5NWUVu90cQ1XRZayAi8oDpGllDwrwihxfAHloE7eqXkNuFC80IRE3BbMwj8h65aBEaOaiq3EBUQ==", + "license": "Apache-2.0", + "dependencies": { + "@x402/core": "~2.32.0" + } + }, + "node_modules/@x402/stellar": { + "version": "2.32.0", + "resolved": "https://registry.npmjs.org/@x402/stellar/-/stellar-2.32.0.tgz", + "integrity": "sha512-ArexKFv6/Os4toaFP4u5RMN+A6v3WtNjCG5/CenuDQRf8+0Ts99GcNz97lKUgo9CXzJfSqE/QhwUlaZ0oiZc7g==", + "license": "Apache-2.0", + "dependencies": { + "@stellar/stellar-sdk": "^17.4.0", + "@x402/core": "~2.32.0" + }, + "engines": { + "node": ">=22.12.0" + } + }, + "node_modules/@x402/stellar/node_modules/@noble/hashes": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-2.4.0.tgz", + "integrity": "sha512-X5XaVWZIBCT7HHZGm5I7ZQXDwLG+bGXuSrMQAW+7Zvl87h1kmc1ZB1VSRJcpUfoUrGQp4Fkoxm5kZ+Ms+aW+eA==", + "license": "MIT", + "engines": { + "node": ">= 20.19.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@x402/stellar/node_modules/@stellar/js-xdr": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/@stellar/js-xdr/-/js-xdr-5.0.0.tgz", + "integrity": "sha512-HBDNKnxr+ecdaEmbZ0mcKkirOF8tXXEbWSw34P3wT40Tn3g+u+cCH17xAWZymzscq8cojHB8340pR8QNVaD32w==", + "license": "Apache-2.0", + "engines": { + "node": ">=22.0.0", + "pnpm": ">=10.0.0" + } + }, + "node_modules/@x402/stellar/node_modules/@stellar/stellar-sdk": { + "version": "17.4.0", + "resolved": "https://registry.npmjs.org/@stellar/stellar-sdk/-/stellar-sdk-17.4.0.tgz", + "integrity": "sha512-IX6gi62yWQ+6Oz56LsVEEeSViSOWJL3BkttftwVmVsu+62nLTWNVsCmTWEzwgNLT/q5HGP25OnlU+hhy2E4wwA==", + "license": "Apache-2.0", + "dependencies": { + "@exodus/bytes": "^1.15.1", + "@noble/ed25519": "^3.1.0", + "@noble/hashes": "^2.2.0", + "@stellar/js-xdr": "^5.0.0", + "@types/json-schema": "^7.0.15", + "axios": "1.20.0", + "bignumber.js": "^11.1.4", + "commander": "^14.0.3", + "eventsource": "^4.1.0", + "feaxios": "^0.0.23", + "smol-toml": "^1.6.1", + "uint8array-extras": "^1.5.0" + }, + "bin": { + "stellar-contract-bindings-typescript": "bin/stellar-contract-bindings-typescript", + "stellar-js": "bin/stellar-js", + "stellar-sdk": "bin/stellar-js" + }, + "engines": { + "node": ">=22.12.0" + } + }, + "node_modules/@x402/stellar/node_modules/axios": { + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.20.0.tgz", + "integrity": "sha512-r8aOh8j9cGKpgQAqpzrUHnSIc6a59Y3Xf/cv8sy1DrHCkZHzQGEuoq1tARk6qSyDdtQGSDgpb9kFlruzPvrgwg==", + "license": "MIT", + "dependencies": { + "follow-redirects": "^1.16.0", + "form-data": "^4.0.6", + "https-proxy-agent": "^5.0.1", + "proxy-from-env": "^2.1.0" + } + }, + "node_modules/@x402/stellar/node_modules/bignumber.js": { + "version": "11.1.5", + "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-11.1.5.tgz", + "integrity": "sha512-6WmzCNtUnfKpbozq+hOgWaZMMzORmYBwF1xZScyoIX3QRYWeKTtxxwDOW5tIz7C9BdjkIYHGTcelCLkXg0mndw==", + "license": "MIT" + }, + "node_modules/@x402/stellar/node_modules/eventsource": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-4.1.1.tgz", + "integrity": "sha512-D6bTRWh6KahHTK/m4WnjPQyEinNPf9eFLEZSEoj7d6fTibspnAVYfzHvirL7u/aoX5d9YYfIkBVAhmigUELk9w==", + "license": "MIT", + "dependencies": { + "eventsource-parser": "^3.0.1" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/abitype": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/abitype/-/abitype-1.3.0.tgz", + "integrity": "sha512-fk6Te+bojIFrMvMZrnOO+SxCB+RUksTGOzq/60ZRvs1L+BVzvi2bqt9L3W/17ZLdZsyM1FuYf65P5nlmoiH1Bg==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/wevm" + }, + "peerDependencies": { + "typescript": ">=5.0.4", + "zod": "^3.22.0 || ^4.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + }, + "zod": { + "optional": true + } + } + }, + "node_modules/accepts": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/accepts/-/accepts-2.0.0.tgz", + "integrity": "sha512-5cvg6CtKwfgdmVqY1WIiXKc3Q1bkRqGLi+2W/6ao+6Y7gu/RCwRuAhGEzh5B4KlszSuTLgZYuqFqo5bImjNKng==", + "license": "MIT", + "dependencies": { + "mime-types": "^3.0.0", + "negotiator": "^1.0.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/accepts/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/accepts/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/agent-base": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", + "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", + "license": "MIT", + "dependencies": { + "debug": "4" + }, + "engines": { + "node": ">= 6.0.0" + } + }, + "node_modules/ajv": { + "version": "8.20.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz", + "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==", + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/apg-js": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/apg-js/-/apg-js-4.4.0.tgz", + "integrity": "sha512-fefmXFknJmtgtNEXfPwZKYkMFX4Fyeyz+fNF6JWp87biGOPslJbCBVU158zvKRZfHBKnJDy8CMM40oLFGkXT8Q==", + "license": "BSD-2-Clause" + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "license": "MIT" + }, + "node_modules/available-typed-arrays": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.7.tgz", + "integrity": "sha512-wvUjBtSGN7+7SjNpq/9M2Tg350UZD3q62IFZLbRAR1bSMlCo1ZaeW+BJ+D090e4hIIZLBcTDWe4Mh4jvUDajzQ==", + "license": "MIT", + "dependencies": { + "possible-typed-array-names": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/axios": { + "version": "1.21.1", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.21.1.tgz", + "integrity": "sha512-6eI5Q/Y4u/Um9dDlsRoq5pY2rxnUTv+L4PpLitnbk/i4jb3MxLZ5CsN5Ih3IysbeRYK4pR+P7qfMsOQl9fwwFQ==", + "license": "MIT", + "dependencies": { + "follow-redirects": "^1.16.2", + "form-data": "^4.0.6", + "https-proxy-agent": "^5.0.1", + "proxy-from-env": "^2.1.0" + } + }, + "node_modules/base32.js": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/base32.js/-/base32.js-0.1.0.tgz", + "integrity": "sha512-n3TkB02ixgBOhTvANakDb4xaMXnYUVkNoRFJjQflcqMQhyEKxEHdj3E6N8t8sUQ0mjH/3/JxzlXuz3ul/J90pQ==", + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/bignumber.js": { + "version": "9.3.1", + "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-9.3.1.tgz", + "integrity": "sha512-Ko0uX15oIUS7wJ3Rb30Fs6SkVbLmPBAKdlm7q9+ak9bbIeFf0MwuBsQV6z7+X768/cHsfg+WlysDWJcmthjsjQ==", + "license": "MIT", + "engines": { + "node": "*" + } + }, + "node_modules/body-parser": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-2.4.0.tgz", + "integrity": "sha512-Ifk1KcLrxaGt1occQagQNFNNOqRt1LFuehEnHHzB8Z6cRgIxRU1TBaiIsUiCdA+gy5PL7Y1IX31DNKkRmxtXjQ==", + "license": "MIT", + "dependencies": { + "bytes": "^3.1.2", + "content-type": "^2.1.0", + "debug": "^4.4.3", + "http-errors": "^2.0.1", + "iconv-lite": "^0.7.3", + "on-finished": "^2.4.1", + "qs": "^6.16.1", + "raw-body": "^3.0.2", + "type-is": "^2.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "node_modules/bytes": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/bytes/-/bytes-3.1.2.tgz", + "integrity": "sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/call-bind": { + "version": "1.0.9", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.9.tgz", + "integrity": "sha512-a/hy+pNsFUTR+Iz8TCJvXudKVLAnz/DyeSUo10I5yvFDQJBFU2s9uqQpoSrJlroHUKoKqzg+epxyP9lqFdzfBQ==", + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", + "get-intrinsic": "^1.3.0", + "set-function-length": "^1.2.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/call-bind-apply-helpers": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", + "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", + "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "get-intrinsic": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "license": "MIT", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/commander": { + "version": "14.0.3", + "resolved": "https://registry.npmjs.org/commander/-/commander-14.0.3.tgz", + "integrity": "sha512-H+y0Jo/T1RZ9qPP4Eh1pkcQcLRglraJaSLoyOtHxu6AapkjWVCy2Sit1QQ4x3Dng8qDlSsZEet7g5Pq06MvTgw==", + "license": "MIT", + "engines": { + "node": ">=20" + } + }, + "node_modules/content-disposition": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/content-disposition/-/content-disposition-2.0.1.tgz", + "integrity": "sha512-e+H0ZXHSWYrENhQzw1LPuP4oF5MzVKmDU6d3hxlvaPEYLLg62MxtQNPRx4SYSuYJSBUgnQIG4HIN2tEtNv7Dog==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/content-type": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/content-type/-/content-type-2.1.0.tgz", + "integrity": "sha512-mj7UPXE0jaqaOsukNZRUEfEi2AcL7C/vwmwcHV0O97eO1E1pxBZuyjlZrx5seTaNBg1U6+o35wpa35Qfcc+7ag==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/cookie": { + "version": "0.7.2", + "resolved": "https://registry.npmjs.org/cookie/-/cookie-0.7.2.tgz", + "integrity": "sha512-yki5XnKuf750l50uGTllt6kKILY4nQ1eNIQatoXEByZ5dWgnKqbnqmTrBE5B4N7lrMJKQ2ytWMiTO2o0v6Ew/w==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/cookie-signature": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/cookie-signature/-/cookie-signature-1.2.2.tgz", + "integrity": "sha512-D76uU73ulSXrD1UXF4KE2TMxVVwhsnCgfAyTg9k8P6KGZjlXKrOLe4dJQKI3Bxi5wjesZoFXJWElNWBjPZMbhg==", + "license": "MIT", + "engines": { + "node": ">=6.6.0" + } + }, + "node_modules/debug": { + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", + "license": "MIT", + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/define-data-property": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.4.tgz", + "integrity": "sha512-rBMvIzlpA8v6E+SJZoo++HAYqsLrkg7MSfIinMPFhmkorw7X+dOXVJQs+QT69zGkzMyfDnIMN2Wid1+NbL3T+A==", + "license": "MIT", + "dependencies": { + "es-define-property": "^1.0.0", + "es-errors": "^1.3.0", + "gopd": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/depd": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/depd/-/depd-2.0.0.tgz", + "integrity": "sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/dotenv": { + "version": "17.4.2", + "resolved": "https://registry.npmjs.org/dotenv/-/dotenv-17.4.2.tgz", + "integrity": "sha512-nI4U3TottKAcAD9LLud4Cb7b2QztQMUEfHbvhTH09bqXTxnSie8WnjPALV/WMCrJZ6UV/qHJ6L03OqO3LcdYZw==", + "license": "BSD-2-Clause", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://dotenvx.com" + } + }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", + "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/ee-first": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz", + "integrity": "sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==", + "license": "MIT" + }, + "node_modules/encodeurl": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/encodeurl/-/encodeurl-2.0.3.tgz", + "integrity": "sha512-mIteYONiEfc4xWf2F1WXovh1c8npzS00vNeiUPdwFF+QlVJni+gNvpQltLMQhob8rew/bWWc/bGTuUr0EUGt0w==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/es-define-property": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", + "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-object-atoms": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.2.tgz", + "integrity": "sha512-HWcBoN6NileqtSydK2FqHbS/LoDd2pqrnQHLyJzBj4kOp/ky2MWMN694xOfkK8/SnUsW2DH7EfyVlydKCsm1Zw==", + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz", + "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==", + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/esbuild": { + "version": "0.28.2", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.28.2.tgz", + "integrity": "sha512-HKVLS8dvII+xoKW9kmqxbRKrnWEXfJJr/FZhhJmiqIB0e053QNYFqOBouTMO/k5sID4MvCiUCvv8b9M4h32wIA==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.28.2", + "@esbuild/android-arm": "0.28.2", + "@esbuild/android-arm64": "0.28.2", + "@esbuild/android-x64": "0.28.2", + "@esbuild/darwin-arm64": "0.28.2", + "@esbuild/darwin-x64": "0.28.2", + "@esbuild/freebsd-arm64": "0.28.2", + "@esbuild/freebsd-x64": "0.28.2", + "@esbuild/linux-arm": "0.28.2", + "@esbuild/linux-arm64": "0.28.2", + "@esbuild/linux-ia32": "0.28.2", + "@esbuild/linux-loong64": "0.28.2", + "@esbuild/linux-mips64el": "0.28.2", + "@esbuild/linux-ppc64": "0.28.2", + "@esbuild/linux-riscv64": "0.28.2", + "@esbuild/linux-s390x": "0.28.2", + "@esbuild/linux-x64": "0.28.2", + "@esbuild/netbsd-arm64": "0.28.2", + "@esbuild/netbsd-x64": "0.28.2", + "@esbuild/openbsd-arm64": "0.28.2", + "@esbuild/openbsd-x64": "0.28.2", + "@esbuild/openharmony-arm64": "0.28.2", + "@esbuild/sunos-x64": "0.28.2", + "@esbuild/win32-arm64": "0.28.2", + "@esbuild/win32-ia32": "0.28.2", + "@esbuild/win32-x64": "0.28.2" + } + }, + "node_modules/escape-html": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/escape-html/-/escape-html-1.0.3.tgz", + "integrity": "sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==", + "license": "MIT" + }, + "node_modules/etag": { + "version": "1.8.1", + "resolved": "https://registry.npmjs.org/etag/-/etag-1.8.1.tgz", + "integrity": "sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/eventemitter3": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz", + "integrity": "sha512-GWkBvjiSZK87ELrYOSESUYeVIc9mvLLf/nXalMOS5dYrgZq9o5OVkbZAVM06CVxYsCwH9BDZFPlQTlPA1j4ahA==", + "license": "MIT" + }, + "node_modules/eventsource": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-2.0.2.tgz", + "integrity": "sha512-IzUmBGPR3+oUG9dUeXynyNmf91/3zUSJg1lCktzKw47OXuhco54U3r9B7O4XX+Rb1Itm9OZ2b0RkTs10bICOxA==", + "license": "MIT", + "engines": { + "node": ">=12.0.0" + } + }, + "node_modules/eventsource-parser": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/eventsource-parser/-/eventsource-parser-3.1.1.tgz", + "integrity": "sha512-EKN1vKAMcZ8MlYMpaNuxN6R9yakzH6uajHcHVTqWJzvu5pWw9DyhbP35HH8MVBQ+dZjAfDxk+A8NiR9KWaXiyQ==", + "license": "MIT", + "engines": { + "node": ">=18.0.0" + } + }, + "node_modules/express": { + "version": "5.3.0", + "resolved": "https://registry.npmjs.org/express/-/express-5.3.0.tgz", + "integrity": "sha512-qCqy1xSoaugxOD4IVHb1ZWdkvCF2W3aE2okKouWj8VwJ+ztskSiXoBnCSJqfKT+cVPJhuJqe9YLbY425+Zh00g==", + "license": "MIT", + "dependencies": { + "accepts": "^2.0.0", + "body-parser": "^2.3.0", + "content-disposition": "^2.0.1", + "content-type": "^2.0.0", + "cookie": "^0.7.1", + "cookie-signature": "^1.2.1", + "debug": "^4.4.0", + "depd": "^2.0.0", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "etag": "^1.8.1", + "finalhandler": "^2.1.0", + "fresh": "^2.0.0", + "http-errors": "^2.0.0", + "merge-descriptors": "^2.0.0", + "mime-types": "^3.0.0", + "on-finished": "^2.4.1", + "once": "^1.4.0", + "parseurl": "^1.3.3", + "proxy-addr": "^2.0.8", + "qs": "^6.16.0", + "range-parser": "^1.2.1", + "router": "^2.2.0", + "send": "^1.1.0", + "serve-static": "^2.2.0", + "statuses": "^2.0.1", + "type-is": "^2.1.0", + "vary": "^1.1.2" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/express/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/express/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "license": "MIT" + }, + "node_modules/fast-uri": { + "version": "3.1.9", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.9.tgz", + "integrity": "sha512-hS/0Wt3Ya043oKXs0sIxrMpKQITXhMLIrVAKKXi4gozGC9v7YRWVnXIZzjNPTO02M9BdxLCWqK1yRXgNziVyJQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fastify" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fastify" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/feaxios": { + "version": "0.0.23", + "resolved": "https://registry.npmjs.org/feaxios/-/feaxios-0.0.23.tgz", + "integrity": "sha512-eghR0A21fvbkcQBgZuMfQhrXxJzC0GNUGC9fXhBge33D+mFDTwl0aJ35zoQQn575BhyjQitRc5N4f+L4cP708g==", + "license": "MIT", + "dependencies": { + "is-retry-allowed": "^3.0.0" + } + }, + "node_modules/finalhandler": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/finalhandler/-/finalhandler-2.1.1.tgz", + "integrity": "sha512-S8KoZgRZN+a5rNwqTxlZZePjT/4cnm0ROV70LedRHZ0p8u9fRID0hJUZQpkKLzro8LfmC8sx23bY6tVNxv8pQA==", + "license": "MIT", + "dependencies": { + "debug": "^4.4.0", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "on-finished": "^2.4.1", + "parseurl": "^1.3.3", + "statuses": "^2.0.1" + }, + "engines": { + "node": ">= 18.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/follow-redirects": { + "version": "1.16.3", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.16.3.tgz", + "integrity": "sha512-toOSoqN6d51Wjf1aOFJYcoVv1aND9rj/CwjLU0Vz40oDuSpWDayCeKe4JpL5NL0WdFvoOOCI3BRo69HahjbR1A==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "license": "MIT", + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/for-each": { + "version": "0.3.5", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.5.tgz", + "integrity": "sha512-dKx12eRCVIzqCxFGplyFKJMPvLEWgmNtUrpTiJIR5u97zEhRG8ySrtboPHZXx7daLxQVrl643cTzbab2tkQjxg==", + "license": "MIT", + "dependencies": { + "is-callable": "^1.2.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/form-data": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.6.tgz", + "integrity": "sha512-vKatAh4SlVfgbv+YtmhiRjhEMJsYpsG1Y2rMQtR+SVSbytsSD1YGzDIcrAJmdFec88u/+VoGmxnl+80gL1tRCQ==", + "license": "MIT", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "es-set-tostringtag": "^2.1.0", + "hasown": "^2.0.4", + "mime-types": "^2.1.35" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/forwarded": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/forwarded/-/forwarded-0.2.0.tgz", + "integrity": "sha512-buRG0fpBtRHSTCOASe6hD258tEubFoRLb4ZNA6NxMVHNw2gOcwHo9wyablzMzOA5z9xA9L1KNjk/Nt6MT9aYow==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/fresh": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/fresh/-/fresh-2.0.0.tgz", + "integrity": "sha512-Rx/WycZ60HOaqLKAi6cHRKKI7zxWbJ31MhntmtwMoaTeF7XFH9hhBp8vITaMidfljRQ6eYWCKkaTK+ykVJHP2A==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-intrinsic": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", + "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "function-bind": "^1.1.2", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", + "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/gopd": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", + "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.2.tgz", + "integrity": "sha512-55JNKuIW+vq4Ke1BjOTjM2YctQIvCT7GFzHwmfZPGo5wnrgkid0YQtnAleFSqumZm4az3n2BS+erby5ipJdgrg==", + "license": "MIT", + "dependencies": { + "es-define-property": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", + "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", + "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", + "license": "MIT", + "dependencies": { + "has-symbols": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hasown": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.4.tgz", + "integrity": "sha512-T2UbfbBEF32wiepXIsMlTW9+dDYC6wMh/t/vYA4tuOMKqWz/n3vr1NFSxQiyP+zk2mXsoMA/i/7qV6LKut1t1A==", + "license": "MIT", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "license": "MIT", + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/https-proxy-agent": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", + "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", + "license": "MIT", + "dependencies": { + "agent-base": "6", + "debug": "4" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/iconv-lite": { + "version": "0.7.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.7.3.tgz", + "integrity": "sha512-IKXpvIzjnC9XTAUbVBcMfGS0EPaIXtW6v+zr+RRp+hqULEpo0owZax6wyRwPOJbWbzjYspQwusTsfVr0ifh4uQ==", + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/incur": { + "version": "0.4.26", + "resolved": "https://registry.npmjs.org/incur/-/incur-0.4.26.tgz", + "integrity": "sha512-63lwOc8+o1VeFkIW3sWWMrDSP5Dd1NsvucUWyxLUk+DoNRiNl7cj481nlLdlboXkq+tqYPBSlV/7XbylS2S4BA==", + "license": "MIT", + "dependencies": { + "@cfworker/json-schema": "^4.1.1", + "@modelcontextprotocol/server": "2.0.0-alpha.4", + "@scalar/openapi-types": "^0.8.0", + "@toon-format/toon": "^2.1.0", + "tokenx": "^1.3.0", + "yaml": "^2.8.2", + "zod": "^4.3.6" + }, + "bin": { + "incur": "dist/bin.js", + "incur.src": "src/bin.ts" + }, + "engines": { + "node": ">=22" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "license": "ISC" + }, + "node_modules/ipaddr.js": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/ipaddr.js/-/ipaddr.js-1.9.1.tgz", + "integrity": "sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==", + "license": "MIT", + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-promise": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/is-promise/-/is-promise-4.0.0.tgz", + "integrity": "sha512-hvpoI6korhJMnej285dSg6nu1+e6uxs7zG3BYAm5byqDsgJNWwxzM6z6iZiAgQR4TJ30JmBTOwqZUw3WlyH3AQ==", + "license": "MIT" + }, + "node_modules/is-retry-allowed": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-retry-allowed/-/is-retry-allowed-3.0.0.tgz", + "integrity": "sha512-9xH0xvoggby+u0uGF7cZXdrutWiBiaFG8ZT4YFPXL8NzkyAwX3AKGLeFQLvzDpM430+nDFBZ1LHkie/8ocL06A==", + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.15", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.15.tgz", + "integrity": "sha512-p3EcsicXjit7SaskXHs1hA91QxgTw46Fv6EFKKGS5DRFLD8yKnohjF3hxoju94b/OcMZoQukzpPpBE9uLVKzgQ==", + "license": "MIT", + "dependencies": { + "which-typed-array": "^1.1.16" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==", + "license": "MIT" + }, + "node_modules/isows": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/isows/-/isows-1.0.7.tgz", + "integrity": "sha512-I1fSfDCZL5P0v33sVqeTDSpcstAg/N+wF5HS033mogOVIp4B+oHC7oOCsA3axAbBSGTJ8QubbNmnIRN/h8U7hg==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/wevm" + } + ], + "license": "MIT", + "peerDependencies": { + "ws": "*" + } + }, + "node_modules/jose": { + "version": "5.10.0", + "resolved": "https://registry.npmjs.org/jose/-/jose-5.10.0.tgz", + "integrity": "sha512-s+3Al/p9g32Iq+oqXxkW//7jk2Vig6FF1CFqzVXoTUXt2qz89YWbL+OwS17NFYEvxC35n0FKeGO2LGYSxeM2Gg==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/panva" + } + }, + "node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "license": "MIT" + }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", + "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/media-typer": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/media-typer/-/media-typer-1.1.1.tgz", + "integrity": "sha512-yz3xRaG20c6/BOzvYoDaGtPmGscs7YivItZEEqe6GbwNfHuxu9YNmvnEkMzKldAGY4/80pRcQRZSEnhquk9XuQ==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/merge-descriptors": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-2.0.0.tgz", + "integrity": "sha512-Snk314V5ayFLhp3fkUREub6WtjBfPdCPY1Ln8/8munuLuiYhsABgBVWsozAG+MWMbVEvcdcpbi9R7ww22l9Q3g==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "license": "MIT", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mppx": { + "version": "0.21.1", + "resolved": "https://registry.npmjs.org/mppx/-/mppx-0.21.1.tgz", + "integrity": "sha512-71+y/cOamBOH1+UehF9EgttkGkwCFmlbDGIs2fB/+0WvZqWCqw5zPqY0rKjxhru+jb1nZo9tK4/S3D1aSLCn7w==", + "extraneous": true, + "license": "MIT", + "dependencies": { + "ox": "0.14.65", + "structured-headers": "2.1.0", + "zod": "^4.6.7" + }, + "bin": { + "mppx": "dist/bin.js" + }, + "peerDependencies": { + "@modelcontextprotocol/sdk": ">=1.25.0", + "@stripe/agent-identity": ">=0.3.0", + "@x402/core": ">=2.22.0", + "@x402/evm": ">=2.22.0", + "@x402/express": ">=2.22.0", + "@x402/hono": ">=2.22.0", + "@x402/mcp": ">=2.22.0", + "@x402/next": ">=2.22.0", + "elysia": ">=1.2.0", + "express": ">=5", + "hono": ">=4.12.25", + "next": ">=16.2.6", + "viem": ">=2.57.19" + }, + "peerDependenciesMeta": { + "@modelcontextprotocol/sdk": { + "optional": true + }, + "@stripe/agent-identity": { + "optional": true + }, + "@x402/core": { + "optional": true + }, + "@x402/evm": { + "optional": true + }, + "@x402/express": { + "optional": true + }, + "@x402/hono": { + "optional": true + }, + "@x402/mcp": { + "optional": true + }, + "@x402/next": { + "optional": true + }, + "elysia": { + "optional": true + }, + "express": { + "optional": true + }, + "hono": { + "optional": true + }, + "next": { + "optional": true + } + } + }, + "node_modules/mppx/node_modules/@noble/curves": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.1.tgz", + "integrity": "sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==", + "extraneous": true, + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/mppx/node_modules/ox": { + "version": "0.14.65", + "resolved": "https://registry.npmjs.org/ox/-/ox-0.14.65.tgz", + "integrity": "sha512-K7oj+jvEP4Gf78ZOYuWAWzKEX/g5z7p6ukj84gdbFnezmFSt6SpprEp9tH5tymXsywSqRdeqk+8JL4+9o0Schw==", + "extraneous": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/wevm" + } + ], + "license": "MIT", + "dependencies": { + "@adraffy/ens-normalize": "^1.11.0", + "@noble/ciphers": "^1.3.0", + "@noble/curves": "1.9.1", + "@noble/hashes": "^1.8.0", + "@scure/bip32": "^1.7.0", + "@scure/bip39": "^1.6.0", + "abitype": "^1.2.3", + "eventemitter3": "5.0.1" + }, + "peerDependencies": { + "typescript": ">=5.4.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "license": "MIT" + }, + "node_modules/negotiator": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/negotiator/-/negotiator-1.1.0.tgz", + "integrity": "sha512-NMPBRMJgiQHjbd8phG3Vebdx4kZ1H121rbl5IkMqeOsahptB9BKo/d7oJ3zTXqTgagn2bWlNSXkh0QUGM31RYg==", + "license": "MIT", + "dependencies": { + "content-type": "^2.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/nirium": { + "version": "0.19.8", + "resolved": "https://registry.npmjs.org/nirium/-/nirium-0.19.8.tgz", + "integrity": "sha512-iOlikOCvqB/ewlaSK2/BVZeNHlaPJySegTSeuUAxdg1Dwvg4qgkxmih8diygbXJ9PR/05cfTV443mvcBw07pwA==", + "license": "Apache-2.0", + "dependencies": { + "@stellar/mpp": "^0.7.1", + "@stellar/stellar-sdk": "^16.3.0", + "@x402/fetch": "^2.28.0", + "@x402/stellar": "^2.28.0", + "mppx": "^0.6.31", + "viem": "^2.55.19", + "ws": "^8.21.3" + }, + "engines": { + "node": ">=22.12.0" + } + }, + "node_modules/nirium-cli": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/nirium-cli/-/nirium-cli-3.2.7.tgz", + "integrity": "sha512-PPj36Sw2Hfn/aVzBgp8qM+uFXYtRK9PJFfvpTU8W4xmlsB6NjweEg6xzn9R/GKbUc012f5hUTdJN2o3JZ6A6Vw==", + "license": "Apache-2.0", + "dependencies": { + "@stellar/stellar-sdk": "^16.3.0", + "@x402/express": "^2.28.0", + "axios": "^1.20.0", + "commander": "^14.0.3", + "express": "^5.1.0", + "nirium": "^0.19.0" + }, + "bin": { + "nirium": "bin/nirium.js" + }, + "engines": { + "node": ">=22.12.0" + } + }, + "node_modules/nirium-cli/node_modules/@noble/hashes": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-2.4.0.tgz", + "integrity": "sha512-X5XaVWZIBCT7HHZGm5I7ZQXDwLG+bGXuSrMQAW+7Zvl87h1kmc1ZB1VSRJcpUfoUrGQp4Fkoxm5kZ+Ms+aW+eA==", + "license": "MIT", + "engines": { + "node": ">= 20.19.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/nirium-cli/node_modules/@stellar/js-xdr": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@stellar/js-xdr/-/js-xdr-4.0.0.tgz", + "integrity": "sha512-+NmNa7Tk5BI5XFdy/6xGTqAN4J9a9KgCrCGhj2uEUTCBhLkch0M+QbKzNH8zEnejWe0p8w+0q5hUVX6L3OzoVA==", + "license": "Apache-2.0", + "engines": { + "node": ">=20.0.0", + "pnpm": ">=9.0.0" + } + }, + "node_modules/nirium-cli/node_modules/@stellar/stellar-sdk": { + "version": "16.4.1", + "resolved": "https://registry.npmjs.org/@stellar/stellar-sdk/-/stellar-sdk-16.4.1.tgz", + "integrity": "sha512-0kT+ShOUE6dc0smLEsajuizss1hvlGDsCooM88FqgxNOCKpY8IuQPzCs75RNKMSMITz+dX7KZ5qGhQ2EWGMTTg==", + "license": "Apache-2.0", + "dependencies": { + "@noble/ed25519": "^3.1.0", + "@noble/hashes": "^2.2.0", + "@stellar/js-xdr": "4.0.0", + "axios": "1.20.0", + "base32.js": "^0.1.0", + "bignumber.js": "^11.1.4", + "buffer": "^6.0.3", + "commander": "^14.0.3", + "eventsource": "^4.1.0", + "feaxios": "^0.0.23", + "smol-toml": "^1.6.1", + "uint8array-extras": "^1.5.0" + }, + "bin": { + "stellar-js": "bin/stellar-js" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/nirium-cli/node_modules/axios": { + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.20.0.tgz", + "integrity": "sha512-r8aOh8j9cGKpgQAqpzrUHnSIc6a59Y3Xf/cv8sy1DrHCkZHzQGEuoq1tARk6qSyDdtQGSDgpb9kFlruzPvrgwg==", + "license": "MIT", + "dependencies": { + "follow-redirects": "^1.16.0", + "form-data": "^4.0.6", + "https-proxy-agent": "^5.0.1", + "proxy-from-env": "^2.1.0" + } + }, + "node_modules/nirium-cli/node_modules/bignumber.js": { + "version": "11.1.5", + "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-11.1.5.tgz", + "integrity": "sha512-6WmzCNtUnfKpbozq+hOgWaZMMzORmYBwF1xZScyoIX3QRYWeKTtxxwDOW5tIz7C9BdjkIYHGTcelCLkXg0mndw==", + "license": "MIT" + }, + "node_modules/nirium-cli/node_modules/eventsource": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-4.1.1.tgz", + "integrity": "sha512-D6bTRWh6KahHTK/m4WnjPQyEinNPf9eFLEZSEoj7d6fTibspnAVYfzHvirL7u/aoX5d9YYfIkBVAhmigUELk9w==", + "license": "MIT", + "dependencies": { + "eventsource-parser": "^3.0.1" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/nirium/node_modules/@noble/curves": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.1.tgz", + "integrity": "sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==", + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/nirium/node_modules/@noble/curves/node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/nirium/node_modules/@noble/hashes": { + "version": "2.4.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-2.4.0.tgz", + "integrity": "sha512-X5XaVWZIBCT7HHZGm5I7ZQXDwLG+bGXuSrMQAW+7Zvl87h1kmc1ZB1VSRJcpUfoUrGQp4Fkoxm5kZ+Ms+aW+eA==", + "license": "MIT", + "engines": { + "node": ">= 20.19.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/nirium/node_modules/@stellar/js-xdr": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/@stellar/js-xdr/-/js-xdr-4.0.0.tgz", + "integrity": "sha512-+NmNa7Tk5BI5XFdy/6xGTqAN4J9a9KgCrCGhj2uEUTCBhLkch0M+QbKzNH8zEnejWe0p8w+0q5hUVX6L3OzoVA==", + "license": "Apache-2.0", + "engines": { + "node": ">=20.0.0", + "pnpm": ">=9.0.0" + } + }, + "node_modules/nirium/node_modules/@stellar/mpp": { + "version": "0.7.1", + "resolved": "https://registry.npmjs.org/@stellar/mpp/-/mpp-0.7.1.tgz", + "integrity": "sha512-L0bwohQU4jKgm3yBFxvrhcYuroRITnUMGmr4N+aJY6q2GYY1bnhenFeTU5Bi0sxXP/5PIRA4ulRHPtqeZ8oTpA==", + "license": "MIT", + "dependencies": { + "zod": "^4.4.3" + }, + "engines": { + "node": ">=22" + }, + "peerDependencies": { + "@stellar/stellar-sdk": "^15.1.0", + "mppx": "^0.6.29" + } + }, + "node_modules/nirium/node_modules/@stellar/stellar-sdk": { + "version": "16.4.1", + "resolved": "https://registry.npmjs.org/@stellar/stellar-sdk/-/stellar-sdk-16.4.1.tgz", + "integrity": "sha512-0kT+ShOUE6dc0smLEsajuizss1hvlGDsCooM88FqgxNOCKpY8IuQPzCs75RNKMSMITz+dX7KZ5qGhQ2EWGMTTg==", + "license": "Apache-2.0", + "dependencies": { + "@noble/ed25519": "^3.1.0", + "@noble/hashes": "^2.2.0", + "@stellar/js-xdr": "4.0.0", + "axios": "1.20.0", + "base32.js": "^0.1.0", + "bignumber.js": "^11.1.4", + "buffer": "^6.0.3", + "commander": "^14.0.3", + "eventsource": "^4.1.0", + "feaxios": "^0.0.23", + "smol-toml": "^1.6.1", + "uint8array-extras": "^1.5.0" + }, + "bin": { + "stellar-js": "bin/stellar-js" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/nirium/node_modules/axios": { + "version": "1.20.0", + "resolved": "https://registry.npmjs.org/axios/-/axios-1.20.0.tgz", + "integrity": "sha512-r8aOh8j9cGKpgQAqpzrUHnSIc6a59Y3Xf/cv8sy1DrHCkZHzQGEuoq1tARk6qSyDdtQGSDgpb9kFlruzPvrgwg==", + "license": "MIT", + "dependencies": { + "follow-redirects": "^1.16.0", + "form-data": "^4.0.6", + "https-proxy-agent": "^5.0.1", + "proxy-from-env": "^2.1.0" + } + }, + "node_modules/nirium/node_modules/bignumber.js": { + "version": "11.1.5", + "resolved": "https://registry.npmjs.org/bignumber.js/-/bignumber.js-11.1.5.tgz", + "integrity": "sha512-6WmzCNtUnfKpbozq+hOgWaZMMzORmYBwF1xZScyoIX3QRYWeKTtxxwDOW5tIz7C9BdjkIYHGTcelCLkXg0mndw==", + "license": "MIT" + }, + "node_modules/nirium/node_modules/eventsource": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/eventsource/-/eventsource-4.1.1.tgz", + "integrity": "sha512-D6bTRWh6KahHTK/m4WnjPQyEinNPf9eFLEZSEoj7d6fTibspnAVYfzHvirL7u/aoX5d9YYfIkBVAhmigUELk9w==", + "license": "MIT", + "dependencies": { + "eventsource-parser": "^3.0.1" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/nirium/node_modules/mppx": { + "version": "0.6.31", + "resolved": "https://registry.npmjs.org/mppx/-/mppx-0.6.31.tgz", + "integrity": "sha512-euHHDLjNa9DQdPSzpayRBhUb3YVGSNZhVAzoOPmjzqxcEb77ry59uaeSBsWr3IjSxqmpR45cB6aR0uiNSgO6kA==", + "license": "MIT", + "dependencies": { + "incur": "^0.4.8", + "ox": "0.14.27", + "zod": "^4.4.3" + }, + "bin": { + "mppx": "dist/bin.js", + "mppx.src": "src/bin.ts" + }, + "peerDependencies": { + "@modelcontextprotocol/sdk": ">=1.25.0", + "elysia": ">=1", + "express": ">=5", + "hono": ">=4.12.18", + "viem": ">=2.51.0" + }, + "peerDependenciesMeta": { + "@modelcontextprotocol/sdk": { + "optional": true + }, + "elysia": { + "optional": true + }, + "express": { + "optional": true + }, + "hono": { + "optional": true + } + } + }, + "node_modules/nirium/node_modules/ox": { + "version": "0.14.27", + "resolved": "https://registry.npmjs.org/ox/-/ox-0.14.27.tgz", + "integrity": "sha512-+xhLHo/f+f4BH121/1Pomm/1vgBBda1wYiFpTvjSo8o5OcEj76Pf1hGPJiepoYMTQoTm2SKdSBvWkFWk5l07PA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/wevm" + } + ], + "license": "MIT", + "dependencies": { + "@adraffy/ens-normalize": "^1.11.0", + "@noble/ciphers": "^1.3.0", + "@noble/curves": "1.9.1", + "@noble/hashes": "^1.8.0", + "@scure/bip32": "^1.7.0", + "@scure/bip39": "^1.6.0", + "abitype": "^1.2.3", + "eventemitter3": "5.0.1" + }, + "peerDependencies": { + "typescript": ">=5.4.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/nirium/node_modules/ox/node_modules/@noble/hashes": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.8.0.tgz", + "integrity": "sha512-jCs9ldd7NwzpgXDIf6P3+NrHh9/sD6CQdxHyjQI+h/6rDNo88ypBxxz45UDuZHz9r3tNz7N/VInSVoVdtXEI4A==", + "license": "MIT", + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/object-inspect": { + "version": "1.14.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.14.0.tgz", + "integrity": "sha512-IVgHNlp/jwQX271+Xzoq9LZNTWXxZK+cEOrGBOBxXNbn7fapnZ+Ts6TVMgNOuAezwG2wdtnMX97tTPK6VEnuOQ==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/on-finished": { + "version": "2.4.2", + "resolved": "https://registry.npmjs.org/on-finished/-/on-finished-2.4.2.tgz", + "integrity": "sha512-ATWUv387i+nLD49EiDoOft5scf32Vsdz3ktrQJG9bi7jRFmaXTssvyvj1EmeKVVgvesbqUtvQQvaS2TpTukAZQ==", + "license": "MIT", + "dependencies": { + "ee-first": "1.1.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "license": "ISC", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/ox": { + "version": "0.14.67", + "resolved": "https://registry.npmjs.org/ox/-/ox-0.14.67.tgz", + "integrity": "sha512-6v6UlwgsmiyTujZp0aVDuN8uIBAtl/QZadBADFRZ2zp1+CM9TqDzd+rPKJ5PYvWPlCvz8JvoO9dTr42+1PhBhA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/wevm" + } + ], + "license": "MIT", + "dependencies": { + "@adraffy/ens-normalize": "^1.11.0", + "@noble/ciphers": "^1.3.0", + "@noble/curves": "1.9.1", + "@noble/hashes": "^1.8.0", + "@scure/bip32": "^1.7.0", + "@scure/bip39": "^1.6.0", + "abitype": "^1.2.3", + "eventemitter3": "5.0.1" + }, + "peerDependencies": { + "typescript": ">=5.4.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + } + } + }, + "node_modules/ox/node_modules/@noble/curves": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.1.tgz", + "integrity": "sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==", + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/parseurl": { + "version": "1.3.3", + "resolved": "https://registry.npmjs.org/parseurl/-/parseurl-1.3.3.tgz", + "integrity": "sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/path-to-regexp": { + "version": "8.4.2", + "resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-8.4.2.tgz", + "integrity": "sha512-qRcuIdP69NPm4qbACK+aDogI5CBDMi1jKe0ry5rSQJz8JVLsC7jV8XpiJjGRLLol3N+R5ihGYcrPLTno6pAdBA==", + "license": "MIT", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/possible-typed-array-names": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/possible-typed-array-names/-/possible-typed-array-names-1.1.0.tgz", + "integrity": "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg==", + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/proxy-addr": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/proxy-addr/-/proxy-addr-2.0.8.tgz", + "integrity": "sha512-5nnx0yGyVUcY6t9RnWcARWtwT9F1D8O9rt08htPvnd49W1IgZtmLkhu9WfMzQj1cFxjHIO6connUNVW5k7AVyQ==", + "license": "MIT", + "dependencies": { + "forwarded": "0.2.0", + "ipaddr.js": "1.9.1" + }, + "engines": { + "node": ">= 0.10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/proxy-from-env": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/proxy-from-env/-/proxy-from-env-2.1.0.tgz", + "integrity": "sha512-cJ+oHTW1VAEa8cJslgmUZrc+sjRKgAKl3Zyse6+PV38hZe/V6Z14TbCuXcan9F9ghlz4QrFr2c92TNF82UkYHA==", + "license": "MIT", + "engines": { + "node": ">=10" + } + }, + "node_modules/qs": { + "version": "6.17.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.17.1.tgz", + "integrity": "sha512-jd3COkaKVgGUW+ZHyEHCG9bH7RoaaiWuMgzsIBjUMVjLAaWGWpoUAVwljVvBHxRu/2qEHnadLGZrkutYUBPQJA==", + "license": "BSD-3-Clause", + "dependencies": { + "es-define-property": "^1.0.1", + "side-channel": "^1.1.1" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "license": "MIT", + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/range-parser": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/range-parser/-/range-parser-1.3.0.tgz", + "integrity": "sha512-hek2mFQpPuI4E1BBKrSto+BU3e3x4xuarsbiwr3+lf7p44juvFMV0XFWQAP3xUyqXA4RrXLIoaSUGbSt056ZMw==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/raw-body": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-3.0.2.tgz", + "integrity": "sha512-K5zQjDllxWkf7Z5xJdV0/B0WTNqx6vxG70zJE4N0kBs4LovmEYWJzQGxC9bS9RAKu3bgM40lrd5zoLJ12MQ5BA==", + "license": "MIT", + "dependencies": { + "bytes": "~3.1.2", + "http-errors": "~2.0.1", + "iconv-lite": "~0.7.0", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.10" + } + }, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/router": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/router/-/router-2.3.0.tgz", + "integrity": "sha512-bpowRfGjEPe8t9R6fJIzhwmyCGAXwKvxBUsgJm+bJukwdcWmUXbMo7p22w7aYmQBPQTUMNqMV39YX0kMou3z8w==", + "license": "MIT", + "dependencies": { + "debug": "^4.4.0", + "depd": "^2.0.0", + "is-promise": "^4.0.0", + "parseurl": "^1.3.3", + "path-to-regexp": "^8.0.0" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "license": "MIT" + }, + "node_modules/send": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/send/-/send-1.2.1.tgz", + "integrity": "sha512-1gnZf7DFcoIcajTjTwjwuDjzuz4PPcY2StKPlsGAQ1+YH20IRVrBaXSWmdjowTJ6u8Rc01PoYOGHXfP1mYcZNQ==", + "license": "MIT", + "dependencies": { + "debug": "^4.4.3", + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "etag": "^1.8.1", + "fresh": "^2.0.0", + "http-errors": "^2.0.1", + "mime-types": "^3.0.2", + "ms": "^2.1.3", + "on-finished": "^2.4.1", + "range-parser": "^1.2.1", + "statuses": "^2.0.2" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/send/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/send/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/serve-static": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/serve-static/-/serve-static-2.2.1.tgz", + "integrity": "sha512-xRXBn0pPqQTVQiC8wyQrKs2MOlX24zQ0POGaj0kultvoOCstBQM5yvOhAVSUwOMjQtTvsPWoNCHfPGwaaQJhTw==", + "license": "MIT", + "dependencies": { + "encodeurl": "^2.0.0", + "escape-html": "^1.0.3", + "parseurl": "^1.3.3", + "send": "^1.2.0" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/set-function-length": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/set-function-length/-/set-function-length-1.2.2.tgz", + "integrity": "sha512-pgRc4hJ4/sNjWCSS9AmnS40x3bNMDTknHgL5UaMBTMyJnU90EgWh1Rz+MC9eFu4BuN/UwZjKQuY/1v3rM7HMfg==", + "license": "MIT", + "dependencies": { + "define-data-property": "^1.1.4", + "es-errors": "^1.3.0", + "function-bind": "^1.1.2", + "get-intrinsic": "^1.2.4", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/setprototypeof": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.2.0.tgz", + "integrity": "sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==", + "license": "ISC" + }, + "node_modules/sha.js": { + "version": "2.4.12", + "resolved": "https://registry.npmjs.org/sha.js/-/sha.js-2.4.12.tgz", + "integrity": "sha512-8LzC5+bvI45BjpfXU8V5fdU2mfeKiQe1D1gIMn7XUlF3OTUrpdJpPPH4EMAnF0DsHHdSZqCdSss5qCmJKuiO3w==", + "license": "(MIT AND BSD-3-Clause)", + "dependencies": { + "inherits": "^2.0.4", + "safe-buffer": "^5.2.1", + "to-buffer": "^1.2.0" + }, + "bin": { + "sha.js": "bin.js" + }, + "engines": { + "node": ">= 0.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.1.tgz", + "integrity": "sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==", + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4", + "side-channel-list": "^1.0.1", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.1.tgz", + "integrity": "sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==", + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/smol-toml": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/smol-toml/-/smol-toml-1.9.1.tgz", + "integrity": "sha512-j7WyPdf0CJoutMzMoPLF/bVXHtKZIT9Rb4eGeEbWw8X2t5oirjPgpL+OpaENZrILYaXqYwnVH+qgUwVbl+pUJQ==", + "license": "BSD-3-Clause", + "engines": { + "node": ">= 18" + }, + "funding": { + "url": "https://github.com/sponsors/cyyynthia" + } + }, + "node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/structured-headers": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/structured-headers/-/structured-headers-2.1.0.tgz", + "integrity": "sha512-ClzykN+XQVaSW5UfpOdEWfDplZ1Th7mISdaFvaC2+GjLTeBhGMJw83D/Rw9jPkHOml4oYd3EXaZhbz3gnE5nBQ==", + "extraneous": true, + "license": "MIT", + "engines": { + "node": ">=18", + "npm": ">=6" + } + }, + "node_modules/to-buffer": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/to-buffer/-/to-buffer-1.2.2.tgz", + "integrity": "sha512-db0E3UJjcFhpDhAF4tLo03oli3pwl3dbnzXOUIlRKrp+ldk/VUxzpWYZENsw2SZiuBjHAk7DfB0VU7NKdpb6sw==", + "license": "MIT", + "dependencies": { + "isarray": "^2.0.5", + "safe-buffer": "^5.2.1", + "typed-array-buffer": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/toidentifier": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/toidentifier/-/toidentifier-1.0.1.tgz", + "integrity": "sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==", + "license": "MIT", + "engines": { + "node": ">=0.6" + } + }, + "node_modules/tokenx": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/tokenx/-/tokenx-1.6.0.tgz", + "integrity": "sha512-CKTjk345ajvBAUp5xUI9a5KKN0zU0lBueVHQbCskH1Hp6WkUKsPW2qGCYNs0pxNyfzxfo+IIjdt2W4sMbw/qBw==", + "license": "MIT" + }, + "node_modules/toml": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/toml/-/toml-3.0.0.tgz", + "integrity": "sha512-y/mWCZinnvxjTKYhJ+pYxwD0mRLVvOtdS2Awbgxln6iEnt4rk0yBxeSBHkGJcPucRiG0e55mwWp+g/05rsrd6w==", + "license": "MIT" + }, + "node_modules/tsx": { + "version": "4.23.15", + "resolved": "https://registry.npmjs.org/tsx/-/tsx-4.23.15.tgz", + "integrity": "sha512-Yiex1Ovn8z2xPpOWckIiysV1SSyRMY9BkLF++q0yKiDxCqRhosKfMg3janKkiLBwZ5c/YryloKwGZcrEmtwxKw==", + "dev": true, + "license": "MIT", + "dependencies": { + "esbuild": "~0.28.0" + }, + "bin": { + "tsx": "dist/cli.mjs" + }, + "engines": { + "node": ">=18.0.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.3" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==", + "license": "Unlicense" + }, + "node_modules/type-is": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/type-is/-/type-is-2.1.0.tgz", + "integrity": "sha512-faYHw0anBbc/kWF3zFTEnxSFOAGUX9GFbOBthvDdLsIlEoWOFOtS0zgCiQYwIskL9iGXZL3kAXD8OoZ4GmMATA==", + "license": "MIT", + "dependencies": { + "content-type": "^2.0.0", + "media-typer": "^1.1.0", + "mime-types": "^3.0.0" + }, + "engines": { + "node": ">= 18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/type-is/node_modules/mime-db": { + "version": "1.54.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.54.0.tgz", + "integrity": "sha512-aU5EJuIN2WDemCcAp2vFBfp/m4EAhWJnUNSSw0ixs7/kXbd6Pg64EmwJkNdFhB8aWt1sH2CTXrLxo/iAGV3oPQ==", + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/type-is/node_modules/mime-types": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-3.0.2.tgz", + "integrity": "sha512-Lbgzdk0h4juoQ9fCKXW4by0UJqj+nOOrI9MJ1sSj4nI8aI2eo1qmvQEie4VD1glsS250n15LsWsYtCugiStS5A==", + "license": "MIT", + "dependencies": { + "mime-db": "^1.54.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, + "node_modules/typed-array-buffer": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.3.tgz", + "integrity": "sha512-nAYYwfY3qnzX30IkA6AQZjVbtK6duGontcQm1WSG1MD94YLqK0515GNApXkoxKOWMusVssAHWLh9SeaoefYFGw==", + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.3", + "es-errors": "^1.3.0", + "is-typed-array": "^1.1.14" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "devOptional": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uint8array-extras": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/uint8array-extras/-/uint8array-extras-1.6.0.tgz", + "integrity": "sha512-8iAasVS4wUx0gPLjH8Xtz2PeDzTSiy8QiLGu2DT3X5GU+egFEQhpnbtkehbAwjvDcxIERmCYcysiODFmE3Ud0Q==", + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/unpipe": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/unpipe/-/unpipe-1.0.0.tgz", + "integrity": "sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/urijs": { + "version": "1.19.11", + "resolved": "https://registry.npmjs.org/urijs/-/urijs-1.19.11.tgz", + "integrity": "sha512-HXgFDgDommxn5/bIv0cnQZsPhHDA90NPHD6+c/v21U5+Sx5hoP8+dP9IZXBU1gIfvdRfhG8cel9QNPeionfcCQ==", + "license": "MIT" + }, + "node_modules/vary": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/vary/-/vary-1.1.2.tgz", + "integrity": "sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==", + "license": "MIT", + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/viem": { + "version": "2.58.4", + "resolved": "https://registry.npmjs.org/viem/-/viem-2.58.4.tgz", + "integrity": "sha512-zeYi2PliKbmJVbIvudHZrYJLh1XMXci6GBJznQLjhhGPGl9L7Hp/LmelpXhOM9VvlXwnvfW7/2PCgpjnc2j8MQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/wevm" + } + ], + "license": "MIT", + "dependencies": { + "@noble/curves": "1.9.1", + "@noble/hashes": "1.8.0", + "@scure/bip32": "1.7.0", + "@scure/bip39": "1.6.0", + "abitype": "1.2.3", + "isows": "1.0.7", + "ox": "0.14.67", + "ws": "8.21.0" + }, + "peerDependencies": { + "mppx": ">=0.17.0", + "typescript": ">=5.0.4" + }, + "peerDependenciesMeta": { + "mppx": { + "optional": true + }, + "typescript": { + "optional": true + } + } + }, + "node_modules/viem/node_modules/@noble/curves": { + "version": "1.9.1", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.9.1.tgz", + "integrity": "sha512-k11yZxZg+t+gWvBbIswW0yoJlu8cHOC7dhunwOzoWH/mXGBiYyR4YY6hAEK/3EUs4UpB8la1RfdRpeGsFHkWsA==", + "license": "MIT", + "dependencies": { + "@noble/hashes": "1.8.0" + }, + "engines": { + "node": "^14.21.3 || >=16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/viem/node_modules/abitype": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/abitype/-/abitype-1.2.3.tgz", + "integrity": "sha512-Ofer5QUnuUdTFsBRwARMoWKOH1ND5ehwYhJ3OJ/BQO+StkwQjHw0XyVh4vDttzHB7QOFhPHa/o413PJ82gU/Tg==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/wevm" + }, + "peerDependencies": { + "typescript": ">=5.0.4", + "zod": "^3.22.0 || ^4.0.0" + }, + "peerDependenciesMeta": { + "typescript": { + "optional": true + }, + "zod": { + "optional": true + } + } + }, + "node_modules/viem/node_modules/ws": { + "version": "8.21.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.21.0.tgz", + "integrity": "sha512-Vsp28b7DRcimFQvrqu2Wek3z1iYxDCWqHYB8Qsnk/S4RfaCQzPGPyBNuVjJV3cd6UiKtUtp6sNM77gWvzcCH+g==", + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/which-typed-array": { + "version": "1.1.24", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.24.tgz", + "integrity": "sha512-wk4Mf4pR5mRP7eYuuTBCIQ9d0ud2Fv2jRLQpfgnRjbOxAFHmjKFValgTpitVKzJJS8ajnYQV2Du1SZ8j6b/EUQ==", + "license": "MIT", + "dependencies": { + "available-typed-arrays": "^1.0.7", + "call-bind": "^1.0.9", + "call-bound": "^1.0.4", + "for-each": "^0.3.5", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-tostringtag": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "license": "ISC" + }, + "node_modules/ws": { + "version": "8.23.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.23.0.tgz", + "integrity": "sha512-wCkmX8QMOrKjgO8HW2WyDbTSGeqkocxgDzS9iR79rEAexty6/2qzilx3Ag8Tqf9ykop3irLKle0MtVn5qjVnoQ==", + "license": "MIT", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": ">=5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/yaml": { + "version": "2.9.1", + "resolved": "https://registry.npmjs.org/yaml/-/yaml-2.9.1.tgz", + "integrity": "sha512-3NxN8+78OdzbT7C/WjGsyfPAtJaN3FNDsWxv7Y7mcDsT/oOmgW8BpyQQFFBnvZE3j9Y2Sdz1ULFLezL7Eb2yFw==", + "license": "ISC", + "bin": { + "yaml": "bin.mjs" + }, + "engines": { + "node": ">= 14.6" + }, + "funding": { + "url": "https://github.com/sponsors/eemeli" + } + }, + "node_modules/zod": { + "version": "4.6.7", + "resolved": "https://registry.npmjs.org/zod/-/zod-4.6.7.tgz", + "integrity": "sha512-g8W2D2kU6a8untc053fX1uVBKzM7yqAxW/3zwk83+6RyF2+SKOuV+c0wBDhUwzV1PaGapmZH+rmcUzPf+3CGwg==", + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/colinhacks" + } + } + } +} diff --git a/examples/build-moderation-log/package.json b/examples/build-moderation-log/package.json new file mode 100644 index 0000000..01f8a56 --- /dev/null +++ b/examples/build-moderation-log/package.json @@ -0,0 +1,28 @@ +{ + "name": "nirium-build-moderation-log-example", + "version": "0.1.0", + "private": true, + "type": "module", + "scripts": { + "typecheck": "tsc --noEmit", + "test": "node --import tsx --test test/*.test.ts", + "log": "node --import tsx src/cli.ts log", + "check-action": "node --import tsx src/cli.ts check", + "list": "node --import tsx src/cli.ts list" + }, + "dependencies": { + "@stellar/stellar-sdk": "^14.5.0", + "dotenv": "^17.2.3", + "nirium": "^0.19.6", + "nirium-cli": "^3.2.4" + }, + "devDependencies": { + "@types/node": "^20.19.30", + "tsx": "^4.21.0", + "typescript": "^5.9.3" + }, + "engines": { + "node": ">=22.12.0" + }, + "license": "Apache-2.0" +} diff --git a/examples/build-moderation-log/receipts.json b/examples/build-moderation-log/receipts.json new file mode 100644 index 0000000..0c42da4 --- /dev/null +++ b/examples/build-moderation-log/receipts.json @@ -0,0 +1,94 @@ +[ + { + "actionId": "mod-mwscienp-12r7", + "cid": "QmUrJezMWZw15CF8tsj4ZW7917oxi18sTCYqkrgrrMHChS", + "sha256": "e27363ab85489af99ee8974006ae09bfffe6c7c87e621ba9c2a05dd19854e9df", + "signerKey": "GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE", + "tag": "wave11-moderation-log", + "anchoredAt": "2026-11-22T21:25:14.764Z", + "payload": { + "actionId": "mod-mwscienp-12r7", + "action": "warn", + "reason": "Repeated spamming of bot commands in #general", + "moderatorIdHash": "e2691daaa4bad131536d2c9c8f5b131d7768c93446c940b14ca08c0a665de598", + "targetUserIdHash": "370bfad6b9eb5584d6561ae70b4b55d2de36463e43feb20e3f87f1815984c8db", + "messageContentHash": "c5e1a0080e035f8a3c8396936b0e935ce8994f2a52bebb566d5885bd28caeef2", + "channelId": "chan_general_chat", + "serverId": "guild_nirium_community_demo", + "timestamp": "2026-11-22T21:25:11.988Z" + } + }, + { + "actionId": "mod-mwscilt0-2fk3", + "cid": "QmSZaccongZ7trqq1LvH7BTfVx7uRLx8atd5uD9VT2pFEd", + "sha256": "af43ef9ed18bbec4426f338eea900fedc0b14475f0c411e62860654f62ab68dd", + "signerKey": "GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE", + "tag": "wave11-moderation-log", + "anchoredAt": "2026-11-22T21:25:23.911Z", + "payload": { + "actionId": "mod-mwscilt0-2fk3", + "action": "mute", + "reason": "Disruptive acoustic noise and harassment in voice lounge", + "moderatorIdHash": "5ed141df3fd1b1861bf93252d9490643c2ca1c7bd5489554541949e3b051ce5f", + "targetUserIdHash": "c7efc5baea648646ccefe784acf562ac4d8c76f90df04ba6b506a14c89b43e93", + "channelId": "voice_community_lounge", + "serverId": "guild_nirium_community_demo", + "timestamp": "2026-11-22T21:25:21.252Z" + } + }, + { + "actionId": "mod-mwscisr0-lz61", + "cid": "QmQci6hVcRAX8GX4hN5LCHi5RPqqramQkf3N1Gw5FMxQZa", + "sha256": "c37195c36455532cf3155ab418a99511e07ef84dea80b87ead1df8f35e805ded", + "signerKey": "GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE", + "tag": "wave11-moderation-log", + "anchoredAt": "2026-11-22T21:25:32.890Z", + "payload": { + "actionId": "mod-mwscisr0-lz61", + "action": "message_removal", + "reason": "Posting deceptive phishing links disguised as airdrop", + "moderatorIdHash": "b83f730254888d96d4c56080f778d84349c3451a83cf799ee126f8b96989ca93", + "targetUserIdHash": "293ce42f340dd63b3f38956917535463aa4a833098ddc8b889ec71a27dc2afa8", + "messageContentHash": "ea61691f185f9a7031adfecb94748c49115ec1dc44623100d0991db9753b03ae", + "channelId": "chan_announcements", + "serverId": "guild_nirium_community_demo", + "timestamp": "2026-11-22T21:25:30.252Z" + } + }, + { + "actionId": "mod-mwscizvx-jgih", + "cid": "QmY6fcPmTDKJc2Pt6AGyZQd1mAnvfGi49QVho1PqRrHaoc", + "sha256": "fb9eba9cb4771ec9d448b8993a2f8e6d2af8edabb3859ec9ea03de5903de5b50", + "signerKey": "GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE", + "tag": "wave11-moderation-log", + "anchoredAt": "2026-11-22T21:25:42.089Z", + "payload": { + "actionId": "mod-mwscizvx-jgih", + "action": "kick", + "reason": "Unsolicited promotional DM spam sent to 50+ members", + "moderatorIdHash": "eda176719c0e9c084adde17c5ace8e8545924676b8da57ba3a29b51f9f79abfe", + "targetUserIdHash": "d5910dc8ad8ccf0b12541f5f8ae15ac1cf1125da074523beeddf2d365303a4c1", + "serverId": "guild_nirium_community_demo", + "timestamp": "2026-11-22T21:25:39.501Z" + } + }, + { + "actionId": "mod-mwscj71d-lxhe", + "cid": "QmRem2Trtiy1uwqKzc6ahR6cxRLL3WLt5GFE1Y6KLnidNq", + "sha256": "b50e79b2d89ba9caa256dbd3868b0bddf4e635c0d79277309118ce42cdeb6520", + "signerKey": "GDAIIS2ERWGIUJZTA4UMH43C5NOBGDCLNKPUDXLXD27JUO5FDA5T6USE", + "tag": "wave11-moderation-log", + "anchoredAt": "2026-11-22T21:25:51.358Z", + "payload": { + "actionId": "mod-mwscj71d-lxhe", + "action": "ban", + "reason": "Malicious impersonation of Nirium core team administrators", + "moderatorIdHash": "420e3a1885cb91904a80e0c11b4c7ba9a27e27b04b506d5d31629cfbab4a64da", + "targetUserIdHash": "ff589cc3c73c2e650ea925d8b416f840e8d2859715169ae360cd00e9c0bddec6", + "messageContentHash": "49eff3034f07780ac02572f5a16b9591df478eed06e056466a95dc8a4144fd9b", + "channelId": "chan_helpdesk", + "serverId": "guild_nirium_community_demo", + "timestamp": "2026-11-22T21:25:48.769Z" + } + } +] \ No newline at end of file diff --git a/examples/build-moderation-log/records.json b/examples/build-moderation-log/records.json new file mode 100644 index 0000000..6314c94 --- /dev/null +++ b/examples/build-moderation-log/records.json @@ -0,0 +1,59 @@ +[ + { + "actionId": "mod-mwscienp-12r7", + "action": "warn", + "reason": "Repeated spamming of bot commands in #general", + "moderatorId": "mod_guardian_01", + "targetUserId": "discord_usr_849201", + "messageContent": "!play song !play song !play song", + "channelId": "chan_general_chat", + "serverId": "guild_nirium_community_demo", + "salt": "d606ae342d711b0c493ec2bd0b531d7ccd9952bacfa32fadbe5a4d927c5d50e9", + "timestamp": "2026-11-22T21:25:11.988Z" + }, + { + "actionId": "mod-mwscilt0-2fk3", + "action": "mute", + "reason": "Disruptive acoustic noise and harassment in voice lounge", + "moderatorId": "mod_guardian_02", + "targetUserId": "discord_usr_391042", + "channelId": "voice_community_lounge", + "serverId": "guild_nirium_community_demo", + "salt": "c838594c8fb62c46594d43ad2c323584dcee6f85ec26c8e19e4f132340e16fda", + "timestamp": "2026-11-22T21:25:21.252Z" + }, + { + "actionId": "mod-mwscisr0-lz61", + "action": "message_removal", + "reason": "Posting deceptive phishing links disguised as airdrop", + "moderatorId": "mod_sentinel_bot", + "targetUserId": "discord_usr_119284", + "messageContent": "Claim 5000 free tokens here: https://airdrop-stealer.xyz", + "channelId": "chan_announcements", + "serverId": "guild_nirium_community_demo", + "salt": "c662d52c038586d26362cb7dc2b4395af65ca4ff042cb4c07bb483929214098c", + "timestamp": "2026-11-22T21:25:30.252Z" + }, + { + "actionId": "mod-mwscizvx-jgih", + "action": "kick", + "reason": "Unsolicited promotional DM spam sent to 50+ members", + "moderatorId": "mod_lead_admin", + "targetUserId": "discord_usr_772019", + "serverId": "guild_nirium_community_demo", + "salt": "7a4f266248b402fa57faa685e4beeb8c772375e46228166d3b4b248a369d73d7", + "timestamp": "2026-11-22T21:25:39.501Z" + }, + { + "actionId": "mod-mwscj71d-lxhe", + "action": "ban", + "reason": "Malicious impersonation of Nirium core team administrators", + "moderatorId": "mod_lead_admin", + "targetUserId": "discord_usr_994102", + "messageContent": "I am Nirium Support, send private key to verify wallet", + "channelId": "chan_helpdesk", + "serverId": "guild_nirium_community_demo", + "salt": "c2bfc72b59281e046187f0e5afb576817f3c327efb7d335687d04758907ea3d2", + "timestamp": "2026-11-22T21:25:48.769Z" + } +] \ No newline at end of file diff --git a/examples/build-moderation-log/scripts/anchor-demo.ts b/examples/build-moderation-log/scripts/anchor-demo.ts new file mode 100644 index 0000000..7b7ae28 --- /dev/null +++ b/examples/build-moderation-log/scripts/anchor-demo.ts @@ -0,0 +1,100 @@ +import { Keypair } from "@stellar/stellar-sdk"; +import { checkAction, niriumCliVerify } from "../src/check.js"; +import { logModerationAction, niriumAnchorer } from "../src/moderator.js"; +import { ModerationStore } from "../src/store.js"; +import type { ModerationInput } from "../src/types.js"; + +async function main() { + const store = new ModerationStore(); + const keypair = Keypair.random(); + console.log("Community Moderation Bot Signer Public Key:", keypair.publicKey()); + + const actions: ModerationInput[] = [ + { + action: "warn", + targetUserId: "discord_usr_849201", + reason: "Repeated spamming of bot commands in #general", + messageContent: "!play song !play song !play song", + moderatorId: "mod_guardian_01", + serverId: "guild_nirium_community_demo", + channelId: "chan_general_chat", + }, + { + action: "mute", + targetUserId: "discord_usr_391042", + reason: "Disruptive acoustic noise and harassment in voice lounge", + moderatorId: "mod_guardian_02", + serverId: "guild_nirium_community_demo", + channelId: "voice_community_lounge", + }, + { + action: "message_removal", + targetUserId: "discord_usr_119284", + reason: "Posting deceptive phishing links disguised as airdrop", + messageContent: "Claim 5000 free tokens here: https://airdrop-stealer.xyz", + moderatorId: "mod_sentinel_bot", + serverId: "guild_nirium_community_demo", + channelId: "chan_announcements", + }, + { + action: "kick", + targetUserId: "discord_usr_772019", + reason: "Unsolicited promotional DM spam sent to 50+ members", + moderatorId: "mod_lead_admin", + serverId: "guild_nirium_community_demo", + }, + { + action: "ban", + targetUserId: "discord_usr_994102", + reason: "Malicious impersonation of Nirium core team administrators", + messageContent: "I am Nirium Support, send private key to verify wallet", + moderatorId: "mod_lead_admin", + serverId: "guild_nirium_community_demo", + channelId: "chan_helpdesk", + }, + ]; + + const results = []; + const anchorer = niriumAnchorer(); + + for (let i = 0; i < actions.length; i++) { + const input = actions[i]; + console.log(`\nAnchoring Action ${i + 1}/5: [${input.action.toUpperCase()}] for target ${input.targetUserId}...`); + const { record, receipt } = await logModerationAction({ + input, + keypair, + store, + anchorer, + tag: "wave11-moderation-log", + }); + + console.log(` Action ID: ${record.actionId}`); + console.log(` CID: ${receipt.cid}`); + console.log(` SHA-256: ${receipt.sha256}`); + console.log(` Anchored At: ${receipt.anchoredAt}`); + + // Verify immediately + const verifyRes = niriumCliVerify(receipt.cid, receipt.sha256); + console.log(` Verify Output (status ${verifyRes.ok}):`, verifyRes.output); + + results.push({ + actionId: record.actionId, + action: record.action, + targetUserId: record.targetUserId, + reason: record.reason, + cid: receipt.cid, + sha256: receipt.sha256, + signerKey: receipt.signerKey, + anchoredAt: receipt.anchoredAt, + verifyOutput: verifyRes.output, + }); + + // Small pause between anchors + await new Promise((r) => setTimeout(r, 1500)); + } + + console.log("\n=== 5 Real Testnet Anchors Complete ==="); + console.log(JSON.stringify(results, null, 2)); +} + +main().catch(console.error); diff --git a/examples/build-moderation-log/src/check.ts b/examples/build-moderation-log/src/check.ts new file mode 100644 index 0000000..c03c55e --- /dev/null +++ b/examples/build-moderation-log/src/check.ts @@ -0,0 +1,141 @@ +import { spawnSync } from "node:child_process"; +import { createRequire } from "node:module"; +import { dirname, join } from "node:path"; +import { canonicalJson, hashWithSalt, sha256Hex } from "./crypto.js"; +import type { ModerationStore } from "./store.js"; +import type { + AnchoredModerationPayload, + CheckResult, +} from "./types.js"; + +export interface VerifyOutput { + ok: boolean; + output: string; +} + +export type Verifier = (cid: string, sha256: string) => VerifyOutput; + +/** + * Runs the standard `nirium-cli verify --hash ` from nirium-cli. + * No custom verifier is built. + */ +export const niriumCliVerify: Verifier = ( + cid: string, + sha256: string, +): VerifyOutput => { + try { + const require = createRequire(import.meta.url); + const binPath = join( + dirname(require.resolve("nirium-cli/package.json")), + "bin", + "nirium.js", + ); + const res = spawnSync( + process.execPath, + [binPath, "verify", cid, "--hash", sha256, "--retries", "3"], + { + encoding: "utf8", + timeout: 15_000, + }, + ); + const output = `${res.stdout ?? ""}${res.stderr ?? ""}`.trim(); + return { ok: res.status === 0, output }; + } catch (err) { + return { ok: false, output: `Verification process error: ${err}` }; + } +}; + +/** + * Checks a stored moderation action against its anchored Nirium receipt: + * 1. Retrieves stored record and receipt by actionId. + * 2. Reconstructs AnchoredModerationPayload from stored record using its secret salt. + * 3. Recomputes payload SHA-256 and compares with receipt hash. + * 4. Runs `nirium-cli verify --hash ` against the testnet node. + * 5. Fails if the stored record was modified or rewritten. + */ +export function checkAction( + actionId: string, + store: ModerationStore, + verifier: Verifier = niriumCliVerify, +): CheckResult { + const record = store.getRecord(actionId); + const receipt = store.getReceipt(actionId); + + if (!record) { + return { + valid: false, + actionId, + action: "warn", + reason: "", + cid: "", + signerKey: "", + hashMatch: false, + error: `Record not found for actionId "${actionId}"`, + }; + } + + if (!receipt) { + return { + valid: false, + actionId, + action: record.action, + reason: record.reason, + cid: "", + signerKey: "", + hashMatch: false, + error: `Receipt not found for actionId "${actionId}"`, + }; + } + + // Reconstruct payload using stored record and salt + const moderatorIdHash = hashWithSalt(record.moderatorId, record.salt); + const targetUserIdHash = hashWithSalt(record.targetUserId, record.salt); + const messageContentHash = record.messageContent + ? hashWithSalt(record.messageContent, record.salt) + : undefined; + + const recomputedPayload: AnchoredModerationPayload = { + actionId: record.actionId, + action: record.action, + reason: record.reason, + moderatorIdHash, + targetUserIdHash, + ...(messageContentHash ? { messageContentHash } : {}), + ...(record.channelId ? { channelId: record.channelId } : {}), + serverId: record.serverId, + timestamp: record.timestamp, + }; + + const recomputedCanonical = canonicalJson(recomputedPayload); + const recomputedSha256 = sha256Hex(recomputedCanonical); + + const hashMatch = + recomputedSha256.toLowerCase() === receipt.sha256.toLowerCase(); + + if (!hashMatch) { + return { + valid: false, + actionId, + action: record.action, + reason: record.reason, + cid: receipt.cid, + signerKey: receipt.signerKey, + hashMatch: false, + error: `TAMPERED: Stored record hash (${recomputedSha256.slice(0, 16)}...) differs from anchored receipt hash (${receipt.sha256.slice(0, 16)}...)`, + }; + } + + // Verify against IPFS / Nirium testnet node + const verifyResult = verifier(receipt.cid, recomputedSha256); + + return { + valid: verifyResult.ok, + actionId, + action: record.action, + reason: record.reason, + cid: receipt.cid, + signerKey: receipt.signerKey, + hashMatch: true, + error: verifyResult.ok ? undefined : verifyResult.output, + }; +} diff --git a/examples/build-moderation-log/src/cli.ts b/examples/build-moderation-log/src/cli.ts new file mode 100644 index 0000000..7a1efed --- /dev/null +++ b/examples/build-moderation-log/src/cli.ts @@ -0,0 +1,185 @@ +import { Keypair } from "@stellar/stellar-sdk"; +import dotenv from "dotenv"; +import { checkAction } from "./check.js"; +import { logModerationAction } from "./moderator.js"; +import { ModerationStore } from "./store.js"; +import type { ModerationAction } from "./types.js"; + +dotenv.config(); + +function getKeypair(): Keypair { + const secret = process.env.STELLAR_SECRET_KEY; + if (!secret) { + console.warn( + "[WARN] STELLAR_SECRET_KEY not set in environment. Generating a temporary testnet keypair.", + ); + return Keypair.random(); + } + return Keypair.fromSecret(secret); +} + +function printUsage(): void { + console.log(` +Nirium Moderation Log Bot CLI + +Usage: + node --import tsx src/cli.ts log [messageContent] + node --import tsx src/cli.ts check + node --import tsx src/cli.ts list + node --import tsx src/cli.ts tamper + +Actions: + warn | mute | ban | message_removal | kick + +Examples: + node --import tsx src/cli.ts log ban user_9981 "Repeated spam in general" "Buy cheap tokens at scam.xyz" + node --import tsx src/cli.ts check mod-179534-a1b2 + node --import tsx src/cli.ts list +`); +} + +async function main(): Promise { + const args = process.argv.slice(2); + const command = args[0]; + const store = new ModerationStore(); + + if (!command || command === "--help" || command === "-h") { + printUsage(); + return; + } + + if (command === "log") { + const action = args[1] as ModerationAction; + const targetUserId = args[2]; + const reason = args[3]; + const messageContent = args[4]; + + if (!action || !targetUserId || !reason) { + console.error( + "Error: Missing required arguments. Expected: log [messageContent]", + ); + process.exit(1); + } + + const validActions: ModerationAction[] = [ + "warn", + "mute", + "ban", + "message_removal", + "kick", + ]; + if (!validActions.includes(action)) { + console.error( + `Error: Invalid action "${action}". Allowed: ${validActions.join(", ")}`, + ); + process.exit(1); + } + + const keypair = getKeypair(); + console.log(`Logging moderation action [${action.toUpperCase()}]...`); + console.log(`Signer Public Key: ${keypair.publicKey()}`); + + try { + const { record, receipt } = await logModerationAction({ + input: { + action, + targetUserId, + reason, + messageContent, + moderatorId: "mod_guardian_01", + serverId: "discord_guild_nirium_alpha", + channelId: "channel_general_01", + }, + keypair, + store, + }); + + console.log("\n[SUCCESS] Action anchored to Nirium Testnet Audit Trail!"); + console.log(` Action ID: ${record.actionId}`); + console.log(` CID: ${receipt.cid}`); + console.log(` SHA-256: ${receipt.sha256}`); + console.log(` Tag: ${receipt.tag}`); + console.log(` Anchored At: ${receipt.anchoredAt}`); + console.log(` Signer: ${receipt.signerKey}`); + console.log("\nZero personal data was transmitted to IPFS. Hashes were verified."); + } catch (err) { + console.error("Failed to anchor action:", err); + process.exit(1); + } + } else if (command === "check") { + const actionId = args[1]; + if (!actionId) { + console.error("Error: Missing actionId. Expected: check "); + process.exit(1); + } + + console.log(`Checking action "${actionId}" against anchored receipt...`); + const result = checkAction(actionId, store); + + if (result.valid) { + console.log(`\n[VERIFIED] Moderation decision is genuine and unmodified!`); + console.log(` Action ID: ${result.actionId}`); + console.log(` Action: ${result.action.toUpperCase()}`); + console.log(` Reason: ${result.reason}`); + console.log(` CID: ${result.cid}`); + console.log(` Signer: ${result.signerKey}`); + console.log(` Hash Match: ${result.hashMatch}`); + } else { + console.error(`\n[CHECK FAILED / TAMPERED] Action does not match receipt!`); + console.error(` Action ID: ${result.actionId}`); + console.error(` Error: ${result.error}`); + process.exit(1); + } + } else if (command === "list") { + const records = store.loadRecords(); + const receipts = store.loadReceipts(); + console.log(`\n=== Stored Moderation Actions (${records.length}) ===\n`); + + if (records.length === 0) { + console.log("No actions recorded yet. Use 'log' to record one."); + return; + } + + for (const r of records) { + const rcpt = receipts.find((x) => x.actionId === r.actionId); + console.log(`[${r.actionId}] ${r.action.toUpperCase()} - ${r.reason}`); + console.log(` Server: ${r.serverId} | Date: ${r.timestamp}`); + console.log(` CID: ${rcpt?.cid ?? "Pending / None"}`); + console.log(` Hash: ${rcpt?.sha256 ?? "N/A"}`); + console.log(` Signer: ${rcpt?.signerKey ?? "N/A"}`); + console.log("------------------------------------------------------------"); + } + } else if (command === "tamper") { + const actionId = args[1]; + const newReason = args[2] ?? "Altered reason after the fact!"; + if (!actionId) { + console.error("Error: Missing actionId. Expected: tamper [newReason]"); + process.exit(1); + } + + const records = store.loadRecords(); + const rec = records.find((r) => r.actionId === actionId); + if (!rec) { + console.error(`Error: Record "${actionId}" not found.`); + process.exit(1); + } + + const oldReason = rec.reason; + rec.reason = newReason; + store.saveRecords(records); + + console.log(`[TAMPERED] Modified reason for "${actionId}":`); + console.log(` Old Reason: "${oldReason}"`); + console.log(` New Reason: "${newReason}"`); + console.log(`Run 'check ${actionId}' to demonstrate tamper detection!`); + } else { + console.error(`Unknown command: ${command}`); + printUsage(); + process.exit(1); + } +} + +main().catch((err) => { + console.error("Fatal error:", err); + process.exit(1); +}); diff --git a/examples/build-moderation-log/src/crypto.ts b/examples/build-moderation-log/src/crypto.ts new file mode 100644 index 0000000..7124e90 --- /dev/null +++ b/examples/build-moderation-log/src/crypto.ts @@ -0,0 +1,87 @@ +import { createHash, randomBytes } from "node:crypto"; +import { Keypair } from "@stellar/stellar-sdk"; + +/** + * Deterministically sorts object keys for canonical JSON serialization. + */ +export function canonicalJson(obj: unknown): string { + if (obj === null || typeof obj !== "object") { + return JSON.stringify(obj); + } + if (Array.isArray(obj)) { + return "[" + obj.map(canonicalJson).join(",") + "]"; + } + const keys = Object.keys(obj as Record).sort(); + const entries = keys.map( + (key) => + `${JSON.stringify(key)}:${canonicalJson((obj as Record)[key])}`, + ); + return "{" + entries.join(",") + "}"; +} + +/** + * Computes SHA-256 hash formatted as lowercase hex string. + */ +export function sha256Hex(data: string | Buffer): string { + return createHash("sha256").update(data).digest("hex"); +} + +/** + * Generates a random cryptographic salt (hex). + */ +export function generateSalt(bytes = 32): string { + return randomBytes(bytes).toString("hex"); +} + +/** + * Hashes PII (user IDs, message content) using SHA-256 with a secret salt. + * Guarantees zero plaintext personal data is anchored on IPFS / public networks. + */ +export function hashWithSalt(value: string, salt: string): string { + return createHash("sha256") + .update(salt) + .update(":") + .update(value) + .digest("hex"); +} + +/** + * Formats canonical audit statement required by Nirium protocol. + */ +export function statementFor(sha256: string): string { + return `nirium-audit-v1:${sha256}`; +} + +/** + * Signs the Nirium audit statement with a Stellar Keypair. + */ +export function signAuditStatement( + statement: string, + keypair: Keypair, +): { key: string; signature: string } { + const statementBuffer = Buffer.from(statement, "utf-8"); + const signatureBuffer = keypair.sign(statementBuffer); + return { + key: keypair.publicKey(), + signature: signatureBuffer.toString("base64"), + }; +} + +/** + * Verifies a Stellar signature over an audit statement. + */ +export function verifyAuditSignature( + statement: string, + publicKey: string, + signatureBase64: string, +): boolean { + try { + const keypair = Keypair.fromPublicKey(publicKey); + return keypair.verify( + Buffer.from(statement, "utf-8"), + Buffer.from(signatureBase64, "base64"), + ); + } catch { + return false; + } +} diff --git a/examples/build-moderation-log/src/moderator.ts b/examples/build-moderation-log/src/moderator.ts new file mode 100644 index 0000000..fac818f --- /dev/null +++ b/examples/build-moderation-log/src/moderator.ts @@ -0,0 +1,159 @@ +import { Keypair } from "@stellar/stellar-sdk"; +import { Agent as NiriumAgent, type AgentAttestationInput, type AuditAnchor } from "nirium"; +import { + canonicalJson, + generateSalt, + hashWithSalt, + sha256Hex, + statementFor, +} from "./crypto.js"; +import type { ModerationStore } from "./store.js"; +import type { + AnchoredModerationPayload, + ModerationInput, + ModerationReceipt, + ModerationStoreRecord, +} from "./types.js"; + +export interface Anchorer { + anchor(hash: string, agent: AgentAttestationInput, tag: string): Promise; +} + +/** + * Anchors through the published Nirium SDK client against the testnet node. + * Sends ONLY hash, tag, and agent signature; zero raw PII is ever sent. + */ +export function niriumAnchorer( + baseUrl = "https://nirium-agent.fly.dev", + apiKey = "", +): Anchorer { + const client = new NiriumAgent({ apiKey, baseUrl }); + return { + anchor: (hash, agent, tag) => client.anchorAuditRecord({ hash, tag, agent }), + }; +} + +export function attest( + sha256: string, + keypair: Keypair, + id = "moderation-log-bot", +): AgentAttestationInput { + return { + key: keypair.publicKey(), + signature: keypair + .sign(Buffer.from(statementFor(sha256), "utf-8")) + .toString("base64"), + id, + }; +} + +export interface LogModerationOptions { + input: ModerationInput; + keypair: Keypair; + store: ModerationStore; + anchorer?: Anchorer; + tag?: string; + customSalt?: string; + customActionId?: string; + timestamp?: string; +} + +/** + * Logs a moderation action with cryptographic audit trail guarantees: + * 1. Hashes user IDs and message content with a secret salt so zero personal data is anchored. + * 2. Prepares AnchoredModerationPayload containing hashed identifiers and action details. + * 3. Computes deterministic SHA-256 of the canonical JSON payload. + * 4. Signs statement `nirium-audit-v1:` with community's Stellar key. + * 5. Anchors hash to Nirium audit trail testnet node with a `wave11-` tag. + * 6. Stores private record in local store and public receipt for verification. + */ +export async function logModerationAction( + options: LogModerationOptions, +): Promise<{ record: ModerationStoreRecord; receipt: ModerationReceipt }> { + const { + input, + keypair, + store, + anchorer = niriumAnchorer(), + tag = "wave11-moderation-log", + customSalt, + customActionId, + timestamp = new Date().toISOString(), + } = options; + + if (!tag.startsWith("wave11-")) { + throw new Error( + 'Anchor tag must start with "wave11-" as required by Nirium Wave 11 standard', + ); + } + + const salt = customSalt ?? generateSalt(32); + const actionId = + customActionId ?? + `mod-${Date.now().toString(36)}-${Math.random().toString(36).substring(2, 6)}`; + + // Salt and hash PII: moderator ID, target user ID, and message content + const moderatorIdHash = hashWithSalt(input.moderatorId, salt); + const targetUserIdHash = hashWithSalt(input.targetUserId, salt); + const messageContentHash = input.messageContent + ? hashWithSalt(input.messageContent, salt) + : undefined; + + const payload: AnchoredModerationPayload = { + actionId, + action: input.action, + reason: input.reason, + moderatorIdHash, + targetUserIdHash, + ...(messageContentHash ? { messageContentHash } : {}), + ...(input.channelId ? { channelId: input.channelId } : {}), + serverId: input.serverId, + timestamp, + }; + + const canonicalPayloadStr = canonicalJson(payload); + const payloadSha256 = sha256Hex(canonicalPayloadStr); + + const attestation = attest(payloadSha256, keypair); + const anchorResult = await anchorer.anchor(payloadSha256, attestation, tag); + + const returnedHash = String( + anchorResult.contentSha256 ?? + (anchorResult as Record).content_sha256 ?? + "", + ).toLowerCase(); + + if (returnedHash && returnedHash !== payloadSha256.toLowerCase()) { + throw new Error( + `Node anchored ${returnedHash}, but expected ${payloadSha256}`, + ); + } + + const record: ModerationStoreRecord = { + actionId, + action: input.action, + reason: input.reason, + moderatorId: input.moderatorId, + targetUserId: input.targetUserId, + messageContent: input.messageContent, + channelId: input.channelId, + serverId: input.serverId, + salt, + timestamp, + }; + + const receipt: ModerationReceipt = { + actionId, + cid: anchorResult.cid, + sha256: payloadSha256, + signerKey: keypair.publicKey(), + tag, + anchoredAt: anchorResult.anchoredAt, + payload, + }; + + store.addRecord(record); + store.addReceipt(receipt); + + return { record, receipt }; +} diff --git a/examples/build-moderation-log/src/store.ts b/examples/build-moderation-log/src/store.ts new file mode 100644 index 0000000..8959ffc --- /dev/null +++ b/examples/build-moderation-log/src/store.ts @@ -0,0 +1,72 @@ +import fs from "node:fs"; +import path from "node:path"; +import { fileURLToPath } from "node:url"; +import type { ModerationStoreRecord, ModerationReceipt } from "./types.js"; + +const __dirname = path.dirname(fileURLToPath(import.meta.url)); +const ROOT_DIR = path.resolve(__dirname, ".."); +const DEFAULT_RECORDS_PATH = path.join(ROOT_DIR, "records.json"); +const DEFAULT_RECEIPTS_PATH = path.join(ROOT_DIR, "receipts.json"); + +export class ModerationStore { + constructor( + private recordsPath: string = DEFAULT_RECORDS_PATH, + private receiptsPath: string = DEFAULT_RECEIPTS_PATH, + ) {} + + loadRecords(): ModerationStoreRecord[] { + if (!fs.existsSync(this.recordsPath)) return []; + try { + return JSON.parse(fs.readFileSync(this.recordsPath, "utf-8")); + } catch { + return []; + } + } + + saveRecords(records: ModerationStoreRecord[]): void { + fs.writeFileSync(this.recordsPath, JSON.stringify(records, null, 2), "utf-8"); + } + + loadReceipts(): ModerationReceipt[] { + if (!fs.existsSync(this.receiptsPath)) return []; + try { + return JSON.parse(fs.readFileSync(this.receiptsPath, "utf-8")); + } catch { + return []; + } + } + + saveReceipts(receipts: ModerationReceipt[]): void { + fs.writeFileSync(this.receiptsPath, JSON.stringify(receipts, null, 2), "utf-8"); + } + + addRecord(record: ModerationStoreRecord): void { + const records = this.loadRecords(); + const existingIndex = records.findIndex((r) => r.actionId === record.actionId); + if (existingIndex >= 0) { + records[existingIndex] = record; + } else { + records.push(record); + } + this.saveRecords(records); + } + + addReceipt(receipt: ModerationReceipt): void { + const receipts = this.loadReceipts(); + const existingIndex = receipts.findIndex((r) => r.actionId === receipt.actionId); + if (existingIndex >= 0) { + receipts[existingIndex] = receipt; + } else { + receipts.push(receipt); + } + this.saveReceipts(receipts); + } + + getRecord(actionId: string): ModerationStoreRecord | undefined { + return this.loadRecords().find((r) => r.actionId === actionId); + } + + getReceipt(actionId: string): ModerationReceipt | undefined { + return this.loadReceipts().find((r) => r.actionId === actionId); + } +} diff --git a/examples/build-moderation-log/src/types.ts b/examples/build-moderation-log/src/types.ts new file mode 100644 index 0000000..fc55ec3 --- /dev/null +++ b/examples/build-moderation-log/src/types.ts @@ -0,0 +1,63 @@ +export type ModerationAction = + | "warn" + | "mute" + | "ban" + | "message_removal" + | "kick"; + +export interface ModerationInput { + action: ModerationAction; + reason: string; + moderatorId: string; + targetUserId: string; + messageContent?: string; + channelId?: string; + serverId: string; +} + +export interface ModerationStoreRecord { + actionId: string; + action: ModerationAction; + reason: string; + moderatorId: string; + targetUserId: string; + messageContent?: string; + channelId?: string; + serverId: string; + salt: string; + timestamp: string; +} + +export interface AnchoredModerationPayload { + actionId: string; + action: ModerationAction; + reason: string; + moderatorIdHash: string; + targetUserIdHash: string; + messageContentHash?: string; + channelId?: string; + serverId: string; + timestamp: string; +} + +export interface ModerationReceipt { + actionId: string; + cid: string; + sha256: string; + signerKey: string; + tag: string; + anchoredAt: string; + payload: AnchoredModerationPayload; +} + +export interface CheckResult { + valid: boolean; + actionId: string; + action: ModerationAction; + reason: string; + cid: string; + signerKey: string; + hashMatch: boolean; + signerVerified?: boolean; + error?: string; +} diff --git a/examples/build-moderation-log/test/moderation-log.test.ts b/examples/build-moderation-log/test/moderation-log.test.ts new file mode 100644 index 0000000..3b743f2 --- /dev/null +++ b/examples/build-moderation-log/test/moderation-log.test.ts @@ -0,0 +1,265 @@ +import assert from "node:assert/strict"; +import fs from "node:fs"; +import os from "node:os"; +import path from "node:path"; +import { describe, it } from "node:test"; +import { Keypair } from "@stellar/stellar-sdk"; +import type { AgentAttestationInput, AuditAnchor } from "nirium"; +import { checkAction, type Verifier } from "../src/check.js"; +import { + canonicalJson, + hashWithSalt, + sha256Hex, + statementFor, + verifyAuditSignature, +} from "../src/crypto.js"; +import { logModerationAction, type Anchorer } from "../src/moderator.js"; +import { ModerationStore } from "../src/store.js"; +import type { ModerationInput } from "../src/types.js"; + +function createTempStore(): { store: ModerationStore; cleanup: () => void } { + const dir = fs.mkdtempSync(path.join(os.tmpdir(), "mod-test-")); + const recordsPath = path.join(dir, "records.json"); + const receiptsPath = path.join(dir, "receipts.json"); + const store = new ModerationStore(recordsPath, receiptsPath); + return { + store, + cleanup: () => fs.rmSync(dir, { recursive: true, force: true }), + }; +} + +describe("Moderation Log Bot with Nirium Receipts (#381)", () => { + it("TC1 - hashes all personal data (user IDs, message content) before anchoring", async () => { + const { store, cleanup } = createTempStore(); + const keypair = Keypair.random(); + let anchoredHash = ""; + let anchoredAgent: AgentAttestationInput | undefined; + let anchoredTag = ""; + + const mockAnchorer: Anchorer = { + anchor: async (hash, agent, tag): Promise => { + anchoredHash = hash; + anchoredAgent = agent; + anchoredTag = tag; + return { + cid: "QmMockModerationCid11111111111111111111111111", + anchoredAt: "2026-11-23T02:00:00.000Z", + contentSha256: hash, + tag, + }; + }, + }; + + const rawUserId = "discord_user_998124"; + const rawModId = "moderator_admin_007"; + const rawMessage = "Please visit http://phishing-site.xyz to claim prize!"; + + const input: ModerationInput = { + action: "ban", + reason: "Posting phishing links", + targetUserId: rawUserId, + moderatorId: rawModId, + messageContent: rawMessage, + serverId: "guild_nirium_alpha", + channelId: "channel_general", + }; + + const { record, receipt } = await logModerationAction({ + input, + keypair, + store, + anchorer: mockAnchorer, + customSalt: "test-salt-secret-000", + customActionId: "act-test-01", + timestamp: "2026-11-23T02:00:00.000Z", + }); + + // 1. Receipt payload contains only hashes, never raw PII + assert.notEqual(receipt.payload.targetUserIdHash, rawUserId); + assert.notEqual(receipt.payload.moderatorIdHash, rawModId); + assert.notEqual(receipt.payload.messageContentHash, rawMessage); + + // 2. Verified salted hashes match expected values + const expectedUserHash = hashWithSalt(rawUserId, "test-salt-secret-000"); + const expectedModHash = hashWithSalt(rawModId, "test-salt-secret-000"); + const expectedMsgHash = hashWithSalt(rawMessage, "test-salt-secret-000"); + + assert.equal(receipt.payload.targetUserIdHash, expectedUserHash); + assert.equal(receipt.payload.moderatorIdHash, expectedModHash); + assert.equal(receipt.payload.messageContentHash, expectedMsgHash); + + // 3. Anchorer only received SHA-256 hash + assert.equal(anchoredHash, receipt.sha256); + assert.equal(anchoredTag, "wave11-moderation-log"); + assert.ok(anchoredAgent); + assert.equal(anchoredAgent?.key, keypair.publicKey()); + + cleanup(); + }); + + it("TC2 - signs statement nirium-audit-v1: with community Stellar key", async () => { + const { store, cleanup } = createTempStore(); + const keypair = Keypair.random(); + let capturedAgent: AgentAttestationInput | undefined; + + const mockAnchorer: Anchorer = { + anchor: async (hash, agent, tag): Promise => { + capturedAgent = agent; + return { + cid: "QmMockModerationCid22222222222222222222222222", + anchoredAt: "2026-11-23T02:00:00.000Z", + contentSha256: hash, + tag, + }; + }, + }; + + const { receipt } = await logModerationAction({ + input: { + action: "warn", + reason: "Excessive pinging in announcements", + targetUserId: "user_1122", + moderatorId: "mod_4455", + serverId: "guild_nirium_alpha", + }, + keypair, + store, + anchorer: mockAnchorer, + }); + + assert.ok(capturedAgent); + const expectedStatement = statementFor(receipt.sha256); + assert.equal(expectedStatement, `nirium-audit-v1:${receipt.sha256}`); + + // Verify cryptographic signature with Stellar SDK + const isValidSignature = verifyAuditSignature( + expectedStatement, + keypair.publicKey(), + capturedAgent?.signature ?? "", + ); + assert.equal(isValidSignature, true); + + cleanup(); + }); + + it("TC3 - enforces wave11- tag prefix", async () => { + const { store, cleanup } = createTempStore(); + const keypair = Keypair.random(); + + await assert.rejects( + async () => { + await logModerationAction({ + input: { + action: "mute", + reason: "Language warning", + targetUserId: "u1", + moderatorId: "m1", + serverId: "s1", + }, + keypair, + store, + tag: "invalid-tag-without-wave11", + }); + }, + { + message: + 'Anchor tag must start with "wave11-" as required by Nirium Wave 11 standard', + }, + ); + + cleanup(); + }); + + it("TC4 - confirms a stored action against its receipt using checkAction", async () => { + const { store, cleanup } = createTempStore(); + const keypair = Keypair.random(); + + const mockAnchorer: Anchorer = { + anchor: async (hash, _agent, tag): Promise => ({ + cid: "QmMockValidActionCid33333333333333333333333333", + anchoredAt: "2026-11-23T02:05:00.000Z", + contentSha256: hash, + tag, + }), + }; + + const mockVerifier: Verifier = (cid, sha256) => ({ + ok: true, + output: `verified CID ${cid} with hash ${sha256}`, + }); + + const { record } = await logModerationAction({ + input: { + action: "kick", + reason: "Inactivity purge", + targetUserId: "inactive_user_44", + moderatorId: "system_bot", + serverId: "guild_nirium_alpha", + }, + keypair, + store, + anchorer: mockAnchorer, + }); + + const result = checkAction(record.actionId, store, mockVerifier); + + assert.equal(result.valid, true); + assert.equal(result.hashMatch, true); + assert.equal(result.actionId, record.actionId); + assert.equal(result.action, "kick"); + assert.equal(result.reason, "Inactivity purge"); + assert.equal(result.signerKey, keypair.publicKey()); + assert.equal(result.error, undefined); + + cleanup(); + }); + + it("TC5 - editing or tampering with the stored record fails /check verification", async () => { + const { store, cleanup } = createTempStore(); + const keypair = Keypair.random(); + + const mockAnchorer: Anchorer = { + anchor: async (hash, _agent, tag): Promise => ({ + cid: "QmMockTamperCid4444444444444444444444444444444", + anchoredAt: "2026-11-23T02:10:00.000Z", + contentSha256: hash, + tag, + }), + }; + + const mockVerifier: Verifier = (cid, sha256) => ({ + ok: true, + output: `verified CID ${cid} with hash ${sha256}`, + }); + + const { record } = await logModerationAction({ + input: { + action: "ban", + reason: "Zero tolerance harassment", + targetUserId: "bad_actor_99", + moderatorId: "mod_lead", + serverId: "guild_nirium_alpha", + }, + keypair, + store, + anchorer: mockAnchorer, + }); + + // Verify valid before tamper + const initialCheck = checkAction(record.actionId, store, mockVerifier); + assert.equal(initialCheck.valid, true); + + // Tamper the stored record (e.g. changing 'ban' to 'warn' or editing the reason) + const records = store.loadRecords(); + records[0].reason = "Minor warning instead of ban"; // Tampered! + store.saveRecords(records); + + // Check action now detects tamper + const tamperedCheck = checkAction(record.actionId, store, mockVerifier); + assert.equal(tamperedCheck.valid, false); + assert.equal(tamperedCheck.hashMatch, false); + assert.ok(tamperedCheck.error?.includes("TAMPERED")); + + cleanup(); + }); +}); diff --git a/examples/build-moderation-log/tsconfig.json b/examples/build-moderation-log/tsconfig.json new file mode 100644 index 0000000..c1283b4 --- /dev/null +++ b/examples/build-moderation-log/tsconfig.json @@ -0,0 +1,13 @@ +{ + "compilerOptions": { + "target": "ES2022", + "module": "NodeNext", + "moduleResolution": "NodeNext", + "strict": true, + "esModuleInterop": true, + "skipLibCheck": true, + "forceConsistentCasingInFileNames": true, + "outDir": "dist" + }, + "include": ["src/**/*", "test/**/*"] +}