diff options
Diffstat (limited to '29.md')
| -rw-r--r-- | 29.md | 16 |
1 files changed, 16 insertions, 0 deletions
| @@ -93,6 +93,20 @@ Any user can send one of these events to the relay in order to be automatically | |||
| 93 | } | 93 | } |
| 94 | ``` | 94 | ``` |
| 95 | 95 | ||
| 96 | - *leave request* (`kind:9022`) | ||
| 97 | |||
| 98 | Any user can send one of these events to the relay in order to be automatically removed from the group. The relay will automatically issue a `kind:9001` in response removing this user. | ||
| 99 | |||
| 100 | ```js | ||
| 101 | { | ||
| 102 | "kind": 9022, | ||
| 103 | "content": "optional reason", | ||
| 104 | "tags": [ | ||
| 105 | ["h", "<group-id>"] | ||
| 106 | ] | ||
| 107 | } | ||
| 108 | ``` | ||
| 109 | |||
| 96 | - *moderation events* (`kinds:9000-9020`) (optional) | 110 | - *moderation events* (`kinds:9000-9020`) (optional) |
| 97 | 111 | ||
| 98 | Clients can send these events to a relay in order to accomplish a moderation action. Relays must check if the pubkey sending the event is capable of performing the given action. The relay may discard the event after taking action or keep it as a moderation log. | 112 | Clients can send these events to a relay in order to accomplish a moderation action. Relays must check if the pubkey sending the event is capable of performing the given action. The relay may discard the event after taking action or keep it as a moderation log. |
| @@ -120,6 +134,7 @@ Each moderation action uses a different kind and requires different arguments, w | |||
| 120 | | 9005 | `delete-event` | `e` (id hex) | | 134 | | 9005 | `delete-event` | `e` (id hex) | |
| 121 | | 9006 | `edit-group-status` | `public` or `private`, `open` or `closed` | | 135 | | 9006 | `edit-group-status` | `public` or `private`, `open` or `closed` | |
| 122 | | 9007 | `create-group` | | | 136 | | 9007 | `create-group` | | |
| 137 | | 9008 | `delete-group` | | | ||
| 123 | 138 | ||
| 124 | - *group metadata* (`kind:39000`) (optional) | 139 | - *group metadata* (`kind:39000`) (optional) |
| 125 | 140 | ||
| @@ -160,6 +175,7 @@ The list of capabilities, as defined by this NIP, for now, is the following: | |||
| 160 | - `add-permission` | 175 | - `add-permission` |
| 161 | - `remove-permission` | 176 | - `remove-permission` |
| 162 | - `edit-group-status` | 177 | - `edit-group-status` |
| 178 | - `delete-group` | ||
| 163 | 179 | ||
| 164 | ```js | 180 | ```js |
| 165 | { | 181 | { |