Files
bitvid/docs/moderation/relays.md
2025-10-05 01:52:50 -04:00

1.1 KiB
Raw Blame History

Relay Compatibility & Fallbacks

COUNT (NIP-45)

  • Use COUNT when available to fetch totals efficiently.
  • If a relay doesnt support COUNT:
    • Show “—” placeholder.
    • Fall back to client-side counting when cheap (narrow queries only).
    • Avoid heavy per-relay scans; cap by time window and result size.

Query hygiene

  • Prefer specific filters: authors, kinds, #e, #p, since/until.
  • Batch requests across relays; debounce UI updates.
  • Cache viewers F1 set (pubkeys you follow) and their report summaries.

Media/thumbnail considerations

  • Never block media fetch solely on relay count results.
  • Thumbnails respect blur rules locally; “show anyway” toggles do not re-query relays.

Timeouts & errors

  • Per-relay timeout (e.g., 15002500 ms); proceed with partial results.
  • Surface a subtle “partial results” indicator when some relays fail.

Privacy notes

  • Do not leak the viewers F1 set to third-party endpoints.
  • If using a reputation provider, pass pubkeys in batches; avoid attaching viewer identity unless needed.