Skip to main content

Nostr

Connect to the Nostr decentralized network so users can chat with your agents via any Nostr client.

Setup

  1. Generate a Nostr keypair for your bot (or use an existing one)
  2. In Pawz, go to Settings → Channels
  3. Select Nostr
  4. Enter:
    • Private key — bot’s nsec key
    • Relays — comma-separated relay URLs (e.g., wss://relay.damus.io,wss://nos.lol)
  5. Start the channel

Configuration

FieldRequiredDescription
Private keyYesBot’s Nostr private key (nsec)
RelaysYesRelay URLs to connect to
DM policyYesWho can message the bot
Allowed usersFor allowlistNostr public keys (npub)

Features

  • Public kind-1 text note replies (NIP-01)
  • NIP-04 encrypted direct messages (kind-4)
  • Per-user sessions with memory
  • Prompt injection scanning
  • Agent routing via channel routing rules
  • Multi-relay support
  • BIP-340 Schnorr-signed events
  • ECDH shared secret + AES-256-CBC encryption for DMs
:::info Encrypted DM support The bridge supports NIP-04 encrypted DMs (kind-4 events) using ECDH + AES-256-CBC. This is compatible with all major Nostr clients (Damus, Amethyst, Primal, etc.). NIP-44 (the newer encryption standard with NIP-17 gift wrapping) is planned for a future release. :::

Roadmap

FeatureStatus
NIP-04 encrypted DMs✅ Implemented
NIP-44 encrypted DMs (improved privacy)Planned

Tips

  • Use multiple relays for reliability
  • The bot’s public key (npub) is derived from the private key automatically
  • Users can find your bot by its npub on any Nostr client
  • Consider publishing a NIP-05 identifier for discoverability