Task Router Skill
Task Router
Run the BTCD collateralization flow on PGP chain. Use when the user asks to run a BTCD loan, collateralization flow, create/take orders, lock BTC, submit proofs, claim BTCD tokens, or repay loans on the PGP network.
Follow the repository instructions for this skill and your agent. Review the files and dependencies before adding it to your workflow.
SkillHub CLI
skillhub install contact-nbwfoundation/btcd-skill-betaInspect the source and compatibility requirements, then follow its installation steps.
Give your agent the source link and ask it to inspect instructions and dependencies before explaining the installation steps.
This skill contains a complete, self-contained Node.js project to run the full BTCD collateralization lifecycle on the PGP (Elastos) chain.
All runnable code is inside the scripts/ directory relative to this SKILL.md:
scripts/
├── package.json
├── .env.template.txt
├── setup.js
├── 00-create-order.js
├── 01-take-order.js
├── 02-lock-btc-collateral.js
├── 03-submit-btc-proof.js
├── 05-claim-btcd-tokens.js
├── 06-repay-loan.js
├── abi/ # Contract ABIs (LoanContract, Order, Issuer, ERC20, ArbitratorManager)
├── utils/ # Shared utilities (config, wallet, EVM/BTC clients, logger, state, proof, arbiter)
└── state/ # Flow state persists here
Copy the entire scripts/ directory to a working directory:
cp -r <path-to-this-skill>/scripts/ /tmp/btcd-flow/
cd /tmp/btcd-flow/
Create .env from the template. Only two values need changing:
cp .env.template.txt .env
Edit .env and set:
EVM_PRIVATE_KEY — your EVM private key (with 0x prefix)BTC_PRIVATE_KEY — your BTC private key (hex, no 0x prefix)Optionally adjust LENDING_AMOUNT (minimum 10) and LENDING_DAYS (only 90 or 180).
All other values (contract addresses, RPC URLs, subgraph URLs) are fixed for PGP chain and must not be changed.
Install dependencies:
npm install
Ensure wallets are funded:
Before running any step, always read state/flow-state.json to u...
These signals come from indexed source analysis and may lag behind changes. Check the current source files.
# BTCD PGP Collateralization Flow This skill contains a **complete, self-contained** Node.js project to run the full BTCD collateralization lifecycle on the PGP (Elastos) chain. ## Bundled Code Location All runnable code is inside the `scripts/` directory relative to this SKILL.md: ``` scripts/ ├── package.json ├── .env.template.txt ├── setup.js ├── 00-create-order.js ├── 01-take-order.js ├── 02-lock-btc-collateral.js ├── 03-submit-btc-proof.js ├── 05-claim-btcd-tokens.js ├── 06-repay-loan.js ├── abi/ # Contract ABIs (LoanContract, Order, Issuer, ERC20, ArbitratorManager) ├── utils/ # Shared utilities (config, wallet, EVM/BTC clients, logger, state, proof, arbiter) └── state/ # Flow state persists here ``` ## Setup Instructions 1. **Copy the entire `scripts/` directory** to a working directory: ```bash cp -r <path-to-this-skill>/scripts/ /tmp/btcd-flow/ cd /tmp/btcd-flow/ ``` 2. **Create `.env`** from the template. Only two values need changing: ```bash cp .env.template.txt .env ``` Edit `.env` and set: - `EVM_PRIVATE_KEY` — your EVM private key (with `0x` prefix) - `BTC_PRIVATE_KEY` — your BTC private key (hex, **no** `0x` prefix) Optionally adjust `LENDING_AMOUNT` (minimum 10) and `LENDING_DAYS` (only 90 or 180). All other values (contract addresses, RPC URLs, subgraph URLs) are **fixed for PGP chain** and must not be changed. 3. **Install dependencies:** ```bash npm install ``` 4. **Ensure wallets are funded:** - **BTC wallet**: Must have enough mainnet BTC for collateral + miner fees. - **EVM wallet**: Must have PGA tokens for gas fees on PGP chain. To get PGA tokens, go to **https://swap.pgpgas.org** — you need USDT on BSC chain, bridge it to PGP, then swap for PGA tokens and/or BTCD. ## CRITICAL: Check State Before Running **Before running any step**, always read `state/flow-state.json` to u...
Task Router
Register, communicate, and earn on the x402hub AI agent marketplace. Use when an agent needs to register on x402hub, browse or claim bounties, submit deliverables, send messages to other agents via x402 Relay,...
Real-time event bus for AI agents. Publish, subscribe, and share live signals across a network of agents with Unix-style simplicity.
OpenClaw integration guidance for CAPTCHAS Agent API, including OpenResponses tool schemas and plugin tool registration.