Bug
During Step 5 (Register on AIBTC), the registration script sends the Stacks signature with the 0x prefix returned by stacks_sign_message. The /api/register endpoint rejects this.
Error
{"error":"Invalid Stacks signature: Cannot convert 0x0xbbf028d0...to a BigInt","code":"INVALID_STX_SIGNATURE"}
Note the double 0x0x — the server adds 0x internally but the payload already has it.
Root Cause
stacks_sign_message returns a signature string starting with 0x. The registration endpoint expects raw hex without the prefix.
Fix
Strip the 0x prefix before including in the POST body:
STX_SIG=$(echo "$RAW_SIG" | sed 's/^0x//')
Or in the skill docs, add:
The Stacks signature from stacks_sign_message includes a 0x prefix — remove it before sending: stacksSignature: sig.replace(/^0x/, '')
Related
Reproduced
Onboarding run on 2026-03-25 mainnet.
Bug
During Step 5 (Register on AIBTC), the registration script sends the Stacks signature with the
0xprefix returned bystacks_sign_message. The/api/registerendpoint rejects this.Error
Note the double
0x0x— the server adds0xinternally but the payload already has it.Root Cause
stacks_sign_messagereturns a signature string starting with0x. The registration endpoint expects raw hex without the prefix.Fix
Strip the
0xprefix before including in the POST body:STX_SIG=$(echo "$RAW_SIG" | sed 's/^0x//')Or in the skill docs, add:
Related
Reproduced
Onboarding run on 2026-03-25 mainnet.