From af0b0b76cf22272cf2fbe4748b582fe3ef84adbf Mon Sep 17 00:00:00 2001 From: tfibtcagent Date: Tue, 17 Mar 2026 11:07:45 +0000 Subject: [PATCH] fix(setup): add btcAddress field to heartbeat POST body (closes #2) Agents using native SegWit (bc1q) addresses require a btcAddress field in the heartbeat POST body for BIP-322 signature verification. Without it the server returns: "BIP-322 signature requires btcAddress parameter for verification" and the heartbeat fails. Updated three files: - .claude/skills/loop-start/SKILL.md: curl example in Setup Step 5b - .claude/skills/loop-start/daemon/loop.md: Phase 1 field list - daemon/loop.md: Phase 1 field list Co-Authored-By: Claude Sonnet 4.6 --- .claude/skills/loop-start/SKILL.md | 2 +- .claude/skills/loop-start/daemon/loop.md | 2 +- daemon/loop.md | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.claude/skills/loop-start/SKILL.md b/.claude/skills/loop-start/SKILL.md index 2e68f05..730fbe5 100644 --- a/.claude/skills/loop-start/SKILL.md +++ b/.claude/skills/loop-start/SKILL.md @@ -414,7 +414,7 @@ POST: ```bash HB_RESPONSE=$(curl -s -w "\n%{http_code}" -X POST https://aibtc.com/api/heartbeat \ -H "Content-Type: application/json" \ - -d '{"signature":"","timestamp":""}') + -d '{"signature":"","timestamp":"","btcAddress":""}') HB_CODE=$(echo "$HB_RESPONSE" | tail -1) HB_BODY=$(echo "$HB_RESPONSE" | head -1) if [ "$HB_CODE" != "200" ] && [ "$HB_CODE" != "201" ]; then diff --git a/.claude/skills/loop-start/daemon/loop.md b/.claude/skills/loop-start/daemon/loop.md index 0841a7d..c0dcffe 100644 --- a/.claude/skills/loop-start/daemon/loop.md +++ b/.claude/skills/loop-start/daemon/loop.md @@ -22,7 +22,7 @@ Unlock wallet if STATE.md says locked. Load MCP tools if not present. ## Phase 1: Heartbeat Sign `"AIBTC Check-In | {timestamp}"` (fresh UTC .000Z). -POST to `https://aibtc.com/api/heartbeat` with `{signature, timestamp}`. +POST to `https://aibtc.com/api/heartbeat` with `{signature, timestamp, btcAddress}`. Use curl, NOT execute_x402_endpoint. **Reads: nothing.** Addresses are in context from CLAUDE.md. diff --git a/daemon/loop.md b/daemon/loop.md index 2bb7d08..c56474b 100644 --- a/daemon/loop.md +++ b/daemon/loop.md @@ -40,7 +40,7 @@ On curl failure (no internet, API rate limit): skip check, continue normally. Do ## Phase 1: Heartbeat Sign `"AIBTC Check-In | {timestamp}"` (fresh UTC .000Z). -POST to `https://aibtc.com/api/heartbeat` with `{signature, timestamp}`. +POST to `https://aibtc.com/api/heartbeat` with `{signature, timestamp, btcAddress}`. Use curl, NOT execute_x402_endpoint. **Reads: nothing.** Addresses are in context from CLAUDE.md.