mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-07-22 15:52:22 +00:00
Restructure `amy relay` from verb-first `relay add URL --type T` to noun-first `relay <noun> <verb>`, matching amy's `marmot group …` / `cashu mint …` convention. The relay-list type is now a required path segment (no implicit default), and a bare noun lists that bucket. NIP-65 (kind:10002) is fronted by two facet-nouns, `outbox` (write) and `inbox` (read), replacing the `--marker` flag. They edit the single 10002 event and apply the spec's merge rules: - outbox add R on a read-only R → both - inbox add R on a write-only R → both - outbox remove R on a both-R → read (stays in inbox) - inbox remove R on a both-R → write (stays in outbox) - dropping the last facet removes R entirely `relay nip65` shows the combined view; `nip65 remove`/`clear` edit the whole event. Other buckets are noun+verb: `relay dm|key-package|search|private|blocked| trusted|proxy|indexer|broadcast|feeds <add|remove|set|clear|list>`. `set` needs ≥1 URL; `clear` empties. `relay add|remove URL` (no noun) stays as the transport fan-out (nip65 both + dm + key-package). BREAKING (cli --json/args): removes `relay add/remove/set --type T` and `--marker`; `relay list` overview now keys nip65 as `outbox`/`inbox`/`nip65` and the DM bucket as `dm` (was `inbox`). In-repo harnesses updated (cache/dm/marmot setup drop `--type all`; cache T5 asserts `.dm`). Verified end-to-end: merge semantics, encrypted NIP-51 round-trips, facet set/clear, fan-out, aliases, and error paths. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EjHzNewJ2sfBGCcSwe35Mc