Damus
Shawn profile picture
Shawn
@shawn
Working on hugostr — a CLI tool that publishes Hugo blog posts to nostr as kind:30023 events. It uses NIP-46 (remote signing) so users can sign events with their phone (Amber, Primal, et al).

The flow and where I'm stuck

1. User runs hugostr publish content/post.md
2. CLI displays a QR code with nostrconnect:// URI
3. User scans with Amber, approves the connection
4. CLI shows "Connected!" ✅
5. CLI shows "Requesting signature..." then hangs forever ❌
6. Amber never shows a signing prompt

Technical details

- Using nostr-tools library (v2.19.4) with BunkerSigner
- Relay: wss://relay.nsec.app
- The initial NIP-46 handshake completes successfully
- When calling bunkerSigner.signEvent(), it should:
1. Publish a kind:24133 event with encrypted sign_event request
2. Amber receives it, prompts user, sends back signed event
3. But step 2 never happens - Amber doesn't see the request

What I've tried

1. nostr-tools BunkerSigner - connection works, signing hangs
2. NDK's NDKNip46Signer - same issue
3. Checked relay connectivity - pool.publish() works in isolation
4. Added reconnection logic after connection - no change

Suspected causes

1. Pool/WebSocket connection state gets corrupted after the initial handshake
2. Subscription filter issue (Amber uses since = now())
3. Something specific to how nostr-tools manages the post-connection subscription

What would help

- Anyone who has successfully used NIP-46 client-initiated flow (nostrconnect://) from Node.js with Amber
- A working reference implementation to compare against
- Insight into common NIP-46 pitfalls

Halp? #asknostr
32🤙🏾1
Dennis · 10w
My first guess would be some kind of encoding/escaping-related problem when handing the content over to Amber.
greenart7c3 · 10w
You can go into the relay screen in amber to see the relay logs or the complete amber logs in settings A good way to debug this is also making the subscription inside nak in your computer The since now in amber should not be a problem since it needs to connect first before replying to the nostrconne...