diff options
| author | hodlbod <jstaab@protonmail.com> | 2023-12-26 12:28:52 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-12-26 12:28:52 -0800 |
| commit | 92f3a45bdc67c2e321788a15301a2c09f50cd2e9 (patch) | |
| tree | 8dba5d0999e1e6582f8ae5bc31d9a6596999983d /01.md | |
| parent | d52b09732a3a35b27110d4b595268d2d9599f0f3 (diff) | |
| parent | 3b065c3c0467def35f5d38a688a1adf98d944183 (diff) | |
Merge pull request #949 from schmijos/patch-1
Reword REQ for multiple filters
Diffstat (limited to '01.md')
| -rw-r--r-- | 01.md | 4 |
1 files changed, 2 insertions, 2 deletions
| @@ -101,12 +101,12 @@ Relays expose a websocket endpoint to which clients can connect. Clients SHOULD | |||
| 101 | Clients can send 3 types of messages, which must be JSON arrays, according to the following patterns: | 101 | Clients can send 3 types of messages, which must be JSON arrays, according to the following patterns: |
| 102 | 102 | ||
| 103 | * `["EVENT", <event JSON as defined above>]`, used to publish events. | 103 | * `["EVENT", <event JSON as defined above>]`, used to publish events. |
| 104 | * `["REQ", <subscription_id>, <filters JSON>, ...]`, used to request events and subscribe to new updates. | 104 | * `["REQ", <subscription_id>, <filters1>, <filters2>, ...]`, used to request events and subscribe to new updates. |
| 105 | * `["CLOSE", <subscription_id>]`, used to stop previous subscriptions. | 105 | * `["CLOSE", <subscription_id>]`, used to stop previous subscriptions. |
| 106 | 106 | ||
| 107 | `<subscription_id>` is an arbitrary, non-empty string of max length 64 chars, that should be used to represent a subscription. Relays should manage `<subscription_id>`s independently for each WebSocket connection; even if `<subscription_id>`s are the same string, they should be treated as different subscriptions for different connections. | 107 | `<subscription_id>` is an arbitrary, non-empty string of max length 64 chars, that should be used to represent a subscription. Relays should manage `<subscription_id>`s independently for each WebSocket connection; even if `<subscription_id>`s are the same string, they should be treated as different subscriptions for different connections. |
| 108 | 108 | ||
| 109 | `<filters>` is a JSON object that determines what events will be sent in that subscription, it can have the following attributes: | 109 | `<filtersX>` is a JSON object that determines what events will be sent in that subscription, it can have the following attributes: |
| 110 | 110 | ||
| 111 | ```json | 111 | ```json |
| 112 | { | 112 | { |