mirror of
https://github.com/nostr-protocol/nips.git
synced 2024-12-23 08:55:52 -05:00
nip09: filter deletation.
This commit is contained in:
parent
8a427ea6d6
commit
83e6e0b4e5
23
09.md
23
09.md
|
@ -34,6 +34,29 @@ Relays SHOULD continue to publish/share the deletion request events indefinitely
|
||||||
|
|
||||||
When an `a` tag is used, relays SHOULD delete all versions of the replaceable event up to the `created_at` timestamp of the deletion request event.
|
When an `a` tag is used, relays SHOULD delete all versions of the replaceable event up to the `created_at` timestamp of the deletion request event.
|
||||||
|
|
||||||
|
## Filter Deletation
|
||||||
|
|
||||||
|
A client MAY use `f` tag to provide a filter, relays and clients SHOULD consider deletation of all events matching to this specific filter from this client up to `kind 5` created at.
|
||||||
|
|
||||||
|
For example:
|
||||||
|
```jsonc
|
||||||
|
{
|
||||||
|
"kind": 5,
|
||||||
|
"pubkey": <32-bytes hex-encoded public key of the event creator>,
|
||||||
|
"tags": [
|
||||||
|
["f", "{\"kinds\":[1,7]}"]
|
||||||
|
],
|
||||||
|
"content": "no more text note and reactions.",
|
||||||
|
// other fields...
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The above event requests the deletation of all text notes and reactions from a user.
|
||||||
|
|
||||||
|
### Usages
|
||||||
|
|
||||||
|
User can make complex bulk deletation requests with consuming small space and this bring possiblited to remove ***all posts***, ***direct messages*** or ***delete account***.
|
||||||
|
|
||||||
## Client Usage
|
## Client Usage
|
||||||
|
|
||||||
Clients MAY choose to fully hide any events that are referenced by valid deletion request events. This includes text notes, direct messages, or other yet-to-be defined event kinds. Alternatively, they MAY show the event along with an icon or other indication that the author has "disowned" the event. The `content` field MAY also be used to replace the deleted events' own content, although a user interface should clearly indicate that this is a deletion request reason, not the original content.
|
Clients MAY choose to fully hide any events that are referenced by valid deletion request events. This includes text notes, direct messages, or other yet-to-be defined event kinds. Alternatively, they MAY show the event along with an icon or other indication that the author has "disowned" the event. The `content` field MAY also be used to replace the deleted events' own content, although a user interface should clearly indicate that this is a deletion request reason, not the original content.
|
||||||
|
|
|
@ -248,6 +248,7 @@ They exist to document what may be implemented by [Nostr](https://github.com/nos
|
||||||
| name | value | other parameters | NIP |
|
| name | value | other parameters | NIP |
|
||||||
| ----------------- | ------------------------------------ | ------------------------------- | ------------------------------------- |
|
| ----------------- | ------------------------------------ | ------------------------------- | ------------------------------------- |
|
||||||
| `e` | event id (hex) | relay URL, marker, pubkey (hex) | [01](01.md), [10](10.md) |
|
| `e` | event id (hex) | relay URL, marker, pubkey (hex) | [01](01.md), [10](10.md) |
|
||||||
|
| `f` | stringified filter object | | [09](09.md) |
|
||||||
| `p` | pubkey (hex) | relay URL, petname | [01](01.md), [02](02.md) |
|
| `p` | pubkey (hex) | relay URL, petname | [01](01.md), [02](02.md) |
|
||||||
| `a` | coordinates to an event | relay URL | [01](01.md) |
|
| `a` | coordinates to an event | relay URL | [01](01.md) |
|
||||||
| `d` | identifier | -- | [01](01.md) |
|
| `d` | identifier | -- | [01](01.md) |
|
||||||
|
|
Loading…
Reference in New Issue
Block a user